$product = {"id":7411442614371,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 大自然的傑作(亞馬遜雨林)","handle":"iphone-14-plus-mod-nx-magsafe-printable-af09","description":null,"published_at":"2024-06-11T17:45:08+08:00","created_at":"2024-05-05T00:30:45+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Look","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-look","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-look","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":41898952196195,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480437375075,"product_id":7411442614371,"position":4,"created_at":"2024-05-05T00:30:55+08:00","updated_at":"2024-05-05T00:30:55+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255","variant_ids":[41898952196195]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 大自然的傑作(亞馬遜雨林) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF09","featured_media":{"alt":null,"id":23885689094243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3533839274333f58bd36785e704f18d66978f68a_f1691791-87a6-4ec9-b15c-dbfc0757f3a7.webp?v=1714840248","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/140dc91627f37260c0c4f154b5eca41dc55cffbb_c0fc3f55-a854-4f49-84b0-f835ef17efc8.webp?v=1714840250","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d6005e0480d67eaeed8201f0f762ba796053aae_73dd19a9-bd72-43f1-ac5a-960ef827ff79.webp?v=1714840252","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/827cbf4c65daf864b79f06f0845f2caa383e033d_2ee8e323-7cd2-4076-956f-45a65d6a645f.webp?v=1714840258","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6311a6256d74ac16cfcc494693d787f12b38cdb8_bd257a14-9751-44a9-b930-7a3514b9edeb.webp?v=1714840260","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb7edf2f09ef8cfe061eb155b62616a72aad61b4_4a7f3591-7703-425c-bb09-94648a46830d.webp?v=1714840262","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9131a82627fb03f3a602d7055b41cfc3f53f567_274fd9ce-4466-4394-bbb0-187dccac30cc.webp?v=1714840265","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb6da3dc30c2ccf9e1d3f889d201667648388bf6_b9f19beb-a9b2-4bf3-b489-ba59ba7f6d22.webp?v=1714840267","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab63de44b83f9da167d8a518e51535786c64d3d_98ffb6b3-3e38-4c19-8d76-9909354e5c56.webp?v=1714840270"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3533839274333f58bd36785e704f18d66978f68a_f1691791-87a6-4ec9-b15c-dbfc0757f3a7.webp?v=1714840248","options":["color"],"media":[{"alt":null,"id":23885687783523,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3533839274333f58bd36785e704f18d66978f68a_f1691791-87a6-4ec9-b15c-dbfc0757f3a7.webp?v=1714840248"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3533839274333f58bd36785e704f18d66978f68a_f1691791-87a6-4ec9-b15c-dbfc0757f3a7.webp?v=1714840248","width":2000},{"alt":null,"id":23885688242275,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/140dc91627f37260c0c4f154b5eca41dc55cffbb_c0fc3f55-a854-4f49-84b0-f835ef17efc8.webp?v=1714840250"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/140dc91627f37260c0c4f154b5eca41dc55cffbb_c0fc3f55-a854-4f49-84b0-f835ef17efc8.webp?v=1714840250","width":2000},{"alt":null,"id":23885688569955,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d6005e0480d67eaeed8201f0f762ba796053aae_73dd19a9-bd72-43f1-ac5a-960ef827ff79.webp?v=1714840252"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d6005e0480d67eaeed8201f0f762ba796053aae_73dd19a9-bd72-43f1-ac5a-960ef827ff79.webp?v=1714840252","width":2000},{"alt":null,"id":23885689094243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255","width":2000},{"alt":null,"id":23885689618531,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/827cbf4c65daf864b79f06f0845f2caa383e033d_2ee8e323-7cd2-4076-956f-45a65d6a645f.webp?v=1714840258"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/827cbf4c65daf864b79f06f0845f2caa383e033d_2ee8e323-7cd2-4076-956f-45a65d6a645f.webp?v=1714840258","width":2000},{"alt":null,"id":23885690077283,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6311a6256d74ac16cfcc494693d787f12b38cdb8_bd257a14-9751-44a9-b930-7a3514b9edeb.webp?v=1714840260"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6311a6256d74ac16cfcc494693d787f12b38cdb8_bd257a14-9751-44a9-b930-7a3514b9edeb.webp?v=1714840260","width":2000},{"alt":null,"id":23885690634339,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb7edf2f09ef8cfe061eb155b62616a72aad61b4_4a7f3591-7703-425c-bb09-94648a46830d.webp?v=1714840262"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb7edf2f09ef8cfe061eb155b62616a72aad61b4_4a7f3591-7703-425c-bb09-94648a46830d.webp?v=1714840262","width":2000},{"alt":null,"id":23885691093091,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9131a82627fb03f3a602d7055b41cfc3f53f567_274fd9ce-4466-4394-bbb0-187dccac30cc.webp?v=1714840265"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9131a82627fb03f3a602d7055b41cfc3f53f567_274fd9ce-4466-4394-bbb0-187dccac30cc.webp?v=1714840265","width":2000},{"alt":null,"id":23885691617379,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb6da3dc30c2ccf9e1d3f889d201667648388bf6_b9f19beb-a9b2-4bf3-b489-ba59ba7f6d22.webp?v=1714840267"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/eb6da3dc30c2ccf9e1d3f889d201667648388bf6_b9f19beb-a9b2-4bf3-b489-ba59ba7f6d22.webp?v=1714840267","width":2000},{"alt":null,"id":23885692600419,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab63de44b83f9da167d8a518e51535786c64d3d_98ffb6b3-3e38-4c19-8d76-9909354e5c56.webp?v=1714840270"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab63de44b83f9da167d8a518e51535786c64d3d_98ffb6b3-3e38-4c19-8d76-9909354e5c56.webp?v=1714840270","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41898952196195,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480437375075,"product_id":7411442614371,"position":4,"created_at":"2024-05-05T00:30:55+08:00","updated_at":"2024-05-05T00:30:55+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255","variant_ids":[41898952196195]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 大自然的傑作(亞馬遜雨林) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF09","featured_media":{"alt":null,"id":23885689094243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41898952196195,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480437375075,"product_id":7411442614371,"position":4,"created_at":"2024-05-05T00:30:55+08:00","updated_at":"2024-05-05T00:30:55+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255","variant_ids":[41898952196195]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 大自然的傑作(亞馬遜雨林) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF09","featured_media":{"alt":null,"id":23885689094243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a7b7b0439583f604c1f0f538fe583279857752a_3318411c-3cde-4ffa-98b8-83166c59c0e2.webp?v=1714840255"}},"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: "停產" }