$product = {"id":7407983624291,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具1-黑","handle":"iphone-14-plus-mod-nx-printable-pb09","description":null,"published_at":"2024-06-11T16:28:18+08:00","created_at":"2024-05-03T11:28:31+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 14 Plus","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-star-wars","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":41881375113315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31470869839971,"product_id":7407983624291,"position":1,"created_at":"2024-05-03T11:28:34+08:00","updated_at":"2024-05-03T11:28:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","variant_ids":[41881375113315]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具1-黑 - 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":"NPB0126124-PB09","featured_media":{"alt":null,"id":23875774480483,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0196f68c7b6dae0b571170fce4d333a8165dfab4_a96eda35-0aee-444c-bec1-f915ddbf5b07.webp?v=1714706916","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/92f9b22319dc9f1c6b01592ad53c3adad814acdc_31a96c58-0adb-46fe-b70d-a3456202743a.webp?v=1714706919","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31f1f1536a75c3143bec4cea7c0ee54585736b41_1c5d2c6f-91b4-46e6-a7ad-c24ced4724df.webp?v=1714706921","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bcb3bea718876da8a7b0037619bd7ffaa2c55b37_e4ffcbc4-9b7f-4fc2-8405-a04326b9a668.webp?v=1714706923","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c9ec5b8c795835bf4d866a7694bdb64ec3cfb66_9bc1cc5a-46bb-4e10-b4fb-bc634beebdd7.webp?v=1714706926","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1a55feedc92fe27077afd4f9736c6c372fbebb5_d41badff-1138-4a99-9fd9-45c1eae609a6.webp?v=1714706928","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/093a457f4d3622a3933051baf82b642e02b68ffb_d6ec7a61-d1c9-4763-9579-13a14a7332b8.webp?v=1714706930","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb3dee34a8367ee4f5dd02b3f4c4212908afae1c_5b4adcf4-4e63-4c86-a6af-3f42b503443f.webp?v=1714706933","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a349d6a8981b8962c6c1d6a7da236a9916ac98ba_d1a760ad-bf16-40e5-9a41-6d226c84838e.webp?v=1714706936"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","options":["color"],"media":[{"alt":null,"id":23875774480483,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","width":2000},{"alt":null,"id":23875774972003,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0196f68c7b6dae0b571170fce4d333a8165dfab4_a96eda35-0aee-444c-bec1-f915ddbf5b07.webp?v=1714706916"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0196f68c7b6dae0b571170fce4d333a8165dfab4_a96eda35-0aee-444c-bec1-f915ddbf5b07.webp?v=1714706916","width":2000},{"alt":null,"id":23875775561827,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/92f9b22319dc9f1c6b01592ad53c3adad814acdc_31a96c58-0adb-46fe-b70d-a3456202743a.webp?v=1714706919"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/92f9b22319dc9f1c6b01592ad53c3adad814acdc_31a96c58-0adb-46fe-b70d-a3456202743a.webp?v=1714706919","width":2000},{"alt":null,"id":23875775922275,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31f1f1536a75c3143bec4cea7c0ee54585736b41_1c5d2c6f-91b4-46e6-a7ad-c24ced4724df.webp?v=1714706921"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31f1f1536a75c3143bec4cea7c0ee54585736b41_1c5d2c6f-91b4-46e6-a7ad-c24ced4724df.webp?v=1714706921","width":2000},{"alt":null,"id":23875776381027,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bcb3bea718876da8a7b0037619bd7ffaa2c55b37_e4ffcbc4-9b7f-4fc2-8405-a04326b9a668.webp?v=1714706923"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bcb3bea718876da8a7b0037619bd7ffaa2c55b37_e4ffcbc4-9b7f-4fc2-8405-a04326b9a668.webp?v=1714706923","width":2000},{"alt":null,"id":23875776905315,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c9ec5b8c795835bf4d866a7694bdb64ec3cfb66_9bc1cc5a-46bb-4e10-b4fb-bc634beebdd7.webp?v=1714706926"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c9ec5b8c795835bf4d866a7694bdb64ec3cfb66_9bc1cc5a-46bb-4e10-b4fb-bc634beebdd7.webp?v=1714706926","width":2000},{"alt":null,"id":23875777364067,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1a55feedc92fe27077afd4f9736c6c372fbebb5_d41badff-1138-4a99-9fd9-45c1eae609a6.webp?v=1714706928"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1a55feedc92fe27077afd4f9736c6c372fbebb5_d41badff-1138-4a99-9fd9-45c1eae609a6.webp?v=1714706928","width":2000},{"alt":null,"id":23875779068003,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/093a457f4d3622a3933051baf82b642e02b68ffb_d6ec7a61-d1c9-4763-9579-13a14a7332b8.webp?v=1714706930"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/093a457f4d3622a3933051baf82b642e02b68ffb_d6ec7a61-d1c9-4763-9579-13a14a7332b8.webp?v=1714706930","width":2000},{"alt":null,"id":23875779723363,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb3dee34a8367ee4f5dd02b3f4c4212908afae1c_5b4adcf4-4e63-4c86-a6af-3f42b503443f.webp?v=1714706933"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb3dee34a8367ee4f5dd02b3f4c4212908afae1c_5b4adcf4-4e63-4c86-a6af-3f42b503443f.webp?v=1714706933","width":2000},{"alt":null,"id":23875780116579,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a349d6a8981b8962c6c1d6a7da236a9916ac98ba_d1a760ad-bf16-40e5-9a41-6d226c84838e.webp?v=1714706936"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a349d6a8981b8962c6c1d6a7da236a9916ac98ba_d1a760ad-bf16-40e5-9a41-6d226c84838e.webp?v=1714706936","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41881375113315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31470869839971,"product_id":7407983624291,"position":1,"created_at":"2024-05-03T11:28:34+08:00","updated_at":"2024-05-03T11:28:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","variant_ids":[41881375113315]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具1-黑 - 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":"NPB0126124-PB09","featured_media":{"alt":null,"id":23875774480483,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41881375113315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31470869839971,"product_id":7407983624291,"position":1,"created_at":"2024-05-03T11:28:34+08:00","updated_at":"2024-05-03T11:28:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914","variant_ids":[41881375113315]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具1-黑 - 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":"NPB0126124-PB09","featured_media":{"alt":null,"id":23875774480483,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2a3a80f2f99e68ec1561178cd98b4792d051707_1fdf7070-46e9-4b9c-92db-8fc905fbdc9e.webp?v=1714706914"}},"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: "停產" }