$product = {"id":7416046714979,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 波巴費特-噴漆黑","handle":"iphone-xs-max-mod-nx-printable-pb05","description":null,"published_at":"2024-06-11T16:51:19+08:00","created_at":"2024-05-06T12:48:12+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 XS Max","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":41916864331875,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB05","requires_shipping":true,"taxable":true,"featured_image":{"id":31491074162787,"product_id":7416046714979,"position":10,"created_at":"2024-05-06T12:48:35+08:00","updated_at":"2024-05-06T12:48:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915","variant_ids":[41916864331875]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0108624-PB05","featured_media":{"alt":null,"id":23896481529955,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/132988ede850dd4362eb13d8c3d23df96463c1e7_e7d9968f-18e4-4ad7-bc12-6e7f719f26a4.webp?v=1714970895","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f79fbab45726aad599e5e486ed4fe6bf92e39d8_38b8fcf0-b26d-4a1b-9dcd-39ce5bfc9f05.webp?v=1714970897","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ae6946544bd8a2d80096f769fd0f531c9565c169_400e9aac-1466-4992-9965-9669ad5dcbb1.webp?v=1714970899","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf7b208c2c5eae0d17e679e6379e6a5abefc948_f08680ef-3b93-492f-b730-854a312aac5c.webp?v=1714970901","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be54abe06a2afa7ef75a5708e40f4c925bfbfb30_34a95da7-6fab-4da2-a7e9-4407722dbfe3.webp?v=1714970904","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/479ebc9d2176ab113ef91909f7e6ee8417133b67_059820f0-c338-4608-8949-d98f8ffc9870.webp?v=1714970906","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c5add2c4210bcffa2d096bccbd865ab3b49b677_b4c05b9e-5c09-44c8-b8da-e14abdfaf764.webp?v=1714970908","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d661974ac0200561556c9b8e3583ef67058c293e_85e59d02-8d13-47f2-bba7-cbebf7024329.webp?v=1714970911","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ede7477a52fc5236d688c1a41a7b283c10daf53_2c425ad4-2559-43f6-aee9-126bd71f3e05.webp?v=1714970913","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/132988ede850dd4362eb13d8c3d23df96463c1e7_e7d9968f-18e4-4ad7-bc12-6e7f719f26a4.webp?v=1714970895","options":["color"],"media":[{"alt":null,"id":23896476516451,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/132988ede850dd4362eb13d8c3d23df96463c1e7_e7d9968f-18e4-4ad7-bc12-6e7f719f26a4.webp?v=1714970895"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/132988ede850dd4362eb13d8c3d23df96463c1e7_e7d9968f-18e4-4ad7-bc12-6e7f719f26a4.webp?v=1714970895","width":2000},{"alt":null,"id":23896477827171,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f79fbab45726aad599e5e486ed4fe6bf92e39d8_38b8fcf0-b26d-4a1b-9dcd-39ce5bfc9f05.webp?v=1714970897"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f79fbab45726aad599e5e486ed4fe6bf92e39d8_38b8fcf0-b26d-4a1b-9dcd-39ce5bfc9f05.webp?v=1714970897","width":2000},{"alt":null,"id":23896478285923,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ae6946544bd8a2d80096f769fd0f531c9565c169_400e9aac-1466-4992-9965-9669ad5dcbb1.webp?v=1714970899"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ae6946544bd8a2d80096f769fd0f531c9565c169_400e9aac-1466-4992-9965-9669ad5dcbb1.webp?v=1714970899","width":2000},{"alt":null,"id":23896478711907,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf7b208c2c5eae0d17e679e6379e6a5abefc948_f08680ef-3b93-492f-b730-854a312aac5c.webp?v=1714970901"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbf7b208c2c5eae0d17e679e6379e6a5abefc948_f08680ef-3b93-492f-b730-854a312aac5c.webp?v=1714970901","width":2000},{"alt":null,"id":23896479170659,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be54abe06a2afa7ef75a5708e40f4c925bfbfb30_34a95da7-6fab-4da2-a7e9-4407722dbfe3.webp?v=1714970904"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be54abe06a2afa7ef75a5708e40f4c925bfbfb30_34a95da7-6fab-4da2-a7e9-4407722dbfe3.webp?v=1714970904","width":2000},{"alt":null,"id":23896479629411,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/479ebc9d2176ab113ef91909f7e6ee8417133b67_059820f0-c338-4608-8949-d98f8ffc9870.webp?v=1714970906"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/479ebc9d2176ab113ef91909f7e6ee8417133b67_059820f0-c338-4608-8949-d98f8ffc9870.webp?v=1714970906","width":2000},{"alt":null,"id":23896480153699,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c5add2c4210bcffa2d096bccbd865ab3b49b677_b4c05b9e-5c09-44c8-b8da-e14abdfaf764.webp?v=1714970908"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c5add2c4210bcffa2d096bccbd865ab3b49b677_b4c05b9e-5c09-44c8-b8da-e14abdfaf764.webp?v=1714970908","width":2000},{"alt":null,"id":23896480579683,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d661974ac0200561556c9b8e3583ef67058c293e_85e59d02-8d13-47f2-bba7-cbebf7024329.webp?v=1714970911"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d661974ac0200561556c9b8e3583ef67058c293e_85e59d02-8d13-47f2-bba7-cbebf7024329.webp?v=1714970911","width":2000},{"alt":null,"id":23896481169507,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ede7477a52fc5236d688c1a41a7b283c10daf53_2c425ad4-2559-43f6-aee9-126bd71f3e05.webp?v=1714970913"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ede7477a52fc5236d688c1a41a7b283c10daf53_2c425ad4-2559-43f6-aee9-126bd71f3e05.webp?v=1714970913","width":2000},{"alt":null,"id":23896481529955,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41916864331875,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB05","requires_shipping":true,"taxable":true,"featured_image":{"id":31491074162787,"product_id":7416046714979,"position":10,"created_at":"2024-05-06T12:48:35+08:00","updated_at":"2024-05-06T12:48:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915","variant_ids":[41916864331875]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0108624-PB05","featured_media":{"alt":null,"id":23896481529955,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41916864331875,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB05","requires_shipping":true,"taxable":true,"featured_image":{"id":31491074162787,"product_id":7416046714979,"position":10,"created_at":"2024-05-06T12:48:35+08:00","updated_at":"2024-05-06T12:48:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915","variant_ids":[41916864331875]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0108624-PB05","featured_media":{"alt":null,"id":23896481529955,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d0178c31bf4a83ff5b0da3e15b2ad17dbfbce0_ef3cc8ae-c509-4f4f-b050-93f4ee38ef4e.webp?v=1714970915"}},"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: "停產" }