$product = {"id":7411262849123,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 人在做 北極冰川在看","handle":"iphone-14-plus-mod-nx-magsafe-printable-af05","description":null,"published_at":"2024-06-11T17:40:14+08:00","created_at":"2024-05-04T23:56:02+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Look","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-look","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-look","Top50","type-Mod NX Printable MagSafe Printable"],"price":110000,"price_min":110000,"price_max":110000,"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":41896684290147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF05","requires_shipping":true,"taxable":true,"featured_image":{"id":31479991566435,"product_id":7411262849123,"position":9,"created_at":"2024-05-04T23:56:22+08:00","updated_at":"2024-05-04T23:56:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182","variant_ids":[41896684290147]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 人在做 北極冰川在看 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF05","featured_media":{"alt":null,"id":23885242105955,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d61cb19a8fb6d628e771daed8dd85dec41173f64_1fabc764-e7ba-4e22-9415-80f11b6615cd.webp?v=1714838164","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dbba0b133af0539eb1b89d9c92d7c125063497c7_194a5300-df5a-4f74-b155-7b804c864b2a.webp?v=1714838166","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5d85ce64454bf6323d15dc44d80cd28630311b1b_5d1cbc7b-a460-4dc8-b528-ffbbc16011cb.webp?v=1714838169","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f426e5381280cc9423f7a0d20b8397b31ad24c1_c2af852c-5363-4949-ba62-222726a02993.webp?v=1714838171","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9cc2c1d060636a472930ad7d2dd992b1331656ee_fd2ac887-7b30-42db-b917-1bc19e64bb44.webp?v=1714838173","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b275cced3d8164b5e4ae90b7b3867aea95c8b88e_ec9a6ae1-4840-4612-a631-84ae13304ba8.webp?v=1714838175","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1cd533d140a0575f0ac5adb2ffe3c2d4787caf63_06dcb95c-2d51-4770-b78f-76d51ae94bfc.webp?v=1714838178","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31e404d1d0f28331df94263e21c734dd73b0d88a_daba689b-7968-4f07-9f54-2db056ae2a65.webp?v=1714838180","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/563b103ef8f3265fd36e8094370307695d2bc887_cb040a03-1089-437a-8c78-cd6ee67ba69d.webp?v=1714838185"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d61cb19a8fb6d628e771daed8dd85dec41173f64_1fabc764-e7ba-4e22-9415-80f11b6615cd.webp?v=1714838164","options":["color"],"media":[{"alt":null,"id":23885237846115,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d61cb19a8fb6d628e771daed8dd85dec41173f64_1fabc764-e7ba-4e22-9415-80f11b6615cd.webp?v=1714838164"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d61cb19a8fb6d628e771daed8dd85dec41173f64_1fabc764-e7ba-4e22-9415-80f11b6615cd.webp?v=1714838164","width":2000},{"alt":null,"id":23885238075491,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dbba0b133af0539eb1b89d9c92d7c125063497c7_194a5300-df5a-4f74-b155-7b804c864b2a.webp?v=1714838166"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dbba0b133af0539eb1b89d9c92d7c125063497c7_194a5300-df5a-4f74-b155-7b804c864b2a.webp?v=1714838166","width":2000},{"alt":null,"id":23885238796387,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5d85ce64454bf6323d15dc44d80cd28630311b1b_5d1cbc7b-a460-4dc8-b528-ffbbc16011cb.webp?v=1714838169"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5d85ce64454bf6323d15dc44d80cd28630311b1b_5d1cbc7b-a460-4dc8-b528-ffbbc16011cb.webp?v=1714838169","width":2000},{"alt":null,"id":23885239091299,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f426e5381280cc9423f7a0d20b8397b31ad24c1_c2af852c-5363-4949-ba62-222726a02993.webp?v=1714838171"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3f426e5381280cc9423f7a0d20b8397b31ad24c1_c2af852c-5363-4949-ba62-222726a02993.webp?v=1714838171","width":2000},{"alt":null,"id":23885239681123,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9cc2c1d060636a472930ad7d2dd992b1331656ee_fd2ac887-7b30-42db-b917-1bc19e64bb44.webp?v=1714838173"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9cc2c1d060636a472930ad7d2dd992b1331656ee_fd2ac887-7b30-42db-b917-1bc19e64bb44.webp?v=1714838173","width":2000},{"alt":null,"id":23885240500323,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b275cced3d8164b5e4ae90b7b3867aea95c8b88e_ec9a6ae1-4840-4612-a631-84ae13304ba8.webp?v=1714838175"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b275cced3d8164b5e4ae90b7b3867aea95c8b88e_ec9a6ae1-4840-4612-a631-84ae13304ba8.webp?v=1714838175","width":2000},{"alt":null,"id":23885241253987,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1cd533d140a0575f0ac5adb2ffe3c2d4787caf63_06dcb95c-2d51-4770-b78f-76d51ae94bfc.webp?v=1714838178"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1cd533d140a0575f0ac5adb2ffe3c2d4787caf63_06dcb95c-2d51-4770-b78f-76d51ae94bfc.webp?v=1714838178","width":2000},{"alt":null,"id":23885241778275,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31e404d1d0f28331df94263e21c734dd73b0d88a_daba689b-7968-4f07-9f54-2db056ae2a65.webp?v=1714838180"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31e404d1d0f28331df94263e21c734dd73b0d88a_daba689b-7968-4f07-9f54-2db056ae2a65.webp?v=1714838180","width":2000},{"alt":null,"id":23885242105955,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182","width":2000},{"alt":null,"id":23885242663011,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/563b103ef8f3265fd36e8094370307695d2bc887_cb040a03-1089-437a-8c78-cd6ee67ba69d.webp?v=1714838185"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/563b103ef8f3265fd36e8094370307695d2bc887_cb040a03-1089-437a-8c78-cd6ee67ba69d.webp?v=1714838185","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41896684290147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF05","requires_shipping":true,"taxable":true,"featured_image":{"id":31479991566435,"product_id":7411262849123,"position":9,"created_at":"2024-05-04T23:56:22+08:00","updated_at":"2024-05-04T23:56:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182","variant_ids":[41896684290147]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 人在做 北極冰川在看 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF05","featured_media":{"alt":null,"id":23885242105955,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41896684290147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF05","requires_shipping":true,"taxable":true,"featured_image":{"id":31479991566435,"product_id":7411262849123,"position":9,"created_at":"2024-05-04T23:56:22+08:00","updated_at":"2024-05-04T23:56:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182","variant_ids":[41896684290147]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 人在做 北極冰川在看 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF05","featured_media":{"alt":null,"id":23885242105955,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ca99b4c2c482bdf76d10a8ab551d0f810a6d2d50_478f47e5-870f-4e3b-a5ac-ea6b98370e55.webp?v=1714838182"}},"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: "停產" }