$product = {"id":7408528621667,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 熱帶音樂系列-慶祝","handle":"iphone-12-pro-max-mod-nx-printable-yf04","description":null,"published_at":"2024-06-11T16:39:47+08:00","created_at":"2024-05-03T15:44:21+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-史迪奇","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-stitch","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-stitch","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":41886519459939,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31472508502115,"product_id":7408528621667,"position":4,"created_at":"2024-05-03T15:44:31+08:00","updated_at":"2024-05-03T15:44:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271","variant_ids":[41886519459939]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 熱帶音樂系列-慶祝 - 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-YF04","featured_media":{"alt":null,"id":23877425758307,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b88924abcd71a9f85cbe2d34d1017f59b40a331d_1bb7efac-9c58-497d-a905-d0a58409769f.webp?v=1714722264","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b3d43e32476d003f3dd8b7901b6ff8070e1754c_af7c385a-98f3-456a-855c-c0ca6ff64d53.webp?v=1714722266","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51028fccbf9cd8f2cb1ef379a9daa117760eaff6_b581f03f-24f6-445a-87f7-989890120905.webp?v=1714722269","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cdbc9aa93bca8df34f679f2e9404f46954d8ddc6_7f8d2a89-457c-4411-8c42-85e09820070a.webp?v=1714722274","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afca3b937822627cae27320e39dda3f4892c9e65_02ad49f8-506f-46ba-8789-8b564a51f516.webp?v=1714722276","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbc9196e22615881c63f81e26cc441fc471b6cd0_8cf80b62-cf83-4ec5-a5f9-594e056109af.webp?v=1714722279","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/395e0fbfddef0d98b83d87fc0552210deccc7e30_50ebdd5e-dea2-4fdb-83f5-1b7700ae0b86.webp?v=1714722281","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11b8317e54dd5427624d0f396df52f0c27c00227_15f85755-c48e-44fb-a9f1-0741a10d5c0a.webp?v=1714722283","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2dbf32044b5b7d0ef8fcc158861185201af3042d_bb3420fd-cd8c-4d86-a2af-859915d7e941.webp?v=1714722286"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b88924abcd71a9f85cbe2d34d1017f59b40a331d_1bb7efac-9c58-497d-a905-d0a58409769f.webp?v=1714722264","options":["color"],"media":[{"alt":null,"id":23877424349283,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b88924abcd71a9f85cbe2d34d1017f59b40a331d_1bb7efac-9c58-497d-a905-d0a58409769f.webp?v=1714722264"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b88924abcd71a9f85cbe2d34d1017f59b40a331d_1bb7efac-9c58-497d-a905-d0a58409769f.webp?v=1714722264","width":2000},{"alt":null,"id":23877424971875,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b3d43e32476d003f3dd8b7901b6ff8070e1754c_af7c385a-98f3-456a-855c-c0ca6ff64d53.webp?v=1714722266"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b3d43e32476d003f3dd8b7901b6ff8070e1754c_af7c385a-98f3-456a-855c-c0ca6ff64d53.webp?v=1714722266","width":2000},{"alt":null,"id":23877425332323,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51028fccbf9cd8f2cb1ef379a9daa117760eaff6_b581f03f-24f6-445a-87f7-989890120905.webp?v=1714722269"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51028fccbf9cd8f2cb1ef379a9daa117760eaff6_b581f03f-24f6-445a-87f7-989890120905.webp?v=1714722269","width":2000},{"alt":null,"id":23877425758307,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271","width":2000},{"alt":null,"id":23877426184291,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cdbc9aa93bca8df34f679f2e9404f46954d8ddc6_7f8d2a89-457c-4411-8c42-85e09820070a.webp?v=1714722274"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cdbc9aa93bca8df34f679f2e9404f46954d8ddc6_7f8d2a89-457c-4411-8c42-85e09820070a.webp?v=1714722274","width":2000},{"alt":null,"id":23877426643043,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afca3b937822627cae27320e39dda3f4892c9e65_02ad49f8-506f-46ba-8789-8b564a51f516.webp?v=1714722276"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afca3b937822627cae27320e39dda3f4892c9e65_02ad49f8-506f-46ba-8789-8b564a51f516.webp?v=1714722276","width":2000},{"alt":null,"id":23877427101795,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbc9196e22615881c63f81e26cc441fc471b6cd0_8cf80b62-cf83-4ec5-a5f9-594e056109af.webp?v=1714722279"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbc9196e22615881c63f81e26cc441fc471b6cd0_8cf80b62-cf83-4ec5-a5f9-594e056109af.webp?v=1714722279","width":2000},{"alt":null,"id":23877427560547,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/395e0fbfddef0d98b83d87fc0552210deccc7e30_50ebdd5e-dea2-4fdb-83f5-1b7700ae0b86.webp?v=1714722281"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/395e0fbfddef0d98b83d87fc0552210deccc7e30_50ebdd5e-dea2-4fdb-83f5-1b7700ae0b86.webp?v=1714722281","width":2000},{"alt":null,"id":23877428314211,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11b8317e54dd5427624d0f396df52f0c27c00227_15f85755-c48e-44fb-a9f1-0741a10d5c0a.webp?v=1714722283"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11b8317e54dd5427624d0f396df52f0c27c00227_15f85755-c48e-44fb-a9f1-0741a10d5c0a.webp?v=1714722283","width":2000},{"alt":null,"id":23877428740195,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2dbf32044b5b7d0ef8fcc158861185201af3042d_bb3420fd-cd8c-4d86-a2af-859915d7e941.webp?v=1714722286"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2dbf32044b5b7d0ef8fcc158861185201af3042d_bb3420fd-cd8c-4d86-a2af-859915d7e941.webp?v=1714722286","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886519459939,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31472508502115,"product_id":7408528621667,"position":4,"created_at":"2024-05-03T15:44:31+08:00","updated_at":"2024-05-03T15:44:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271","variant_ids":[41886519459939]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 熱帶音樂系列-慶祝 - 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-YF04","featured_media":{"alt":null,"id":23877425758307,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886519459939,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31472508502115,"product_id":7408528621667,"position":4,"created_at":"2024-05-03T15:44:31+08:00","updated_at":"2024-05-03T15:44:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271","variant_ids":[41886519459939]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 熱帶音樂系列-慶祝 - 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-YF04","featured_media":{"alt":null,"id":23877425758307,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d62e0e8333553c3d1e6865c8c71e29e7ef8ffa96_fdc5d4bd-9e97-46c5-aedd-051ba1e46da0.webp?v=1714722271"}},"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: "停產" }