$product = {"id":7903443615843,"title":"iPhone X Mod NX 變種吉娃娃 Godgwawa 五星吉海底餐廳","handle":"iphone-x-mod-nx-printable-it37","description":null,"published_at":"2025-10-20T09:40:37+08:00","created_at":"2025-10-20T09:30:15+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-godgwawa","device-iPhone X","merge","reseller-godgwawa"],"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":43786669391971,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0106424-IT37","requires_shipping":true,"taxable":true,"featured_image":{"id":34672973250659,"product_id":7903443615843,"position":3,"created_at":"2025-10-20T09:30:18+08:00","updated_at":"2025-10-20T09:30:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820","variant_ids":[43786669391971]},"available":true,"name":"iPhone X Mod NX 變種吉娃娃 Godgwawa 五星吉海底餐廳 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0106424-IT37","featured_media":{"alt":null,"id":26242232189027,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/87a0a36d2b00e86f70eafe6f11a1be44356e79e8.webp?v=1760923819","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2aeb45d64a232ee243cc00e9e92451ace30696a.webp?v=1760923828","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0bbe563b0fc813f429d5867bd250fd59628985a.webp?v=1760923821","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2996a532c772d0f243cb4fa785ae1a0d792855d1.webp?v=1760923822","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f816db7a508adea0cdfeafeec72ebe45d36168d4.webp?v=1760923823","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12349abbd0596e42520a8e7bf895922f110156c0.webp?v=1760923823","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4381f52590841b276b45e5314418d7126663a094.webp?v=1760923824","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ed104b4e26704c8e954703741e78e132372d93cf.webp?v=1760923825","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/20be709a82fc9a1731b5c336f6237e6e3fc2a381.webp?v=1760923826"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/87a0a36d2b00e86f70eafe6f11a1be44356e79e8.webp?v=1760923819","options":["color"],"media":[{"alt":null,"id":26242231763043,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/87a0a36d2b00e86f70eafe6f11a1be44356e79e8.webp?v=1760923819"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/87a0a36d2b00e86f70eafe6f11a1be44356e79e8.webp?v=1760923819","width":2000},{"alt":null,"id":26242231959651,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2aeb45d64a232ee243cc00e9e92451ace30696a.webp?v=1760923828"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2aeb45d64a232ee243cc00e9e92451ace30696a.webp?v=1760923828","width":2000},{"alt":null,"id":26242232189027,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820","width":2000},{"alt":null,"id":26242232385635,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0bbe563b0fc813f429d5867bd250fd59628985a.webp?v=1760923821"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0bbe563b0fc813f429d5867bd250fd59628985a.webp?v=1760923821","width":2000},{"alt":null,"id":26242232877155,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2996a532c772d0f243cb4fa785ae1a0d792855d1.webp?v=1760923822"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2996a532c772d0f243cb4fa785ae1a0d792855d1.webp?v=1760923822","width":2000},{"alt":null,"id":26242233204835,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f816db7a508adea0cdfeafeec72ebe45d36168d4.webp?v=1760923823"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f816db7a508adea0cdfeafeec72ebe45d36168d4.webp?v=1760923823","width":2000},{"alt":null,"id":26242233532515,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12349abbd0596e42520a8e7bf895922f110156c0.webp?v=1760923823"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12349abbd0596e42520a8e7bf895922f110156c0.webp?v=1760923823","width":2000},{"alt":null,"id":26242233794659,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4381f52590841b276b45e5314418d7126663a094.webp?v=1760923824"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4381f52590841b276b45e5314418d7126663a094.webp?v=1760923824","width":2000},{"alt":null,"id":26242234024035,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ed104b4e26704c8e954703741e78e132372d93cf.webp?v=1760923825"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ed104b4e26704c8e954703741e78e132372d93cf.webp?v=1760923825","width":2000},{"alt":null,"id":26242234253411,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/20be709a82fc9a1731b5c336f6237e6e3fc2a381.webp?v=1760923826"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/20be709a82fc9a1731b5c336f6237e6e3fc2a381.webp?v=1760923826","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $bumper = null; $variants = [{"id":43786669391971,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0106424-IT37","requires_shipping":true,"taxable":true,"featured_image":{"id":34672973250659,"product_id":7903443615843,"position":3,"created_at":"2025-10-20T09:30:18+08:00","updated_at":"2025-10-20T09:30:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820","variant_ids":[43786669391971]},"available":true,"name":"iPhone X Mod NX 變種吉娃娃 Godgwawa 五星吉海底餐廳 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0106424-IT37","featured_media":{"alt":null,"id":26242232189027,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43786669391971,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0106424-IT37","requires_shipping":true,"taxable":true,"featured_image":{"id":34672973250659,"product_id":7903443615843,"position":3,"created_at":"2025-10-20T09:30:18+08:00","updated_at":"2025-10-20T09:30:20+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820","variant_ids":[43786669391971]},"available":true,"name":"iPhone X Mod NX 變種吉娃娃 Godgwawa 五星吉海底餐廳 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0106424-IT37","featured_media":{"alt":null,"id":26242232189027,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/96998b182b563c3508c6a4c269f047726537037e.webp?v=1760923820"}},"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: "停產" }