$product = {"id":7408539467875,"title":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-潮流系列","handle":"iphone-12-mini-mod-nx-printable-pb42","description":null,"published_at":"2024-06-11T16:40:06+08:00","created_at":"2024-05-03T15:46:24+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 mini","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":41886636605539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB42","requires_shipping":true,"taxable":true,"featured_image":{"id":31472537731171,"product_id":7408539467875,"position":9,"created_at":"2024-05-03T15:46:46+08:00","updated_at":"2024-05-03T15:46:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406","variant_ids":[41886636605539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-潮流系列 - 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":"NPB0118424-PB42","featured_media":{"alt":null,"id":23877455020131,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9599761fc0a8952934927c856349d5b1a3bd72d_f0d48b62-e08a-4d41-848d-ab2fab7926b4.webp?v=1714722387","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bed17e61649739931d9cc44322894178408ebc5a_0773fcf8-a94b-46da-8f42-49237c69c6df.webp?v=1714722389","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e188250120b34bd7e828321c20c82a1a0554c0db_c55d1b85-8066-47ec-abd3-624bd5bfb667.webp?v=1714722392","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f772328efc92d9394d94b4a08533009a6c437bec_5c69ac67-f2d4-430f-a49e-9d3ae443a0a1.webp?v=1714722394","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9490ffff136121fa092b8ba23be9f27ec3b9bc60_97ff454f-14ec-4b67-84a4-c0e0e41ccda3.webp?v=1714722397","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/111f9bec21c373046c2506dfc9590831a3ee266d_4a837b95-c8f4-4eb1-80cb-99d8e5cc0d3b.webp?v=1714722399","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/83c0f5eada622db66a143893b5b47c7337ca9244_9279dfdd-6d6f-4833-9742-468425f37553.webp?v=1714722402","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/603d1b142361756d47a0640b35af713c8393f031_33665a6d-78d6-4376-9a96-6e908a1cfcc9.webp?v=1714722404","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6683bb976e8190ffdcea040b63bc45d63bbf53dc_2446bc12-f82a-493d-9f61-4388c7a9e553.webp?v=1714722409","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50e08f239c1e15e44abb5c466895c15f8eede510_5a61f30d-c8fd-4f75-bfb5-6f0149dca87f.webp?v=1714722411"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9599761fc0a8952934927c856349d5b1a3bd72d_f0d48b62-e08a-4d41-848d-ab2fab7926b4.webp?v=1714722387","options":["color"],"media":[{"alt":null,"id":23877451186275,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9599761fc0a8952934927c856349d5b1a3bd72d_f0d48b62-e08a-4d41-848d-ab2fab7926b4.webp?v=1714722387"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9599761fc0a8952934927c856349d5b1a3bd72d_f0d48b62-e08a-4d41-848d-ab2fab7926b4.webp?v=1714722387","width":2000},{"alt":null,"id":23877451513955,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bed17e61649739931d9cc44322894178408ebc5a_0773fcf8-a94b-46da-8f42-49237c69c6df.webp?v=1714722389"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bed17e61649739931d9cc44322894178408ebc5a_0773fcf8-a94b-46da-8f42-49237c69c6df.webp?v=1714722389","width":2000},{"alt":null,"id":23877452136547,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e188250120b34bd7e828321c20c82a1a0554c0db_c55d1b85-8066-47ec-abd3-624bd5bfb667.webp?v=1714722392"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e188250120b34bd7e828321c20c82a1a0554c0db_c55d1b85-8066-47ec-abd3-624bd5bfb667.webp?v=1714722392","width":2000},{"alt":null,"id":23877452496995,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f772328efc92d9394d94b4a08533009a6c437bec_5c69ac67-f2d4-430f-a49e-9d3ae443a0a1.webp?v=1714722394"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f772328efc92d9394d94b4a08533009a6c437bec_5c69ac67-f2d4-430f-a49e-9d3ae443a0a1.webp?v=1714722394","width":2000},{"alt":null,"id":23877453054051,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9490ffff136121fa092b8ba23be9f27ec3b9bc60_97ff454f-14ec-4b67-84a4-c0e0e41ccda3.webp?v=1714722397"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9490ffff136121fa092b8ba23be9f27ec3b9bc60_97ff454f-14ec-4b67-84a4-c0e0e41ccda3.webp?v=1714722397","width":2000},{"alt":null,"id":23877453480035,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/111f9bec21c373046c2506dfc9590831a3ee266d_4a837b95-c8f4-4eb1-80cb-99d8e5cc0d3b.webp?v=1714722399"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/111f9bec21c373046c2506dfc9590831a3ee266d_4a837b95-c8f4-4eb1-80cb-99d8e5cc0d3b.webp?v=1714722399","width":2000},{"alt":null,"id":23877454037091,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/83c0f5eada622db66a143893b5b47c7337ca9244_9279dfdd-6d6f-4833-9742-468425f37553.webp?v=1714722402"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/83c0f5eada622db66a143893b5b47c7337ca9244_9279dfdd-6d6f-4833-9742-468425f37553.webp?v=1714722402","width":2000},{"alt":null,"id":23877454561379,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/603d1b142361756d47a0640b35af713c8393f031_33665a6d-78d6-4376-9a96-6e908a1cfcc9.webp?v=1714722404"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/603d1b142361756d47a0640b35af713c8393f031_33665a6d-78d6-4376-9a96-6e908a1cfcc9.webp?v=1714722404","width":2000},{"alt":null,"id":23877455020131,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406","width":2000},{"alt":null,"id":23877455577187,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6683bb976e8190ffdcea040b63bc45d63bbf53dc_2446bc12-f82a-493d-9f61-4388c7a9e553.webp?v=1714722409"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6683bb976e8190ffdcea040b63bc45d63bbf53dc_2446bc12-f82a-493d-9f61-4388c7a9e553.webp?v=1714722409","width":2000},{"alt":null,"id":23877456363619,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50e08f239c1e15e44abb5c466895c15f8eede510_5a61f30d-c8fd-4f75-bfb5-6f0149dca87f.webp?v=1714722411"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50e08f239c1e15e44abb5c466895c15f8eede510_5a61f30d-c8fd-4f75-bfb5-6f0149dca87f.webp?v=1714722411","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886636605539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB42","requires_shipping":true,"taxable":true,"featured_image":{"id":31472537731171,"product_id":7408539467875,"position":9,"created_at":"2024-05-03T15:46:46+08:00","updated_at":"2024-05-03T15:46:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406","variant_ids":[41886636605539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-潮流系列 - 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":"NPB0118424-PB42","featured_media":{"alt":null,"id":23877455020131,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886636605539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB42","requires_shipping":true,"taxable":true,"featured_image":{"id":31472537731171,"product_id":7408539467875,"position":9,"created_at":"2024-05-03T15:46:46+08:00","updated_at":"2024-05-03T15:46:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406","variant_ids":[41886636605539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-潮流系列 - 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":"NPB0118424-PB42","featured_media":{"alt":null,"id":23877455020131,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/61a391b904aa5979d63290c4a38ed059d28252f5_fa6a3375-a8de-4995-8ad1-50d2b3f71226.webp?v=1714722406"}},"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: "停產" }