$product = {"id":7416371380323,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-剪紙系列","handle":"iphone-8-mod-nx-printable-pb57","description":null,"published_at":"2024-06-11T16:57:14+08:00","created_at":"2024-05-06T14:44:02+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 8","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":41919010766947,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB57","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966697571,"product_id":7416371380323,"position":10,"created_at":"2024-05-06T14:44:24+08:00","updated_at":"2024-05-06T14:44:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864","variant_ids":[41919010766947]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-剪紙系列 - 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":"NPB0105424-PB57","featured_media":{"alt":null,"id":23897379930211,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ae46684c52c729add27af3f11995432f97de136_da292917-b4d1-4a44-bad1-cb52ce5877a9.webp?v=1714977844","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf955b5ac0d773d31d76ac36f084e408507465b_88387e28-867a-4e20-94bf-eb6dd28d067d.webp?v=1714977846","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21f43548f1dc7a4d41e2a051f9d5e21e8fa017e9_72b9c399-9daf-4e8d-a415-e7232ba3f0ca.webp?v=1714977849","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9bcf30a18fd2d0b8d70d0ab1c22c9718e91f4a28_14c174fe-2d81-4fec-963a-58688d71d802.webp?v=1714977851","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b14b84c3ff377129b049825fe83a0446d9b20a3_3bee6734-5951-4c3c-853b-24e8d375cdce.webp?v=1714977853","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eeed90e897020598830f9a28ab606b92728e8610_05c4a0ed-fadf-45c6-b462-9d4235e6f3b9.webp?v=1714977855","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a4248f9d4d89253981f5405f57bc13cd47c5ee_77465467-fa80-431c-aa0e-6acfb8477d55.webp?v=1714977857","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd2ccc8537394fbd1b5f2e48ecd01b622facf4d_700888bc-5d03-4d4b-a13f-3b7a5ac157ec.webp?v=1714977860","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cd370878d56716219490fc67cceb784f091ffe9_5e54b3a6-895e-4810-9939-22882369f8da.webp?v=1714977862","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ae46684c52c729add27af3f11995432f97de136_da292917-b4d1-4a44-bad1-cb52ce5877a9.webp?v=1714977844","options":["color"],"media":[{"alt":null,"id":23897375768675,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ae46684c52c729add27af3f11995432f97de136_da292917-b4d1-4a44-bad1-cb52ce5877a9.webp?v=1714977844"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ae46684c52c729add27af3f11995432f97de136_da292917-b4d1-4a44-bad1-cb52ce5877a9.webp?v=1714977844","width":2000},{"alt":null,"id":23897376489571,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf955b5ac0d773d31d76ac36f084e408507465b_88387e28-867a-4e20-94bf-eb6dd28d067d.webp?v=1714977846"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf955b5ac0d773d31d76ac36f084e408507465b_88387e28-867a-4e20-94bf-eb6dd28d067d.webp?v=1714977846","width":2000},{"alt":null,"id":23897376915555,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21f43548f1dc7a4d41e2a051f9d5e21e8fa017e9_72b9c399-9daf-4e8d-a415-e7232ba3f0ca.webp?v=1714977849"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21f43548f1dc7a4d41e2a051f9d5e21e8fa017e9_72b9c399-9daf-4e8d-a415-e7232ba3f0ca.webp?v=1714977849","width":2000},{"alt":null,"id":23897377407075,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9bcf30a18fd2d0b8d70d0ab1c22c9718e91f4a28_14c174fe-2d81-4fec-963a-58688d71d802.webp?v=1714977851"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9bcf30a18fd2d0b8d70d0ab1c22c9718e91f4a28_14c174fe-2d81-4fec-963a-58688d71d802.webp?v=1714977851","width":2000},{"alt":null,"id":23897377865827,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b14b84c3ff377129b049825fe83a0446d9b20a3_3bee6734-5951-4c3c-853b-24e8d375cdce.webp?v=1714977853"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b14b84c3ff377129b049825fe83a0446d9b20a3_3bee6734-5951-4c3c-853b-24e8d375cdce.webp?v=1714977853","width":2000},{"alt":null,"id":23897378259043,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eeed90e897020598830f9a28ab606b92728e8610_05c4a0ed-fadf-45c6-b462-9d4235e6f3b9.webp?v=1714977855"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eeed90e897020598830f9a28ab606b92728e8610_05c4a0ed-fadf-45c6-b462-9d4235e6f3b9.webp?v=1714977855","width":2000},{"alt":null,"id":23897378881635,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a4248f9d4d89253981f5405f57bc13cd47c5ee_77465467-fa80-431c-aa0e-6acfb8477d55.webp?v=1714977857"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a4248f9d4d89253981f5405f57bc13cd47c5ee_77465467-fa80-431c-aa0e-6acfb8477d55.webp?v=1714977857","width":2000},{"alt":null,"id":23897379209315,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd2ccc8537394fbd1b5f2e48ecd01b622facf4d_700888bc-5d03-4d4b-a13f-3b7a5ac157ec.webp?v=1714977860"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd2ccc8537394fbd1b5f2e48ecd01b622facf4d_700888bc-5d03-4d4b-a13f-3b7a5ac157ec.webp?v=1714977860","width":2000},{"alt":null,"id":23897379602531,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cd370878d56716219490fc67cceb784f091ffe9_5e54b3a6-895e-4810-9939-22882369f8da.webp?v=1714977862"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cd370878d56716219490fc67cceb784f091ffe9_5e54b3a6-895e-4810-9939-22882369f8da.webp?v=1714977862","width":2000},{"alt":null,"id":23897379930211,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41919010766947,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB57","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966697571,"product_id":7416371380323,"position":10,"created_at":"2024-05-06T14:44:24+08:00","updated_at":"2024-05-06T14:44:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864","variant_ids":[41919010766947]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-剪紙系列 - 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":"NPB0105424-PB57","featured_media":{"alt":null,"id":23897379930211,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41919010766947,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB57","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966697571,"product_id":7416371380323,"position":10,"created_at":"2024-05-06T14:44:24+08:00","updated_at":"2024-05-06T14:44:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864","variant_ids":[41919010766947]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-剪紙系列 - 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":"NPB0105424-PB57","featured_media":{"alt":null,"id":23897379930211,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a6c09400871e56b3b2939418218baba552b8553_3c00cd73-621e-43dd-9ab6-960892ec270a.webp?v=1714977864"}},"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: "停產" }