$product = {"id":7408519610467,"title":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 波巴菲特-剪紙系列","handle":"iphone-12-mini-mod-nx-printable-pb58","description":null,"published_at":"2024-06-11T16:39:32+08:00","created_at":"2024-05-03T15:42:39+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 12 mini","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":41886416601187,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB58","requires_shipping":true,"taxable":true,"featured_image":{"id":31472489791587,"product_id":7408519610467,"position":10,"created_at":"2024-05-03T15:43:03+08:00","updated_at":"2024-05-03T15:43:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183","variant_ids":[41886416601187]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118424-PB58","featured_media":{"alt":null,"id":23877407146083,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9550937b9d094abc2d600cf42f7d102f141f6b9_4009191e-9370-4e3a-b0ee-29abf2487aa7.webp?v=1714722161","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7adcace367af712883e06b28e66c3556a9e4f709_2de52f48-67db-49bc-94d2-82dd46a2a99e.webp?v=1714722164","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/06b2a640eaf9ec8412db3d51436642e58ff9c05a_52fd393a-c281-4369-9192-d879ea5a735f.webp?v=1714722166","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/389fb454fb5eab4a438a06193a580468f7640985_c533fc50-ebe8-4952-9cc1-ee65375a35bb.webp?v=1714722169","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3cd0be4b3564a46b45017eb087353fd277d907c_53dc9e84-88e4-451e-8a2e-d3898988f7c1.webp?v=1714722171","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0d2f5c9e34e75c11b9ab21522243173243ef8dfe_a950f607-04ad-4855-baca-de3ea1cd5134.webp?v=1714722173","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/28255d2f260ce9e31a6146da203e168780395f5a_1e114fcb-4524-41cc-a4b4-28fa426e7fd6.webp?v=1714722176","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f350b69282b0a5dcb232ef5fc267be42b87ff91_d049a8e4-fcbc-4ba8-af6a-f1e907897260.webp?v=1714722178","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be368ee4601a4934709d5bbba99558e4df885f2c_c96dbe5f-e78c-497e-b6a3-2ccd672921cc.webp?v=1714722180","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0e1fa0568c2e84cc05bb2e45f367d4641f593c3_0b4b88e2-c734-477d-ba4b-14881326dbfa.webp?v=1714722185"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9550937b9d094abc2d600cf42f7d102f141f6b9_4009191e-9370-4e3a-b0ee-29abf2487aa7.webp?v=1714722161","options":["color"],"media":[{"alt":null,"id":23877402493027,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9550937b9d094abc2d600cf42f7d102f141f6b9_4009191e-9370-4e3a-b0ee-29abf2487aa7.webp?v=1714722161"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9550937b9d094abc2d600cf42f7d102f141f6b9_4009191e-9370-4e3a-b0ee-29abf2487aa7.webp?v=1714722161","width":2000},{"alt":null,"id":23877402820707,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7adcace367af712883e06b28e66c3556a9e4f709_2de52f48-67db-49bc-94d2-82dd46a2a99e.webp?v=1714722164"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7adcace367af712883e06b28e66c3556a9e4f709_2de52f48-67db-49bc-94d2-82dd46a2a99e.webp?v=1714722164","width":2000},{"alt":null,"id":23877403344995,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/06b2a640eaf9ec8412db3d51436642e58ff9c05a_52fd393a-c281-4369-9192-d879ea5a735f.webp?v=1714722166"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/06b2a640eaf9ec8412db3d51436642e58ff9c05a_52fd393a-c281-4369-9192-d879ea5a735f.webp?v=1714722166","width":2000},{"alt":null,"id":23877403672675,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/389fb454fb5eab4a438a06193a580468f7640985_c533fc50-ebe8-4952-9cc1-ee65375a35bb.webp?v=1714722169"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/389fb454fb5eab4a438a06193a580468f7640985_c533fc50-ebe8-4952-9cc1-ee65375a35bb.webp?v=1714722169","width":2000},{"alt":null,"id":23877404229731,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3cd0be4b3564a46b45017eb087353fd277d907c_53dc9e84-88e4-451e-8a2e-d3898988f7c1.webp?v=1714722171"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3cd0be4b3564a46b45017eb087353fd277d907c_53dc9e84-88e4-451e-8a2e-d3898988f7c1.webp?v=1714722171","width":2000},{"alt":null,"id":23877404983395,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0d2f5c9e34e75c11b9ab21522243173243ef8dfe_a950f607-04ad-4855-baca-de3ea1cd5134.webp?v=1714722173"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0d2f5c9e34e75c11b9ab21522243173243ef8dfe_a950f607-04ad-4855-baca-de3ea1cd5134.webp?v=1714722173","width":2000},{"alt":null,"id":23877405540451,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/28255d2f260ce9e31a6146da203e168780395f5a_1e114fcb-4524-41cc-a4b4-28fa426e7fd6.webp?v=1714722176"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/28255d2f260ce9e31a6146da203e168780395f5a_1e114fcb-4524-41cc-a4b4-28fa426e7fd6.webp?v=1714722176","width":2000},{"alt":null,"id":23877405999203,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f350b69282b0a5dcb232ef5fc267be42b87ff91_d049a8e4-fcbc-4ba8-af6a-f1e907897260.webp?v=1714722178"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f350b69282b0a5dcb232ef5fc267be42b87ff91_d049a8e4-fcbc-4ba8-af6a-f1e907897260.webp?v=1714722178","width":2000},{"alt":null,"id":23877406589027,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be368ee4601a4934709d5bbba99558e4df885f2c_c96dbe5f-e78c-497e-b6a3-2ccd672921cc.webp?v=1714722180"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be368ee4601a4934709d5bbba99558e4df885f2c_c96dbe5f-e78c-497e-b6a3-2ccd672921cc.webp?v=1714722180","width":2000},{"alt":null,"id":23877407146083,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183","width":2000},{"alt":null,"id":23877407866979,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0e1fa0568c2e84cc05bb2e45f367d4641f593c3_0b4b88e2-c734-477d-ba4b-14881326dbfa.webp?v=1714722185"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0e1fa0568c2e84cc05bb2e45f367d4641f593c3_0b4b88e2-c734-477d-ba4b-14881326dbfa.webp?v=1714722185","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886416601187,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB58","requires_shipping":true,"taxable":true,"featured_image":{"id":31472489791587,"product_id":7408519610467,"position":10,"created_at":"2024-05-03T15:43:03+08:00","updated_at":"2024-05-03T15:43:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183","variant_ids":[41886416601187]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118424-PB58","featured_media":{"alt":null,"id":23877407146083,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886416601187,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB58","requires_shipping":true,"taxable":true,"featured_image":{"id":31472489791587,"product_id":7408519610467,"position":10,"created_at":"2024-05-03T15:43:03+08:00","updated_at":"2024-05-03T15:43:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183","variant_ids":[41886416601187]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 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":"NPB0118424-PB58","featured_media":{"alt":null,"id":23877407146083,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/77bbfd7c9ea2202b8941be558c49076d8506618c_b9a5a4fb-e994-48d5-b178-dbbedcd11aa0.webp?v=1714722183"}},"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: "停產" }