$product = {"id":7886142537827,"title":"iPhone 12 mini Mod NX (MagSafe 兼容) 馬來貘LAIMO 奇峰崢嶸","handle":"iphone-12-mini-mod-nx-magsafe-printable-lmo02","description":null,"published_at":"2025-09-17T10:54:54+08:00","created_at":"2025-09-17T10:02:30+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-cherng","device-iPhone 12 Mini","merge","reseller-cherng"],"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":43734813933667,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"MPB0118424-LMO02","requires_shipping":true,"taxable":true,"featured_image":{"id":34500227235939,"product_id":7886142537827,"position":2,"created_at":"2025-09-17T10:02:34+08:00","updated_at":"2025-09-17T10:02:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555","variant_ids":[43734813933667]},"available":true,"name":"iPhone 12 mini Mod NX (MagSafe 兼容) 馬來貘LAIMO 奇峰崢嶸 - Black","public_title":"Black","options":["Black"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-LMO02","featured_media":{"alt":null,"id":26071818993763,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/516632dcb4902d4b4287750ba0680079b13a1366.webp?v=1758074555","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/69d000c5e510ff829c9bdead5139f5cf1f45aae7.webp?v=1758074556","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4298d689a5977c19443182523918d25f54b3afc.webp?v=1758074556","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47d2617091b9906a3714a4b817d59dbe62c36213.webp?v=1758074557","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e6312aab7f3d5198c4004c29c6bc233da94e258.webp?v=1758074558","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef823c1e563311bb613bcfec4e5f51c2a623abad.webp?v=1758074558","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e6b36968d2568232e18fa8713a67fa5c9107bf5.webp?v=1758074559","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b6a250d329332c8a67be990fe66b92b9f714ca91.webp?v=1758074559","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71016bb144b838c3797e4433c74336081df9ab92.webp?v=1758074559","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ea5d8f3f1fd577f486118ca7c79326390280b3f.webp?v=1758074560"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/516632dcb4902d4b4287750ba0680079b13a1366.webp?v=1758074555","options":["color"],"media":[{"alt":null,"id":26071818797155,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/516632dcb4902d4b4287750ba0680079b13a1366.webp?v=1758074555"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/516632dcb4902d4b4287750ba0680079b13a1366.webp?v=1758074555","width":2000},{"alt":null,"id":26071818993763,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555","width":2000},{"alt":null,"id":26071819190371,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/69d000c5e510ff829c9bdead5139f5cf1f45aae7.webp?v=1758074556"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/69d000c5e510ff829c9bdead5139f5cf1f45aae7.webp?v=1758074556","width":2000},{"alt":null,"id":26071819485283,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4298d689a5977c19443182523918d25f54b3afc.webp?v=1758074556"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4298d689a5977c19443182523918d25f54b3afc.webp?v=1758074556","width":2000},{"alt":null,"id":26071819681891,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47d2617091b9906a3714a4b817d59dbe62c36213.webp?v=1758074557"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/47d2617091b9906a3714a4b817d59dbe62c36213.webp?v=1758074557","width":2000},{"alt":null,"id":26071819944035,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e6312aab7f3d5198c4004c29c6bc233da94e258.webp?v=1758074558"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1e6312aab7f3d5198c4004c29c6bc233da94e258.webp?v=1758074558","width":2000},{"alt":null,"id":26071820206179,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef823c1e563311bb613bcfec4e5f51c2a623abad.webp?v=1758074558"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef823c1e563311bb613bcfec4e5f51c2a623abad.webp?v=1758074558","width":2000},{"alt":null,"id":26071820435555,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e6b36968d2568232e18fa8713a67fa5c9107bf5.webp?v=1758074559"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e6b36968d2568232e18fa8713a67fa5c9107bf5.webp?v=1758074559","width":2000},{"alt":null,"id":26071820763235,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b6a250d329332c8a67be990fe66b92b9f714ca91.webp?v=1758074559"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b6a250d329332c8a67be990fe66b92b9f714ca91.webp?v=1758074559","width":2000},{"alt":null,"id":26071820992611,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71016bb144b838c3797e4433c74336081df9ab92.webp?v=1758074559"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71016bb144b838c3797e4433c74336081df9ab92.webp?v=1758074559","width":2000},{"alt":null,"id":26071821353059,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ea5d8f3f1fd577f486118ca7c79326390280b3f.webp?v=1758074560"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ea5d8f3f1fd577f486118ca7c79326390280b3f.webp?v=1758074560","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $bumper = null; $variants = [{"id":43734813933667,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"MPB0118424-LMO02","requires_shipping":true,"taxable":true,"featured_image":{"id":34500227235939,"product_id":7886142537827,"position":2,"created_at":"2025-09-17T10:02:34+08:00","updated_at":"2025-09-17T10:02:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555","variant_ids":[43734813933667]},"available":true,"name":"iPhone 12 mini Mod NX (MagSafe 兼容) 馬來貘LAIMO 奇峰崢嶸 - Black","public_title":"Black","options":["Black"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-LMO02","featured_media":{"alt":null,"id":26071818993763,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43734813933667,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"MPB0118424-LMO02","requires_shipping":true,"taxable":true,"featured_image":{"id":34500227235939,"product_id":7886142537827,"position":2,"created_at":"2025-09-17T10:02:34+08:00","updated_at":"2025-09-17T10:02:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555","variant_ids":[43734813933667]},"available":true,"name":"iPhone 12 mini Mod NX (MagSafe 兼容) 馬來貘LAIMO 奇峰崢嶸 - Black","public_title":"Black","options":["Black"],"price":110000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-LMO02","featured_media":{"alt":null,"id":26071818993763,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9d90ce619bc0be38023140f2f4b81c852730647.webp?v=1758074555"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}; $device_handle = null var sellingStatus if ($bumper) { $(document).ready(function() { var productImg = $product.images[0] var bumperVariants = $bumper.variants; var bumperColors = new Object(); var currentVariant = ''; var productType = ''; bumperVariants.forEach(variant => { bumperColors[`${variant.title.split(' (')[0].toLowerCase()}`] = variant.featured_image.src; }); if (productType === 'mod-nx-backplate' || productType === 'mod-backplate') { mergeImages( [productImg, bumperColors[currentVariant]], { crossOrigin: 'anonymous' } ).then(mergedImg => { $('.merged-img').attr('src', mergedImg); }); } else { mergeImages( [bumperColors[currentVariant], productImg], { crossOrigin: 'anonymous' } ).then(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: "停產" }