$product = {"id":7407794716771,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 黑武士-經典","handle":"iphone-14-plus-mod-nx-printable-pb23","description":null,"published_at":"2024-06-11T16:23:16+08:00","created_at":"2024-05-03T10:52:22+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":41878924918883,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB23","requires_shipping":true,"taxable":true,"featured_image":{"id":31470397915235,"product_id":7407794716771,"position":10,"created_at":"2024-05-03T10:52:46+08:00","updated_at":"2024-05-03T10:52:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766","variant_ids":[41878924918883]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 黑武士-經典 - 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-PB23","featured_media":{"alt":null,"id":23875301212259,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0784e179935fdc10c8e98f4ef5c5e1342d4b474_ef4d2e2a-3abc-4fb4-ae3a-8759341db56d.webp?v=1714704745","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa1cca4ea8912a9373be1d17e8b5325133a278b4_362396f1-99c0-454c-bb83-bdbe08e1b37b.webp?v=1714704747","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/09b3213414307d97e5d76b2d9614eef804a60acd_1d31b0d7-744b-422e-8e89-8e67464b56c5.webp?v=1714704750","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c10a4952cddb7f3aea1ed7338d82455a9d6c68c3_e8cc0511-a843-4b1e-8c2a-0993286d5bbf.webp?v=1714704752","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b97e57d694e9059df361203dd4dc2e0a3b7e662_9d276ef9-e073-4c21-9072-b255c021e896.webp?v=1714704754","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5729fb57e9f27a9c58883d3cf8429853d4b2876_6dfc6544-daf5-4189-804f-03e178a698d7.webp?v=1714704757","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a33e773bcfe166b51bc5146fcfbf1d1cec026998_121d775f-2c89-4dc7-89aa-1c977d3d5c85.webp?v=1714704759","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c9193f69263d235b083a5105b8f5a096d9dbf320_606aed0a-9b83-4e98-8660-617d0d2bae94.webp?v=1714704762","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f81b7b5780460aa3b62d97cbd50a82241ee9ef84_11882a6e-3208-4b84-8c20-f5b85b989fab.webp?v=1714704764","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0784e179935fdc10c8e98f4ef5c5e1342d4b474_ef4d2e2a-3abc-4fb4-ae3a-8759341db56d.webp?v=1714704745","options":["color"],"media":[{"alt":null,"id":23875296034915,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0784e179935fdc10c8e98f4ef5c5e1342d4b474_ef4d2e2a-3abc-4fb4-ae3a-8759341db56d.webp?v=1714704745"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0784e179935fdc10c8e98f4ef5c5e1342d4b474_ef4d2e2a-3abc-4fb4-ae3a-8759341db56d.webp?v=1714704745","width":2000},{"alt":null,"id":23875296395363,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa1cca4ea8912a9373be1d17e8b5325133a278b4_362396f1-99c0-454c-bb83-bdbe08e1b37b.webp?v=1714704747"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa1cca4ea8912a9373be1d17e8b5325133a278b4_362396f1-99c0-454c-bb83-bdbe08e1b37b.webp?v=1714704747","width":2000},{"alt":null,"id":23875296788579,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/09b3213414307d97e5d76b2d9614eef804a60acd_1d31b0d7-744b-422e-8e89-8e67464b56c5.webp?v=1714704750"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/09b3213414307d97e5d76b2d9614eef804a60acd_1d31b0d7-744b-422e-8e89-8e67464b56c5.webp?v=1714704750","width":2000},{"alt":null,"id":23875297706083,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c10a4952cddb7f3aea1ed7338d82455a9d6c68c3_e8cc0511-a843-4b1e-8c2a-0993286d5bbf.webp?v=1714704752"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c10a4952cddb7f3aea1ed7338d82455a9d6c68c3_e8cc0511-a843-4b1e-8c2a-0993286d5bbf.webp?v=1714704752","width":2000},{"alt":null,"id":23875298099299,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b97e57d694e9059df361203dd4dc2e0a3b7e662_9d276ef9-e073-4c21-9072-b255c021e896.webp?v=1714704754"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b97e57d694e9059df361203dd4dc2e0a3b7e662_9d276ef9-e073-4c21-9072-b255c021e896.webp?v=1714704754","width":2000},{"alt":null,"id":23875298525283,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5729fb57e9f27a9c58883d3cf8429853d4b2876_6dfc6544-daf5-4189-804f-03e178a698d7.webp?v=1714704757"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5729fb57e9f27a9c58883d3cf8429853d4b2876_6dfc6544-daf5-4189-804f-03e178a698d7.webp?v=1714704757","width":2000},{"alt":null,"id":23875299246179,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a33e773bcfe166b51bc5146fcfbf1d1cec026998_121d775f-2c89-4dc7-89aa-1c977d3d5c85.webp?v=1714704759"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a33e773bcfe166b51bc5146fcfbf1d1cec026998_121d775f-2c89-4dc7-89aa-1c977d3d5c85.webp?v=1714704759","width":2000},{"alt":null,"id":23875299868771,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c9193f69263d235b083a5105b8f5a096d9dbf320_606aed0a-9b83-4e98-8660-617d0d2bae94.webp?v=1714704762"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c9193f69263d235b083a5105b8f5a096d9dbf320_606aed0a-9b83-4e98-8660-617d0d2bae94.webp?v=1714704762","width":2000},{"alt":null,"id":23875300491363,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f81b7b5780460aa3b62d97cbd50a82241ee9ef84_11882a6e-3208-4b84-8c20-f5b85b989fab.webp?v=1714704764"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f81b7b5780460aa3b62d97cbd50a82241ee9ef84_11882a6e-3208-4b84-8c20-f5b85b989fab.webp?v=1714704764","width":2000},{"alt":null,"id":23875301212259,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41878924918883,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB23","requires_shipping":true,"taxable":true,"featured_image":{"id":31470397915235,"product_id":7407794716771,"position":10,"created_at":"2024-05-03T10:52:46+08:00","updated_at":"2024-05-03T10:52:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766","variant_ids":[41878924918883]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 黑武士-經典 - 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-PB23","featured_media":{"alt":null,"id":23875301212259,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41878924918883,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB23","requires_shipping":true,"taxable":true,"featured_image":{"id":31470397915235,"product_id":7407794716771,"position":10,"created_at":"2024-05-03T10:52:46+08:00","updated_at":"2024-05-03T10:52:46+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766","variant_ids":[41878924918883]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 黑武士-經典 - 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-PB23","featured_media":{"alt":null,"id":23875301212259,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/53a01cde859b6dba6caa008e64e592057115ea54_5e34755b-d956-4bb7-8365-96aa99b8c029.webp?v=1714704766"}},"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: "停產" }