$product = {"id":7369203613795,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Snoopy 史努比 - 曬太陽","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-pl63","description":null,"published_at":"2024-06-11T17:31:23+08:00","created_at":"2024-04-23T15:44:04+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Snoopy 史努比","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-snoopy","device-iPhone 12 pro max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-snoopy","Top50","type-Mod NX Printable MagSafe Printable"],"price":110000,"price_min":110000,"price_max":110000,"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":41793575452771,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PL63","requires_shipping":true,"taxable":true,"featured_image":{"id":31387061387363,"product_id":7369203613795,"position":7,"created_at":"2024-04-23T15:44:27+08:00","updated_at":"2024-04-23T15:44:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267","variant_ids":[41793575452771]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Snoopy 史努比 - 曬太陽 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-PL63","featured_media":{"alt":null,"id":23789300023395,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/42c25bb8cf26a042c36b6a17729d20cdd80815ab_9da7a710-8560-4519-a312-e9a84f7b9321.webp?v=1713858252","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10b3adcd5ab2ed8936220a3eb70fc33cb5ef3863_27323176-3b73-4452-8e0c-a2e6653c94b2.webp?v=1713858254","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb81780d91d2588398446dba1143b5003facf4e9_5e95af11-340e-47fb-bb0f-b3e248429add.webp?v=1713858257","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6d6c16f53e5abc74b4afae6c8ac21ccae92540f5_4cd6dfc9-c6bb-4376-a6f9-cb8fc5cceb2f.webp?v=1713858260","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/abc63224d9a020060578929e3647b893817b7281_20cb176f-8d04-41dc-89e0-33cc85fa8943.webp?v=1713858262","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df76602c9a28e81d788dd6f4458e357ae269d5f1_62cdcb2c-c1f5-4f21-bc4c-ae24b7d5b910.webp?v=1713858264","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/70d904d8f1cea4a0352e2c7f7dd8fe3c5f318120_452c2f39-51f1-46e0-857e-7d6c3216878a.webp?v=1713858269","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8fd46e01578d804273b4281ec969142b6d9b83d8_78b01fa8-1664-4e0f-8a0c-90bbea9b29d6.webp?v=1713858272","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6092117ea50a28e4adf2786ff4578ddc39ed90c5_36db8625-7f1a-4849-bb29-3a0e1077f4ab.webp?v=1713858275"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/42c25bb8cf26a042c36b6a17729d20cdd80815ab_9da7a710-8560-4519-a312-e9a84f7b9321.webp?v=1713858252","options":["color"],"media":[{"alt":null,"id":23789295960163,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/42c25bb8cf26a042c36b6a17729d20cdd80815ab_9da7a710-8560-4519-a312-e9a84f7b9321.webp?v=1713858252"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/42c25bb8cf26a042c36b6a17729d20cdd80815ab_9da7a710-8560-4519-a312-e9a84f7b9321.webp?v=1713858252","width":2000},{"alt":null,"id":23789296615523,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10b3adcd5ab2ed8936220a3eb70fc33cb5ef3863_27323176-3b73-4452-8e0c-a2e6653c94b2.webp?v=1713858254"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10b3adcd5ab2ed8936220a3eb70fc33cb5ef3863_27323176-3b73-4452-8e0c-a2e6653c94b2.webp?v=1713858254","width":2000},{"alt":null,"id":23789297434723,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb81780d91d2588398446dba1143b5003facf4e9_5e95af11-340e-47fb-bb0f-b3e248429add.webp?v=1713858257"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb81780d91d2588398446dba1143b5003facf4e9_5e95af11-340e-47fb-bb0f-b3e248429add.webp?v=1713858257","width":2000},{"alt":null,"id":23789298221155,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6d6c16f53e5abc74b4afae6c8ac21ccae92540f5_4cd6dfc9-c6bb-4376-a6f9-cb8fc5cceb2f.webp?v=1713858260"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6d6c16f53e5abc74b4afae6c8ac21ccae92540f5_4cd6dfc9-c6bb-4376-a6f9-cb8fc5cceb2f.webp?v=1713858260","width":2000},{"alt":null,"id":23789298778211,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/abc63224d9a020060578929e3647b893817b7281_20cb176f-8d04-41dc-89e0-33cc85fa8943.webp?v=1713858262"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/abc63224d9a020060578929e3647b893817b7281_20cb176f-8d04-41dc-89e0-33cc85fa8943.webp?v=1713858262","width":2000},{"alt":null,"id":23789299466339,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df76602c9a28e81d788dd6f4458e357ae269d5f1_62cdcb2c-c1f5-4f21-bc4c-ae24b7d5b910.webp?v=1713858264"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df76602c9a28e81d788dd6f4458e357ae269d5f1_62cdcb2c-c1f5-4f21-bc4c-ae24b7d5b910.webp?v=1713858264","width":2000},{"alt":null,"id":23789300023395,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267","width":2000},{"alt":null,"id":23789300645987,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/70d904d8f1cea4a0352e2c7f7dd8fe3c5f318120_452c2f39-51f1-46e0-857e-7d6c3216878a.webp?v=1713858269"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/70d904d8f1cea4a0352e2c7f7dd8fe3c5f318120_452c2f39-51f1-46e0-857e-7d6c3216878a.webp?v=1713858269","width":2000},{"alt":null,"id":23789301399651,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8fd46e01578d804273b4281ec969142b6d9b83d8_78b01fa8-1664-4e0f-8a0c-90bbea9b29d6.webp?v=1713858272"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8fd46e01578d804273b4281ec969142b6d9b83d8_78b01fa8-1664-4e0f-8a0c-90bbea9b29d6.webp?v=1713858272","width":2000},{"alt":null,"id":23789302055011,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6092117ea50a28e4adf2786ff4578ddc39ed90c5_36db8625-7f1a-4849-bb29-3a0e1077f4ab.webp?v=1713858275"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6092117ea50a28e4adf2786ff4578ddc39ed90c5_36db8625-7f1a-4849-bb29-3a0e1077f4ab.webp?v=1713858275","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41793575452771,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PL63","requires_shipping":true,"taxable":true,"featured_image":{"id":31387061387363,"product_id":7369203613795,"position":7,"created_at":"2024-04-23T15:44:27+08:00","updated_at":"2024-04-23T15:44:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267","variant_ids":[41793575452771]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Snoopy 史努比 - 曬太陽 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-PL63","featured_media":{"alt":null,"id":23789300023395,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41793575452771,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PL63","requires_shipping":true,"taxable":true,"featured_image":{"id":31387061387363,"product_id":7369203613795,"position":7,"created_at":"2024-04-23T15:44:27+08:00","updated_at":"2024-04-23T15:44:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267","variant_ids":[41793575452771]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Snoopy 史努比 - 曬太陽 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-PL63","featured_media":{"alt":null,"id":23789300023395,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ece25b6f98f6968c859da3c2eb1a30e32e289868_f000241d-4cac-48c6-91f3-0987620c6d0b.webp?v=1713858267"}},"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: "停產" }