$product = {"id":7408456433763,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 黑武士-黑白條紋","handle":"iphone-12-pro-max-mod-nx-printable-pb20","description":null,"published_at":"2024-06-11T16:37:44+08:00","created_at":"2024-05-03T15:30:11+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":41885680402531,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31472326705251,"product_id":7408456433763,"position":4,"created_at":"2024-05-03T15:30:21+08:00","updated_at":"2024-05-03T15:30:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421","variant_ids":[41885680402531]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118724-PB20","featured_media":{"alt":null,"id":23877243109475,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/99c0e0ca018c45eeae976bffafcf238ac4b4f758_836c2f0e-9ba5-4e50-89fe-ef7cde1774fb.webp?v=1714721413","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/067498687b6b210c1668f4d15df3c2c5ceb5ee4e_79421660-09f4-477e-81f6-f9c9a3982bfe.webp?v=1714721416","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24652f1f3c97b63e8ad5eadc19c104518e6edacc_2c70ad55-bd22-4b21-807a-25d1a559e08a.webp?v=1714721418","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa358fc1d1d831e5b3d37c18c79272ddf9dbf562_19a0ab98-f8df-40f3-91ca-781a9a439c55.webp?v=1714721423","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aec450d507cfbfd21244705f683d5fd449dc365b_3df57e40-7c60-4293-9f0d-a9a3be646b14.webp?v=1714721425","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16f78b265735e1615eb1332e6d4cb5f6d8bdd8fa_48363930-6ef9-4d9b-abe7-ef2ac77f05d8.webp?v=1714721427","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/186316a8cdac466afe970094e1e6b9a290b375c1_7e0bc8cd-4c0e-4d30-b944-8ebe2ec08db7.webp?v=1714721430","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a037a062a36f0060d81a9b1116ebd97b383f5235_34a3e8b3-9b76-4e54-8860-c68b69ffea4d.webp?v=1714721432","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2657448bdc4299620bc3d234c8b612c21047fb9c_2751d82f-de3b-455e-ba54-424ca149492f.webp?v=1714721435"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/99c0e0ca018c45eeae976bffafcf238ac4b4f758_836c2f0e-9ba5-4e50-89fe-ef7cde1774fb.webp?v=1714721413","options":["color"],"media":[{"alt":null,"id":23877241634915,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/99c0e0ca018c45eeae976bffafcf238ac4b4f758_836c2f0e-9ba5-4e50-89fe-ef7cde1774fb.webp?v=1714721413"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/99c0e0ca018c45eeae976bffafcf238ac4b4f758_836c2f0e-9ba5-4e50-89fe-ef7cde1774fb.webp?v=1714721413","width":2000},{"alt":null,"id":23877242159203,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/067498687b6b210c1668f4d15df3c2c5ceb5ee4e_79421660-09f4-477e-81f6-f9c9a3982bfe.webp?v=1714721416"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/067498687b6b210c1668f4d15df3c2c5ceb5ee4e_79421660-09f4-477e-81f6-f9c9a3982bfe.webp?v=1714721416","width":2000},{"alt":null,"id":23877242650723,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24652f1f3c97b63e8ad5eadc19c104518e6edacc_2c70ad55-bd22-4b21-807a-25d1a559e08a.webp?v=1714721418"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24652f1f3c97b63e8ad5eadc19c104518e6edacc_2c70ad55-bd22-4b21-807a-25d1a559e08a.webp?v=1714721418","width":2000},{"alt":null,"id":23877243109475,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421","width":2000},{"alt":null,"id":23877243502691,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa358fc1d1d831e5b3d37c18c79272ddf9dbf562_19a0ab98-f8df-40f3-91ca-781a9a439c55.webp?v=1714721423"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa358fc1d1d831e5b3d37c18c79272ddf9dbf562_19a0ab98-f8df-40f3-91ca-781a9a439c55.webp?v=1714721423","width":2000},{"alt":null,"id":23877243961443,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aec450d507cfbfd21244705f683d5fd449dc365b_3df57e40-7c60-4293-9f0d-a9a3be646b14.webp?v=1714721425"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aec450d507cfbfd21244705f683d5fd449dc365b_3df57e40-7c60-4293-9f0d-a9a3be646b14.webp?v=1714721425","width":2000},{"alt":null,"id":23877244518499,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16f78b265735e1615eb1332e6d4cb5f6d8bdd8fa_48363930-6ef9-4d9b-abe7-ef2ac77f05d8.webp?v=1714721427"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16f78b265735e1615eb1332e6d4cb5f6d8bdd8fa_48363930-6ef9-4d9b-abe7-ef2ac77f05d8.webp?v=1714721427","width":2000},{"alt":null,"id":23877245042787,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/186316a8cdac466afe970094e1e6b9a290b375c1_7e0bc8cd-4c0e-4d30-b944-8ebe2ec08db7.webp?v=1714721430"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/186316a8cdac466afe970094e1e6b9a290b375c1_7e0bc8cd-4c0e-4d30-b944-8ebe2ec08db7.webp?v=1714721430","width":2000},{"alt":null,"id":23877245567075,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a037a062a36f0060d81a9b1116ebd97b383f5235_34a3e8b3-9b76-4e54-8860-c68b69ffea4d.webp?v=1714721432"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a037a062a36f0060d81a9b1116ebd97b383f5235_34a3e8b3-9b76-4e54-8860-c68b69ffea4d.webp?v=1714721432","width":2000},{"alt":null,"id":23877246058595,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2657448bdc4299620bc3d234c8b612c21047fb9c_2751d82f-de3b-455e-ba54-424ca149492f.webp?v=1714721435"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2657448bdc4299620bc3d234c8b612c21047fb9c_2751d82f-de3b-455e-ba54-424ca149492f.webp?v=1714721435","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41885680402531,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31472326705251,"product_id":7408456433763,"position":4,"created_at":"2024-05-03T15:30:21+08:00","updated_at":"2024-05-03T15:30:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421","variant_ids":[41885680402531]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118724-PB20","featured_media":{"alt":null,"id":23877243109475,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41885680402531,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31472326705251,"product_id":7408456433763,"position":4,"created_at":"2024-05-03T15:30:21+08:00","updated_at":"2024-05-03T15:30:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421","variant_ids":[41885680402531]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118724-PB20","featured_media":{"alt":null,"id":23877243109475,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3865c3412a1a55b06c401ce080ade81cbc21f287_900a5da4-2ad7-4e8d-bde9-6b55d8557ef8.webp?v=1714721421"}},"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: "停產" }