$product = {"id":7415941628003,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 史迪奇 - 搞怪系列-怪可愛","handle":"iphone-xs-max-mod-nx-printable-yf02","description":null,"published_at":"2024-06-11T16:48:30+08:00","created_at":"2024-05-06T12:28:57+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 XS 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":41915759100003,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-YF02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490792489059,"product_id":7415941628003,"position":3,"created_at":"2024-05-06T12:29:05+08:00","updated_at":"2024-05-06T12:29:05+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745","variant_ids":[41915759100003]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS 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":"NPB0108624-YF02","featured_media":{"alt":null,"id":23896199331939,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04ea7d168a67065b4e7da5bfb4b23ba01e08b3d_7843899c-daba-4c3b-8b0f-53e2cbdc6f4f.webp?v=1714969740","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96af83a56224a9920064b534a7b0d96ea4cb4fa4_b683945d-e8a4-41bc-ba31-c8a909b33381.webp?v=1714969743","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/263d30fc5c5395fdfca74ff03aa8fbaf90291ab6_740b5ecf-e911-42e0-8a33-db15e37fd2a2.webp?v=1714969748","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8de535a81f965650752360bf163585da80965a63_bc4c6257-ef67-4605-98ed-1307722a9e75.webp?v=1714969750","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ba09e1390ed9f274199095c006ccec777d9316db_02c134da-b4c6-4296-b79f-64a838b6a02a.webp?v=1714969752","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11f24ad0946abd065789ac1f528a7f62c4c0fde8_f51b4d33-8921-42ac-88cf-d4abd89ae077.webp?v=1714969755","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/26fe22d64666df5814217d5878d320f60fe42bf1_966750ae-2451-4f2a-b752-e53c4cca37f3.webp?v=1714969757","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0001e442fb73b10307e698f810e04bd295ed1c70_0b39cd6f-329c-4a7a-825d-d5048b1ad0ee.webp?v=1714969760","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c911d1d157c4480b0951e125921b5cfa9663a710_ebe09c50-42be-411b-b498-6fc469533dfd.webp?v=1714969762"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04ea7d168a67065b4e7da5bfb4b23ba01e08b3d_7843899c-daba-4c3b-8b0f-53e2cbdc6f4f.webp?v=1714969740","options":["color"],"media":[{"alt":null,"id":23896198217827,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04ea7d168a67065b4e7da5bfb4b23ba01e08b3d_7843899c-daba-4c3b-8b0f-53e2cbdc6f4f.webp?v=1714969740"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04ea7d168a67065b4e7da5bfb4b23ba01e08b3d_7843899c-daba-4c3b-8b0f-53e2cbdc6f4f.webp?v=1714969740","width":2000},{"alt":null,"id":23896198611043,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96af83a56224a9920064b534a7b0d96ea4cb4fa4_b683945d-e8a4-41bc-ba31-c8a909b33381.webp?v=1714969743"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96af83a56224a9920064b534a7b0d96ea4cb4fa4_b683945d-e8a4-41bc-ba31-c8a909b33381.webp?v=1714969743","width":2000},{"alt":null,"id":23896199331939,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745","width":2000},{"alt":null,"id":23896199757923,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/263d30fc5c5395fdfca74ff03aa8fbaf90291ab6_740b5ecf-e911-42e0-8a33-db15e37fd2a2.webp?v=1714969748"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/263d30fc5c5395fdfca74ff03aa8fbaf90291ab6_740b5ecf-e911-42e0-8a33-db15e37fd2a2.webp?v=1714969748","width":2000},{"alt":null,"id":23896200740963,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8de535a81f965650752360bf163585da80965a63_bc4c6257-ef67-4605-98ed-1307722a9e75.webp?v=1714969750"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8de535a81f965650752360bf163585da80965a63_bc4c6257-ef67-4605-98ed-1307722a9e75.webp?v=1714969750","width":2000},{"alt":null,"id":23896201068643,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ba09e1390ed9f274199095c006ccec777d9316db_02c134da-b4c6-4296-b79f-64a838b6a02a.webp?v=1714969752"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ba09e1390ed9f274199095c006ccec777d9316db_02c134da-b4c6-4296-b79f-64a838b6a02a.webp?v=1714969752","width":2000},{"alt":null,"id":23896201527395,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11f24ad0946abd065789ac1f528a7f62c4c0fde8_f51b4d33-8921-42ac-88cf-d4abd89ae077.webp?v=1714969755"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11f24ad0946abd065789ac1f528a7f62c4c0fde8_f51b4d33-8921-42ac-88cf-d4abd89ae077.webp?v=1714969755","width":2000},{"alt":null,"id":23896202117219,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/26fe22d64666df5814217d5878d320f60fe42bf1_966750ae-2451-4f2a-b752-e53c4cca37f3.webp?v=1714969757"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/26fe22d64666df5814217d5878d320f60fe42bf1_966750ae-2451-4f2a-b752-e53c4cca37f3.webp?v=1714969757","width":2000},{"alt":null,"id":23896203165795,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0001e442fb73b10307e698f810e04bd295ed1c70_0b39cd6f-329c-4a7a-825d-d5048b1ad0ee.webp?v=1714969760"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0001e442fb73b10307e698f810e04bd295ed1c70_0b39cd6f-329c-4a7a-825d-d5048b1ad0ee.webp?v=1714969760","width":2000},{"alt":null,"id":23896204148835,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c911d1d157c4480b0951e125921b5cfa9663a710_ebe09c50-42be-411b-b498-6fc469533dfd.webp?v=1714969762"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c911d1d157c4480b0951e125921b5cfa9663a710_ebe09c50-42be-411b-b498-6fc469533dfd.webp?v=1714969762","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41915759100003,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-YF02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490792489059,"product_id":7415941628003,"position":3,"created_at":"2024-05-06T12:29:05+08:00","updated_at":"2024-05-06T12:29:05+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745","variant_ids":[41915759100003]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS 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":"NPB0108624-YF02","featured_media":{"alt":null,"id":23896199331939,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41915759100003,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-YF02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490792489059,"product_id":7415941628003,"position":3,"created_at":"2024-05-06T12:29:05+08:00","updated_at":"2024-05-06T12:29:05+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745","variant_ids":[41915759100003]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS 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":"NPB0108624-YF02","featured_media":{"alt":null,"id":23896199331939,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e6d9991409bee9fd287a844930e033b6f46b8df_54d64b2f-b3ce-416c-9b49-cfa91c97591d.webp?v=1714969745"}},"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: "停產" }