$product = {"id":7369170747491,"title":"犀牛盾Mod NX手機殼 - iPhone 11 Pro Max - 【聯名設計款】 - Snoopy 史努比 - 夏日活動","handle":"iphone-11-pro-max-mod-nx-printable-pl61","description":"","published_at":"2024-06-11T16:13:44+08:00","created_at":"2024-04-23T15:37:29+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Snoopy 史努比","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-snoopy","device-iPhone 11 Pro Max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-snoopy","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":41793253408867,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0114924-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31386969702499,"product_id":7369170747491,"position":1,"created_at":"2024-04-23T15:37:32+08:00","updated_at":"2025-01-22T15:00:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","variant_ids":[41793253408867]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 11 Pro Max - 【聯名設計款】 - Snoopy 史努比 - 夏日活動 - 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":"NPB0114924-PL61","featured_media":{"alt":null,"id":23789207945315,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335dc820b3f1c04df73097287f774ae81fe2c0e7_8d8f25db-03a6-4b34-8855-d95473553b83.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/352463b659393ebc9a71ddde484a65bcb82e6abf_4044897e-3427-42ae-9bb5-02e2f8a705e0.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be4fff2adcc5e09a10ab81f6abc697d2caea8ece_5a9ef22a-447b-4aed-b670-09463b5c3b08.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c951bd1a8f3b98d0d242f4a5ec4df3aa3dd89b0a_1d367773-3807-471b-9167-77aaf2e5e131.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ce3db5e2249f30b2ad0f89749c5519f2a51faad_dfba6671-5449-4578-87f3-95e8ab79d79b.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e2612ac7bc90679e8a2d0861c5ebc40a81bf3d4_e425ca1f-8b66-4f33-9dad-9dcf988a98db.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c1ba2d25a057922908e2a85f54b707580fc16c18_2c124a0e-674b-4f8e-ad3a-779ae1b378f8.webp?v=1737529240","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/990dc58001eb52fa1b0054edbf360775d10dfa7b_083236ca-2032-4992-928d-e601f39be8fd.webp?v=1737529240"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","options":["color"],"media":[{"alt":null,"id":23789207945315,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","width":2000},{"alt":null,"id":23789208404067,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335dc820b3f1c04df73097287f774ae81fe2c0e7_8d8f25db-03a6-4b34-8855-d95473553b83.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335dc820b3f1c04df73097287f774ae81fe2c0e7_8d8f25db-03a6-4b34-8855-d95473553b83.webp?v=1737529240","width":2000},{"alt":null,"id":23789210468451,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/352463b659393ebc9a71ddde484a65bcb82e6abf_4044897e-3427-42ae-9bb5-02e2f8a705e0.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/352463b659393ebc9a71ddde484a65bcb82e6abf_4044897e-3427-42ae-9bb5-02e2f8a705e0.webp?v=1737529240","width":2000},{"alt":null,"id":23789211091043,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be4fff2adcc5e09a10ab81f6abc697d2caea8ece_5a9ef22a-447b-4aed-b670-09463b5c3b08.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be4fff2adcc5e09a10ab81f6abc697d2caea8ece_5a9ef22a-447b-4aed-b670-09463b5c3b08.webp?v=1737529240","width":2000},{"alt":null,"id":23789211779171,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c951bd1a8f3b98d0d242f4a5ec4df3aa3dd89b0a_1d367773-3807-471b-9167-77aaf2e5e131.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c951bd1a8f3b98d0d242f4a5ec4df3aa3dd89b0a_1d367773-3807-471b-9167-77aaf2e5e131.webp?v=1737529240","width":2000},{"alt":null,"id":23789213188195,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ce3db5e2249f30b2ad0f89749c5519f2a51faad_dfba6671-5449-4578-87f3-95e8ab79d79b.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ce3db5e2249f30b2ad0f89749c5519f2a51faad_dfba6671-5449-4578-87f3-95e8ab79d79b.webp?v=1737529240","width":2000},{"alt":null,"id":23789213876323,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e2612ac7bc90679e8a2d0861c5ebc40a81bf3d4_e425ca1f-8b66-4f33-9dad-9dcf988a98db.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e2612ac7bc90679e8a2d0861c5ebc40a81bf3d4_e425ca1f-8b66-4f33-9dad-9dcf988a98db.webp?v=1737529240","width":2000},{"alt":null,"id":25221968560227,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c1ba2d25a057922908e2a85f54b707580fc16c18_2c124a0e-674b-4f8e-ad3a-779ae1b378f8.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c1ba2d25a057922908e2a85f54b707580fc16c18_2c124a0e-674b-4f8e-ad3a-779ae1b378f8.webp?v=1737529240","width":2000},{"alt":null,"id":23789215088739,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/990dc58001eb52fa1b0054edbf360775d10dfa7b_083236ca-2032-4992-928d-e601f39be8fd.webp?v=1737529240"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/990dc58001eb52fa1b0054edbf360775d10dfa7b_083236ca-2032-4992-928d-e601f39be8fd.webp?v=1737529240","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":""}; $isMerge = null; $variants = [{"id":41793253408867,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0114924-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31386969702499,"product_id":7369170747491,"position":1,"created_at":"2024-04-23T15:37:32+08:00","updated_at":"2025-01-22T15:00:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","variant_ids":[41793253408867]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 11 Pro Max - 【聯名設計款】 - Snoopy 史努比 - 夏日活動 - 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":"NPB0114924-PL61","featured_media":{"alt":null,"id":23789207945315,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41793253408867,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0114924-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31386969702499,"product_id":7369170747491,"position":1,"created_at":"2024-04-23T15:37:32+08:00","updated_at":"2025-01-22T15:00:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240","variant_ids":[41793253408867]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 11 Pro Max - 【聯名設計款】 - Snoopy 史努比 - 夏日活動 - 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":"NPB0114924-PL61","featured_media":{"alt":null,"id":23789207945315,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0098a373a7764f6f85d4315477cc0edd29416bf_9c1fb9ce-2191-4147-998e-9b8008245354.webp?v=1737529240"}},"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: "停產" }