$product = {"id":7408500703331,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 經典系列-Aloha!","handle":"iphone-12-pro-max-mod-nx-printable-yf08","description":null,"published_at":"2024-06-11T16:38:59+08:00","created_at":"2024-05-03T15:38:58+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":41886195515491,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF08","requires_shipping":true,"taxable":true,"featured_image":{"id":31472441000035,"product_id":7408500703331,"position":10,"created_at":"2024-05-03T15:39:20+08:00","updated_at":"2024-05-03T15:39:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960","variant_ids":[41886195515491]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 經典系列-Aloha! - 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-YF08","featured_media":{"alt":null,"id":23877358125155,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8d6f895923ca561d88162cba299d2e2a0018e36_543014b0-f780-4e63-b056-23b9062427f1.webp?v=1714721940","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1015fb76694c17c742445c4df77f84663f67b9ea_1ca697e3-34e5-49e2-848d-69890098bf6d.webp?v=1714721942","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3b0d901c3c6f54a31a8a373178032f7a8560455d_3a63e085-4e4e-47c0-b411-1e6a590b7e4e.webp?v=1714721944","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a27039bbba6f4c78bf31cfde159808cce65da19b_caad2a09-3078-412a-8dc6-2a2deadb2c20.webp?v=1714721947","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e058ec0266bce2a0337df3d2dbc587332560644_e9c62313-bc66-488f-9ac8-a2cf8c44c6c5.webp?v=1714721949","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84c3fb6b5624505d83af0f0f849b1ab5b33241e0_63d9972e-24bb-4f41-827a-95896905dcf9.webp?v=1714721951","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a1d42d2ef086f6779ff95e6798eecc448cb675ab_1cabf2c4-6eb0-4036-a8ea-f1edbb1c6b54.webp?v=1714721953","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6a6f93c3a4b86fc78448bd854a4767adddf5b3ac_e0d9eccb-9e2c-406c-b385-8faef5e2d47a.webp?v=1714721956","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d53c1f2654c59849a88c519878b8173e78d9bca6_7edaffe3-870e-49d2-a55c-ebb2f50b4c5e.webp?v=1714721958","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8d6f895923ca561d88162cba299d2e2a0018e36_543014b0-f780-4e63-b056-23b9062427f1.webp?v=1714721940","options":["color"],"media":[{"alt":null,"id":23877353570403,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8d6f895923ca561d88162cba299d2e2a0018e36_543014b0-f780-4e63-b056-23b9062427f1.webp?v=1714721940"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8d6f895923ca561d88162cba299d2e2a0018e36_543014b0-f780-4e63-b056-23b9062427f1.webp?v=1714721940","width":2000},{"alt":null,"id":23877354127459,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1015fb76694c17c742445c4df77f84663f67b9ea_1ca697e3-34e5-49e2-848d-69890098bf6d.webp?v=1714721942"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1015fb76694c17c742445c4df77f84663f67b9ea_1ca697e3-34e5-49e2-848d-69890098bf6d.webp?v=1714721942","width":2000},{"alt":null,"id":23877354455139,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3b0d901c3c6f54a31a8a373178032f7a8560455d_3a63e085-4e4e-47c0-b411-1e6a590b7e4e.webp?v=1714721944"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3b0d901c3c6f54a31a8a373178032f7a8560455d_3a63e085-4e4e-47c0-b411-1e6a590b7e4e.webp?v=1714721944","width":2000},{"alt":null,"id":23877355012195,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a27039bbba6f4c78bf31cfde159808cce65da19b_caad2a09-3078-412a-8dc6-2a2deadb2c20.webp?v=1714721947"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a27039bbba6f4c78bf31cfde159808cce65da19b_caad2a09-3078-412a-8dc6-2a2deadb2c20.webp?v=1714721947","width":2000},{"alt":null,"id":23877355405411,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e058ec0266bce2a0337df3d2dbc587332560644_e9c62313-bc66-488f-9ac8-a2cf8c44c6c5.webp?v=1714721949"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e058ec0266bce2a0337df3d2dbc587332560644_e9c62313-bc66-488f-9ac8-a2cf8c44c6c5.webp?v=1714721949","width":2000},{"alt":null,"id":23877355929699,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84c3fb6b5624505d83af0f0f849b1ab5b33241e0_63d9972e-24bb-4f41-827a-95896905dcf9.webp?v=1714721951"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84c3fb6b5624505d83af0f0f849b1ab5b33241e0_63d9972e-24bb-4f41-827a-95896905dcf9.webp?v=1714721951","width":2000},{"alt":null,"id":23877356585059,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a1d42d2ef086f6779ff95e6798eecc448cb675ab_1cabf2c4-6eb0-4036-a8ea-f1edbb1c6b54.webp?v=1714721953"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a1d42d2ef086f6779ff95e6798eecc448cb675ab_1cabf2c4-6eb0-4036-a8ea-f1edbb1c6b54.webp?v=1714721953","width":2000},{"alt":null,"id":23877357174883,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6a6f93c3a4b86fc78448bd854a4767adddf5b3ac_e0d9eccb-9e2c-406c-b385-8faef5e2d47a.webp?v=1714721956"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6a6f93c3a4b86fc78448bd854a4767adddf5b3ac_e0d9eccb-9e2c-406c-b385-8faef5e2d47a.webp?v=1714721956","width":2000},{"alt":null,"id":23877357502563,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d53c1f2654c59849a88c519878b8173e78d9bca6_7edaffe3-870e-49d2-a55c-ebb2f50b4c5e.webp?v=1714721958"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d53c1f2654c59849a88c519878b8173e78d9bca6_7edaffe3-870e-49d2-a55c-ebb2f50b4c5e.webp?v=1714721958","width":2000},{"alt":null,"id":23877358125155,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886195515491,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF08","requires_shipping":true,"taxable":true,"featured_image":{"id":31472441000035,"product_id":7408500703331,"position":10,"created_at":"2024-05-03T15:39:20+08:00","updated_at":"2024-05-03T15:39:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960","variant_ids":[41886195515491]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 經典系列-Aloha! - 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-YF08","featured_media":{"alt":null,"id":23877358125155,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886195515491,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-YF08","requires_shipping":true,"taxable":true,"featured_image":{"id":31472441000035,"product_id":7408500703331,"position":10,"created_at":"2024-05-03T15:39:20+08:00","updated_at":"2024-05-03T15:39:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960","variant_ids":[41886195515491]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 史迪奇 - 經典系列-Aloha! - 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-YF08","featured_media":{"alt":null,"id":23877358125155,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0722b36da23cb5406d3aa812dbe2814d3f1a286b_1802108c-08b1-4eec-9c8f-59cefb1c25bb.webp?v=1714721960"}},"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: "停產" }