$product = {"id":7416372756579,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - K2SO 2-俠盜一號","handle":"iphone-8-mod-nx-printable-pb69","description":null,"published_at":"2024-06-11T16:57:16+08:00","created_at":"2024-05-06T14:44:17+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":41919023939683,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB69","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966042211,"product_id":7416372756579,"position":1,"created_at":"2024-05-06T14:44:20+08:00","updated_at":"2024-05-06T14:44:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","variant_ids":[41919023939683]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - K2SO 2-俠盜一號 - 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-PB69","featured_media":{"alt":null,"id":23897379274851,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017dc8c6a96b00617a81eea97b7ff23d2dbe540d_c8a4c202-c5f1-4977-918c-760a7c53c12d.webp?v=1714977862","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d74d641eca7f9a79f9f2653a18e24e0a97f269fd_02778659-7eba-48cb-932c-705ab987aa0b.webp?v=1714977864","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/142230ca953f2c036807183e6d48270929388261_d64c5344-c97b-41ed-9637-47d7a58315b6.webp?v=1714977867","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c6ce964ca89ccd5d6f3a727707266ab1263ad581_bbf69f90-3823-4210-a3c7-ef4989b6baba.webp?v=1714977869","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d15b0329d8f2690a1c440fae6a467a9823a1e09a_b31253df-84f5-481e-bfca-c78b34ac93a6.webp?v=1714977872","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a3d623f557674dd1ed54908749c9e976a41ec01_d5765d2c-5c51-4e57-a9fd-fcc5d42ea2ea.webp?v=1714977874","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/924198b5d634211483c4fe3a56960ff0de30b69a_99b517f4-538b-404d-b2fa-fc8e8063fccd.webp?v=1714977877","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1911adad1fad083340e36f7520cd3edbd10773bd_db83fcdd-e989-45ca-a46a-9f8a6c17aa21.webp?v=1714977879","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db8479d8d3066447230013094bc437e20794f3dc_2d6407f9-786e-4a34-9b5a-bfd079cfa3a4.webp?v=1714977882"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","options":["color"],"media":[{"alt":null,"id":23897379274851,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","width":2000},{"alt":null,"id":23897379569763,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017dc8c6a96b00617a81eea97b7ff23d2dbe540d_c8a4c202-c5f1-4977-918c-760a7c53c12d.webp?v=1714977862"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/017dc8c6a96b00617a81eea97b7ff23d2dbe540d_c8a4c202-c5f1-4977-918c-760a7c53c12d.webp?v=1714977862","width":2000},{"alt":null,"id":23897379962979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d74d641eca7f9a79f9f2653a18e24e0a97f269fd_02778659-7eba-48cb-932c-705ab987aa0b.webp?v=1714977864"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d74d641eca7f9a79f9f2653a18e24e0a97f269fd_02778659-7eba-48cb-932c-705ab987aa0b.webp?v=1714977864","width":2000},{"alt":null,"id":23897380421731,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/142230ca953f2c036807183e6d48270929388261_d64c5344-c97b-41ed-9637-47d7a58315b6.webp?v=1714977867"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/142230ca953f2c036807183e6d48270929388261_d64c5344-c97b-41ed-9637-47d7a58315b6.webp?v=1714977867","width":2000},{"alt":null,"id":23897380749411,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c6ce964ca89ccd5d6f3a727707266ab1263ad581_bbf69f90-3823-4210-a3c7-ef4989b6baba.webp?v=1714977869"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c6ce964ca89ccd5d6f3a727707266ab1263ad581_bbf69f90-3823-4210-a3c7-ef4989b6baba.webp?v=1714977869","width":2000},{"alt":null,"id":23897381437539,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d15b0329d8f2690a1c440fae6a467a9823a1e09a_b31253df-84f5-481e-bfca-c78b34ac93a6.webp?v=1714977872"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d15b0329d8f2690a1c440fae6a467a9823a1e09a_b31253df-84f5-481e-bfca-c78b34ac93a6.webp?v=1714977872","width":2000},{"alt":null,"id":23897381863523,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a3d623f557674dd1ed54908749c9e976a41ec01_d5765d2c-5c51-4e57-a9fd-fcc5d42ea2ea.webp?v=1714977874"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a3d623f557674dd1ed54908749c9e976a41ec01_d5765d2c-5c51-4e57-a9fd-fcc5d42ea2ea.webp?v=1714977874","width":2000},{"alt":null,"id":23897382256739,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/924198b5d634211483c4fe3a56960ff0de30b69a_99b517f4-538b-404d-b2fa-fc8e8063fccd.webp?v=1714977877"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/924198b5d634211483c4fe3a56960ff0de30b69a_99b517f4-538b-404d-b2fa-fc8e8063fccd.webp?v=1714977877","width":2000},{"alt":null,"id":23897382486115,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1911adad1fad083340e36f7520cd3edbd10773bd_db83fcdd-e989-45ca-a46a-9f8a6c17aa21.webp?v=1714977879"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1911adad1fad083340e36f7520cd3edbd10773bd_db83fcdd-e989-45ca-a46a-9f8a6c17aa21.webp?v=1714977879","width":2000},{"alt":null,"id":23897383075939,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db8479d8d3066447230013094bc437e20794f3dc_2d6407f9-786e-4a34-9b5a-bfd079cfa3a4.webp?v=1714977882"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db8479d8d3066447230013094bc437e20794f3dc_2d6407f9-786e-4a34-9b5a-bfd079cfa3a4.webp?v=1714977882","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41919023939683,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB69","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966042211,"product_id":7416372756579,"position":1,"created_at":"2024-05-06T14:44:20+08:00","updated_at":"2024-05-06T14:44:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","variant_ids":[41919023939683]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - K2SO 2-俠盜一號 - 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-PB69","featured_media":{"alt":null,"id":23897379274851,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41919023939683,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PB69","requires_shipping":true,"taxable":true,"featured_image":{"id":31491966042211,"product_id":7416372756579,"position":1,"created_at":"2024-05-06T14:44:20+08:00","updated_at":"2024-05-06T14:44:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860","variant_ids":[41919023939683]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - K2SO 2-俠盜一號 - 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-PB69","featured_media":{"alt":null,"id":23897379274851,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25918835c8c1ef97fdba483d890ac52832438ada_f5fd91d2-7b2e-42a8-83a4-e1d2cc11dcf6.webp?v=1714977860"}},"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: "停產" }