$product = {"id":7892365017187,"title":"iPhone 15 Plus SolidX 小王子 小王子的世界","handle":"iphone-15-plus-solidx-to54","description":null,"published_at":"2025-10-03T10:15:10+08:00","created_at":"2025-10-01T15:38:15+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-le-petit-prince","device-iPhone 15 Plus","merge","reseller-le-petit-prince"],"price":125000,"price_min":125000,"price_max":125000,"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":43755447550051,"title":"Shell Beige","option1":"Shell Beige","option2":null,"option3":null,"sku":"NST012960B-TO54","requires_shipping":true,"taxable":true,"featured_image":{"id":34542013546595,"product_id":7892365017187,"position":10,"created_at":"2025-10-01T15:38:26+08:00","updated_at":"2025-10-01T15:38:28+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308","variant_ids":[43755447550051]},"available":true,"name":"iPhone 15 Plus SolidX 小王子 小王子的世界 - Shell Beige","public_title":"Shell Beige","options":["Shell Beige"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST012960B-TO54","featured_media":{"alt":null,"id":26111778619491,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43755450630243,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NST0129652-TO54","requires_shipping":true,"taxable":true,"featured_image":{"id":34542013186147,"product_id":7892365017187,"position":9,"created_at":"2025-10-01T15:38:26+08:00","updated_at":"2025-10-01T15:38:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307","variant_ids":[43755450630243]},"available":true,"name":"iPhone 15 Plus SolidX 小王子 小王子的世界 - Black","public_title":"Black","options":["Black"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129652-TO54","featured_media":{"alt":null,"id":26111778259043,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3188dfd7d42a3341d129c36a2d905072c7b35970.webp?v=1759304297","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b29c2900178da71cddb98f78bd471c15fa9f2863.webp?v=1759304298","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/299fbd04a6690d97dfd59c1659743e42981adbb7.webp?v=1759304299","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583305bdda6bdd1947fc2f015319b70233237150.webp?v=1759304300","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ebc2c531d89315dbd379b396bc77187fe784aa66.webp?v=1759304301","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e7bd1075b4068c39f5cf541c309155fc0be3f0a.webp?v=1759304301","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b599037999dab653a47b4d7e0c40609a2b550bfb.webp?v=1759304302","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c889285a8d30d7580eb4f550b05648aab14ed469.webp?v=1759304303","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3188dfd7d42a3341d129c36a2d905072c7b35970.webp?v=1759304297","options":["color"],"media":[{"alt":null,"id":26111776161891,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3188dfd7d42a3341d129c36a2d905072c7b35970.webp?v=1759304297"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3188dfd7d42a3341d129c36a2d905072c7b35970.webp?v=1759304297","width":2000},{"alt":null,"id":26111776522339,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b29c2900178da71cddb98f78bd471c15fa9f2863.webp?v=1759304298"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b29c2900178da71cddb98f78bd471c15fa9f2863.webp?v=1759304298","width":2000},{"alt":null,"id":26111776915555,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/299fbd04a6690d97dfd59c1659743e42981adbb7.webp?v=1759304299"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/299fbd04a6690d97dfd59c1659743e42981adbb7.webp?v=1759304299","width":2000},{"alt":null,"id":26111777144931,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583305bdda6bdd1947fc2f015319b70233237150.webp?v=1759304300"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583305bdda6bdd1947fc2f015319b70233237150.webp?v=1759304300","width":2000},{"alt":null,"id":26111777374307,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ebc2c531d89315dbd379b396bc77187fe784aa66.webp?v=1759304301"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ebc2c531d89315dbd379b396bc77187fe784aa66.webp?v=1759304301","width":2000},{"alt":null,"id":26111777636451,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e7bd1075b4068c39f5cf541c309155fc0be3f0a.webp?v=1759304301"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0e7bd1075b4068c39f5cf541c309155fc0be3f0a.webp?v=1759304301","width":2000},{"alt":null,"id":26111777833059,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b599037999dab653a47b4d7e0c40609a2b550bfb.webp?v=1759304302"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b599037999dab653a47b4d7e0c40609a2b550bfb.webp?v=1759304302","width":2000},{"alt":null,"id":26111778062435,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c889285a8d30d7580eb4f550b05648aab14ed469.webp?v=1759304303"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c889285a8d30d7580eb4f550b05648aab14ed469.webp?v=1759304303","width":2000},{"alt":null,"id":26111778259043,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307","width":2000},{"alt":null,"id":26111778619491,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":43755447550051,"title":"Shell Beige","option1":"Shell Beige","option2":null,"option3":null,"sku":"NST012960B-TO54","requires_shipping":true,"taxable":true,"featured_image":{"id":34542013546595,"product_id":7892365017187,"position":10,"created_at":"2025-10-01T15:38:26+08:00","updated_at":"2025-10-01T15:38:28+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308","variant_ids":[43755447550051]},"available":true,"name":"iPhone 15 Plus SolidX 小王子 小王子的世界 - Shell Beige","public_title":"Shell Beige","options":["Shell Beige"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST012960B-TO54","featured_media":{"alt":null,"id":26111778619491,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43755450630243,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NST0129652-TO54","requires_shipping":true,"taxable":true,"featured_image":{"id":34542013186147,"product_id":7892365017187,"position":9,"created_at":"2025-10-01T15:38:26+08:00","updated_at":"2025-10-01T15:38:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307","variant_ids":[43755450630243]},"available":true,"name":"iPhone 15 Plus SolidX 小王子 小王子的世界 - Black","public_title":"Black","options":["Black"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129652-TO54","featured_media":{"alt":null,"id":26111778259043,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c622130b652156abf47c3d4a7758691f881738d.webp?v=1759304307"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43755447550051,"title":"Shell Beige","option1":"Shell Beige","option2":null,"option3":null,"sku":"NST012960B-TO54","requires_shipping":true,"taxable":true,"featured_image":{"id":34542013546595,"product_id":7892365017187,"position":10,"created_at":"2025-10-01T15:38:26+08:00","updated_at":"2025-10-01T15:38:28+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308","variant_ids":[43755447550051]},"available":true,"name":"iPhone 15 Plus SolidX 小王子 小王子的世界 - Shell Beige","public_title":"Shell Beige","options":["Shell Beige"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST012960B-TO54","featured_media":{"alt":null,"id":26111778619491,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/29b7795ae98b9952f68e08d2018f8bd2daf4bdc1.webp?v=1759304308"}},"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: "停產" }