$product = {"id":7407768010851,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP X戰機 X-WI","handle":"iphone-14-plus-mod-nx-printable-pb25","description":null,"published_at":"2024-06-11T16:22:57+08:00","created_at":"2024-05-03T10:49:38+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":41878608445539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB25","requires_shipping":true,"taxable":true,"featured_image":{"id":31470347714659,"product_id":7407768010851,"position":1,"created_at":"2024-05-03T10:49:41+08:00","updated_at":"2024-05-03T10:49:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","variant_ids":[41878608445539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP X戰機 X-WI - 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-PB25","featured_media":{"alt":null,"id":23875250880611,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8eb16587491bc97770eb23b12e5f53bc56bebd5_10fcb7d8-cc44-4308-ba45-fa78356cac91.webp?v=1714704583","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c599d7a3d962d294dbe5410d1ec29df0dbb78578_a354946c-2a59-4921-bb3f-c28ebea96e5e.webp?v=1714704586","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c7d8a7b892776d6a80b725c0e544e11dadef3f4_5ec909d7-d4ab-424b-ac84-0291b3b5833c.webp?v=1714704589","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8403061eab393ce2c2ed38c79a534b7c49a6be8_9a1d29d1-b4bf-41ab-b366-367f13e63258.webp?v=1714704591","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db6c125c02e4ac035eb112d645f2e24403a4a813_768d7b83-ec00-4cba-9d52-e01e4d9f674f.webp?v=1714704594","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90b43f0f64d70c4bcbd8da1fd476135314d19dc0_f52411f3-f9ce-464c-bc5f-1c95ced30831.webp?v=1714704597","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/226bfa8ea32327a53f8e50463edf248434484a8b_5d4377db-a83e-4b08-819b-06105ca388dc.webp?v=1714704599","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e0a259ef1dd45b1c0a2a42f92f705be000ede1b_da4c4927-c044-4f63-bc5f-64b2b8d21159.webp?v=1714704602","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a7c0dcce1a4e8358b59a1f842e1994e1a9fbee82_ccd762b1-90f7-44c0-9fb4-0203ce96f4f4.webp?v=1714704605"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","options":["color"],"media":[{"alt":null,"id":23875250880611,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","width":2000},{"alt":null,"id":23875251437667,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8eb16587491bc97770eb23b12e5f53bc56bebd5_10fcb7d8-cc44-4308-ba45-fa78356cac91.webp?v=1714704583"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8eb16587491bc97770eb23b12e5f53bc56bebd5_10fcb7d8-cc44-4308-ba45-fa78356cac91.webp?v=1714704583","width":2000},{"alt":null,"id":23875252519011,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c599d7a3d962d294dbe5410d1ec29df0dbb78578_a354946c-2a59-4921-bb3f-c28ebea96e5e.webp?v=1714704586"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c599d7a3d962d294dbe5410d1ec29df0dbb78578_a354946c-2a59-4921-bb3f-c28ebea96e5e.webp?v=1714704586","width":2000},{"alt":null,"id":23875253043299,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c7d8a7b892776d6a80b725c0e544e11dadef3f4_5ec909d7-d4ab-424b-ac84-0291b3b5833c.webp?v=1714704589"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1c7d8a7b892776d6a80b725c0e544e11dadef3f4_5ec909d7-d4ab-424b-ac84-0291b3b5833c.webp?v=1714704589","width":2000},{"alt":null,"id":23875253764195,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8403061eab393ce2c2ed38c79a534b7c49a6be8_9a1d29d1-b4bf-41ab-b366-367f13e63258.webp?v=1714704591"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8403061eab393ce2c2ed38c79a534b7c49a6be8_9a1d29d1-b4bf-41ab-b366-367f13e63258.webp?v=1714704591","width":2000},{"alt":null,"id":23875254517859,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db6c125c02e4ac035eb112d645f2e24403a4a813_768d7b83-ec00-4cba-9d52-e01e4d9f674f.webp?v=1714704594"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db6c125c02e4ac035eb112d645f2e24403a4a813_768d7b83-ec00-4cba-9d52-e01e4d9f674f.webp?v=1714704594","width":2000},{"alt":null,"id":23875255271523,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90b43f0f64d70c4bcbd8da1fd476135314d19dc0_f52411f3-f9ce-464c-bc5f-1c95ced30831.webp?v=1714704597"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90b43f0f64d70c4bcbd8da1fd476135314d19dc0_f52411f3-f9ce-464c-bc5f-1c95ced30831.webp?v=1714704597","width":2000},{"alt":null,"id":23875255894115,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/226bfa8ea32327a53f8e50463edf248434484a8b_5d4377db-a83e-4b08-819b-06105ca388dc.webp?v=1714704599"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/226bfa8ea32327a53f8e50463edf248434484a8b_5d4377db-a83e-4b08-819b-06105ca388dc.webp?v=1714704599","width":2000},{"alt":null,"id":23875256713315,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e0a259ef1dd45b1c0a2a42f92f705be000ede1b_da4c4927-c044-4f63-bc5f-64b2b8d21159.webp?v=1714704602"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e0a259ef1dd45b1c0a2a42f92f705be000ede1b_da4c4927-c044-4f63-bc5f-64b2b8d21159.webp?v=1714704602","width":2000},{"alt":null,"id":23875257466979,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a7c0dcce1a4e8358b59a1f842e1994e1a9fbee82_ccd762b1-90f7-44c0-9fb4-0203ce96f4f4.webp?v=1714704605"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a7c0dcce1a4e8358b59a1f842e1994e1a9fbee82_ccd762b1-90f7-44c0-9fb4-0203ce96f4f4.webp?v=1714704605","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41878608445539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB25","requires_shipping":true,"taxable":true,"featured_image":{"id":31470347714659,"product_id":7407768010851,"position":1,"created_at":"2024-05-03T10:49:41+08:00","updated_at":"2024-05-03T10:49:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","variant_ids":[41878608445539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP X戰機 X-WI - 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-PB25","featured_media":{"alt":null,"id":23875250880611,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41878608445539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB25","requires_shipping":true,"taxable":true,"featured_image":{"id":31470347714659,"product_id":7407768010851,"position":1,"created_at":"2024-05-03T10:49:41+08:00","updated_at":"2024-05-03T10:49:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581","variant_ids":[41878608445539]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP X戰機 X-WI - 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-PB25","featured_media":{"alt":null,"id":23875250880611,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/57499da20c31c957cf7b26402c6c1149bc40332c_0087cc2d-ab1f-4971-bdc1-1e2ca3ecdc51.webp?v=1714704581"}},"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: "停產" }