$product = {"id":7416343658595,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-塗鴉藝術","handle":"iphone-8-mod-nx-printable-pb38","description":null,"published_at":"2024-06-11T16:56:27+08:00","created_at":"2024-05-06T14:38:28+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 8","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":41918707990627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB38","requires_shipping":true,"taxable":true,"featured_image":{"id":31491893428323,"product_id":7416343658595,"position":1,"created_at":"2024-05-06T14:38:30+08:00","updated_at":"2024-05-06T14:38:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","variant_ids":[41918707990627]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-塗鴉藝術 - 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":"NPB0105424-PB38","featured_media":{"alt":null,"id":23897306300515,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a177bd48d0e400ff506fc3df610d4acd5d66329c_82cce831-3ced-4545-8b94-64b8d35bd217.webp?v=1714977512","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b9803b9af7f61667d5e1ae6ee37e9b07e62ae43_daf1fd11-9238-4f22-8569-4ae905f02fce.webp?v=1714977514","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d315770fb51cb7e201cceb82c6ccc4ca686ee916_63c9e417-9e32-49b9-b692-feaec8fff36e.webp?v=1714977517","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c2e9fdd42378d56e16383a6481dbaef1f1057c2_e238aed0-67ff-44ff-bd87-20fd40453b0a.webp?v=1714977519","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0316c91d6dff1d540a6de77dd8510f0ee7c0a3_7b28aabe-6681-4fb5-a495-98115d260459.webp?v=1714977521","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7a197cc179fbf4a8608898708ab6644dfb00999a_408e0ded-381e-4918-a7fa-49857448427d.webp?v=1714977523","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b352a98a84062013e81f62f74f60ea517a13084c_19eae257-2071-4ca4-a7f5-5909fcd5bd04.webp?v=1714977525","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89623a018dd1d863d98df20d6dd146f8e1df8f81_3ae91dce-fed8-4ce4-aa10-2707b1bb87a8.webp?v=1714977527","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/34402f5f79b62127d5eb1bace2ebc2f774ffdc44_522cf1e2-6a9f-4dd0-b657-cc350f50c2dc.webp?v=1714977530"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","options":["color"],"media":[{"alt":null,"id":23897306300515,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","width":2000},{"alt":null,"id":23897306660963,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a177bd48d0e400ff506fc3df610d4acd5d66329c_82cce831-3ced-4545-8b94-64b8d35bd217.webp?v=1714977512"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a177bd48d0e400ff506fc3df610d4acd5d66329c_82cce831-3ced-4545-8b94-64b8d35bd217.webp?v=1714977512","width":2000},{"alt":null,"id":23897307152483,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b9803b9af7f61667d5e1ae6ee37e9b07e62ae43_daf1fd11-9238-4f22-8569-4ae905f02fce.webp?v=1714977514"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b9803b9af7f61667d5e1ae6ee37e9b07e62ae43_daf1fd11-9238-4f22-8569-4ae905f02fce.webp?v=1714977514","width":2000},{"alt":null,"id":23897307611235,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d315770fb51cb7e201cceb82c6ccc4ca686ee916_63c9e417-9e32-49b9-b692-feaec8fff36e.webp?v=1714977517"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d315770fb51cb7e201cceb82c6ccc4ca686ee916_63c9e417-9e32-49b9-b692-feaec8fff36e.webp?v=1714977517","width":2000},{"alt":null,"id":23897308037219,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c2e9fdd42378d56e16383a6481dbaef1f1057c2_e238aed0-67ff-44ff-bd87-20fd40453b0a.webp?v=1714977519"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c2e9fdd42378d56e16383a6481dbaef1f1057c2_e238aed0-67ff-44ff-bd87-20fd40453b0a.webp?v=1714977519","width":2000},{"alt":null,"id":23897308430435,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0316c91d6dff1d540a6de77dd8510f0ee7c0a3_7b28aabe-6681-4fb5-a495-98115d260459.webp?v=1714977521"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0316c91d6dff1d540a6de77dd8510f0ee7c0a3_7b28aabe-6681-4fb5-a495-98115d260459.webp?v=1714977521","width":2000},{"alt":null,"id":23897308856419,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7a197cc179fbf4a8608898708ab6644dfb00999a_408e0ded-381e-4918-a7fa-49857448427d.webp?v=1714977523"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7a197cc179fbf4a8608898708ab6644dfb00999a_408e0ded-381e-4918-a7fa-49857448427d.webp?v=1714977523","width":2000},{"alt":null,"id":23897309347939,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b352a98a84062013e81f62f74f60ea517a13084c_19eae257-2071-4ca4-a7f5-5909fcd5bd04.webp?v=1714977525"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b352a98a84062013e81f62f74f60ea517a13084c_19eae257-2071-4ca4-a7f5-5909fcd5bd04.webp?v=1714977525","width":2000},{"alt":null,"id":23897309642851,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89623a018dd1d863d98df20d6dd146f8e1df8f81_3ae91dce-fed8-4ce4-aa10-2707b1bb87a8.webp?v=1714977527"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89623a018dd1d863d98df20d6dd146f8e1df8f81_3ae91dce-fed8-4ce4-aa10-2707b1bb87a8.webp?v=1714977527","width":2000},{"alt":null,"id":23897310167139,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/34402f5f79b62127d5eb1bace2ebc2f774ffdc44_522cf1e2-6a9f-4dd0-b657-cc350f50c2dc.webp?v=1714977530"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/34402f5f79b62127d5eb1bace2ebc2f774ffdc44_522cf1e2-6a9f-4dd0-b657-cc350f50c2dc.webp?v=1714977530","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41918707990627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB38","requires_shipping":true,"taxable":true,"featured_image":{"id":31491893428323,"product_id":7416343658595,"position":1,"created_at":"2024-05-06T14:38:30+08:00","updated_at":"2024-05-06T14:38:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","variant_ids":[41918707990627]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-塗鴉藝術 - 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":"NPB0105424-PB38","featured_media":{"alt":null,"id":23897306300515,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41918707990627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB38","requires_shipping":true,"taxable":true,"featured_image":{"id":31491893428323,"product_id":7416343658595,"position":1,"created_at":"2024-05-06T14:38:30+08:00","updated_at":"2024-05-06T14:38:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510","variant_ids":[41918707990627]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-塗鴉藝術 - 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":"NPB0105424-PB38","featured_media":{"alt":null,"id":23897306300515,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03d7d34f3b52569a492b51ae8af77c22e4e99059_cc6180ff-8582-4f85-99e5-ee8c2c1cca81.webp?v=1714977510"}},"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: "停產" }