$product = {"id":7408380805219,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款","handle":"iphone-12-pro-max-mod-nx-printable-pb45","description":null,"published_at":"2024-06-11T16:35:39+08:00","created_at":"2024-05-03T15:15:13+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-star-wars","Top50","type-Mod NX Printable"],"price":90000,"price_min":90000,"price_max":90000,"available":true,"price_varies":false,"compare_at_price":null,"compare_at_price_min":0,"compare_at_price_max":0,"compare_at_price_varies":false,"variants":[{"id":41884841279587,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31472115974243,"product_id":7408380805219,"position":9,"created_at":"2024-05-03T15:15:33+08:00","updated_at":"2024-05-03T15:15:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533","variant_ids":[41884841279587]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-PB45","featured_media":{"alt":null,"id":23877031395427,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47f3be823bda9add25f445c14ebdcb30c7acbbc9_902f5ae4-5595-44ab-ad24-1bc1354a0729.webp?v=1714720515","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3bc5d8285a67598a5733c5fd641d7ecf1f482034_e57b4ce5-ede7-4f23-b826-18a5465bc4d6.webp?v=1714720517","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b32f22d0ca3775ed43003132f6f24151ca3f579b_f76b5f2e-b97f-4a4c-afba-da4bc8597e63.webp?v=1714720520","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b108173fd07aaa5dbe0d2ce42094ac710065a297_8a3dbffd-2c0f-4a52-8021-e2657fa781c4.webp?v=1714720522","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/227a160435c8293a7227cdddf44172eb31d1087d_53a9687e-4bbf-4371-8040-9f0cc8764147.webp?v=1714720524","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb57339af724b4511798de89781f30fed698ea78_8858f7be-b896-496d-bb7b-72cdad6d35f5.webp?v=1714720526","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3a90b383e03b29e883154810c698eb0fd92af2a5_749989c3-3b27-458b-a3bb-c722f724a04f.webp?v=1714720529","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017db053bcfe8fd6e6bf95212dc31c325addf08e_fd835c70-86bd-4536-a698-1363174e30d1.webp?v=1714720531","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f92e8adb40dd740e96018908a4c2030daa905431_a9a90a23-0889-4696-9c03-8f56f544ee92.webp?v=1714720536"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47f3be823bda9add25f445c14ebdcb30c7acbbc9_902f5ae4-5595-44ab-ad24-1bc1354a0729.webp?v=1714720515","options":["color"],"media":[{"alt":null,"id":23877027430499,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47f3be823bda9add25f445c14ebdcb30c7acbbc9_902f5ae4-5595-44ab-ad24-1bc1354a0729.webp?v=1714720515"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47f3be823bda9add25f445c14ebdcb30c7acbbc9_902f5ae4-5595-44ab-ad24-1bc1354a0729.webp?v=1714720515","width":2000},{"alt":null,"id":23877027922019,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3bc5d8285a67598a5733c5fd641d7ecf1f482034_e57b4ce5-ede7-4f23-b826-18a5465bc4d6.webp?v=1714720517"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3bc5d8285a67598a5733c5fd641d7ecf1f482034_e57b4ce5-ede7-4f23-b826-18a5465bc4d6.webp?v=1714720517","width":2000},{"alt":null,"id":23877028380771,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b32f22d0ca3775ed43003132f6f24151ca3f579b_f76b5f2e-b97f-4a4c-afba-da4bc8597e63.webp?v=1714720520"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b32f22d0ca3775ed43003132f6f24151ca3f579b_f76b5f2e-b97f-4a4c-afba-da4bc8597e63.webp?v=1714720520","width":2000},{"alt":null,"id":23877028806755,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b108173fd07aaa5dbe0d2ce42094ac710065a297_8a3dbffd-2c0f-4a52-8021-e2657fa781c4.webp?v=1714720522"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b108173fd07aaa5dbe0d2ce42094ac710065a297_8a3dbffd-2c0f-4a52-8021-e2657fa781c4.webp?v=1714720522","width":2000},{"alt":null,"id":23877029199971,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/227a160435c8293a7227cdddf44172eb31d1087d_53a9687e-4bbf-4371-8040-9f0cc8764147.webp?v=1714720524"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/227a160435c8293a7227cdddf44172eb31d1087d_53a9687e-4bbf-4371-8040-9f0cc8764147.webp?v=1714720524","width":2000},{"alt":null,"id":23877029986403,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb57339af724b4511798de89781f30fed698ea78_8858f7be-b896-496d-bb7b-72cdad6d35f5.webp?v=1714720526"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb57339af724b4511798de89781f30fed698ea78_8858f7be-b896-496d-bb7b-72cdad6d35f5.webp?v=1714720526","width":2000},{"alt":null,"id":23877030477923,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3a90b383e03b29e883154810c698eb0fd92af2a5_749989c3-3b27-458b-a3bb-c722f724a04f.webp?v=1714720529"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3a90b383e03b29e883154810c698eb0fd92af2a5_749989c3-3b27-458b-a3bb-c722f724a04f.webp?v=1714720529","width":2000},{"alt":null,"id":23877031002211,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017db053bcfe8fd6e6bf95212dc31c325addf08e_fd835c70-86bd-4536-a698-1363174e30d1.webp?v=1714720531"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017db053bcfe8fd6e6bf95212dc31c325addf08e_fd835c70-86bd-4536-a698-1363174e30d1.webp?v=1714720531","width":2000},{"alt":null,"id":23877031395427,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533","width":2000},{"alt":null,"id":23877031919715,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f92e8adb40dd740e96018908a4c2030daa905431_a9a90a23-0889-4696-9c03-8f56f544ee92.webp?v=1714720536"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f92e8adb40dd740e96018908a4c2030daa905431_a9a90a23-0889-4696-9c03-8f56f544ee92.webp?v=1714720536","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41884841279587,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31472115974243,"product_id":7408380805219,"position":9,"created_at":"2024-05-03T15:15:33+08:00","updated_at":"2024-05-03T15:15:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533","variant_ids":[41884841279587]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-PB45","featured_media":{"alt":null,"id":23877031395427,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41884841279587,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31472115974243,"product_id":7408380805219,"position":9,"created_at":"2024-05-03T15:15:33+08:00","updated_at":"2024-05-03T15:15:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533","variant_ids":[41884841279587]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-PB45","featured_media":{"alt":null,"id":23877031395427,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80a20732f28dd79f4fbab7f7567670b2fe22a2bb_184cd9b1-f79c-4af8-9b31-9a9de573de4d.webp?v=1714720533"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}; $device_handle = null; $brand_handle = null; $type = ""; var sellingStatus // 只有設計款(SKU 含 '-')才需要合圖 if ($isMerge && $defaultVariant.sku.includes('-')) { $(document).ready(function() { var productImg = $product.images[0]; var bumperImg = window.getProductImageUrl($defaultVariant.sku.split('-')[0]); var layers = ($type === 'mod-nx-backplate' || $type === 'mod-backplate') ? [productImg, bumperImg] : [bumperImg, productImg]; window.mergeProductImages(layers).then(function (mergedImg) { $('.merged-img').attr('src', mergedImg); }); }); }; var sellingStatusData window.fetchSellingStatus().then(data => { try { sellingStatusData = data; } catch (error) { sellingStatusData = null console.error('Unable to parse selling status', error) } $(document).ready(function() { handleSellingStatus($defaultVariant.sku); }); }) function handleSellingStatus(currentSku) { if (!sellingStatusData) { console.error('No selling status available!') return } const sellingStatusElement = document.getElementById('selling-status') const addToCartButton = document.getElementById('AddToCart-product-template') const currentProductSku = currentSku.replace(/-(.*)$/, '-') if ($variants) { const flattenedSellingStatus = [...sellingStatusData.pending, ...sellingStatusData.preorder] const matchSellingStatusProduct = flattenedSellingStatus.filter(product => currentProductSku === product.sku) if (matchSellingStatusProduct.length > 0) { const isProductPending = matchSellingStatusProduct[0].status === 'pending' const matchDate = matchSellingStatusProduct[0].date sellingStatus = isProductPending ? "缺貨中" : "預購完成出貨日:" + matchDate sellingStatusElement.textContent = sellingStatus if (sellingStatus.includes("缺貨中")){ addToCartButton.disabled ='true'; addToCartButton.textContent = "缺貨中無法加入購物車" } else { addToCartButton.textContent = "加到購物車" } } else { sellingStatusElement.textContent = '' addToCartButton.textContent = "加到購物車" }; }; }; document.addEventListener('DOMContentLoaded', function () { var currentVariantSelect = document.getElementById('SingleOptionSelector-0') currentVariantSelect.addEventListener('change', function() { var currentSku = $('#current_sku').text() var skuElement = document.getElementById('current-sku') skuElement.textContent = currentSku handleSellingStatus(currentSku) }); });
// Override default values of shop.strings for each template. // Alternate product templates can change values of // add to cart button, sold out, and unavailable states here. theme.productStrings = { addToCart: "加到購物車", soldOut: "售完", unavailable: "停產" }