$product = {"id":7824067100771,"title":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎?","handle":"iphone-15-pro-solidx-rk17","description":null,"published_at":"2025-07-01T18:42:16+08:00","created_at":"2025-06-20T17:02:04+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-squarestudio","device-iPhone 15 Pro","merge","reseller-squarestudio"],"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":43475548700771,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NST0129752-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187373772899,"product_id":7824067100771,"position":7,"created_at":"2025-07-15T17:34:11+08:00","updated_at":"2025-07-15T17:34:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053","variant_ids":[43475548700771]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Black","public_title":"Black","options":["Black"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129752-RK17","featured_media":{"alt":null,"id":25822738317411,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551551587,"title":"Ocean Blue","option1":"Ocean Blue","option2":null,"option3":null,"sku":"NST012970A-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187372003427,"product_id":7824067100771,"position":4,"created_at":"2025-07-15T17:34:09+08:00","updated_at":"2025-07-15T17:34:11+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051","variant_ids":[43475551551587]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Ocean Blue","public_title":"Ocean Blue","options":["Ocean Blue"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST012970A-RK17","featured_media":{"alt":null,"id":25822737039459,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551584355,"title":"White","option1":"White","option2":null,"option3":null,"sku":"NST0129753-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187371348067,"product_id":7824067100771,"position":3,"created_at":"2025-07-15T17:34:09+08:00","updated_at":"2025-07-15T17:34:11+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051","variant_ids":[43475551584355]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - White","public_title":"White","options":["White"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129753-RK17","featured_media":{"alt":null,"id":25822736711779,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551617123,"title":"Shell Beige","option1":"Shell Beige","option2":null,"option3":null,"sku":"NST012970B-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187373019235,"product_id":7824067100771,"position":6,"created_at":"2025-07-15T17:34:10+08:00","updated_at":"2025-07-15T17:34:12+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052","variant_ids":[43475551617123]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - 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":"NST012970B-RK17","featured_media":{"alt":null,"id":25822738022499,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551649891,"title":"Seaweed Green","option1":"Seaweed Green","option2":null,"option3":null,"sku":"NST01297Z8-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187374231651,"product_id":7824067100771,"position":8,"created_at":"2025-07-15T17:34:12+08:00","updated_at":"2025-07-15T17:34:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053","variant_ids":[43475551649891]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Seaweed Green","public_title":"Seaweed Green","options":["Seaweed Green"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST01297Z8-RK17","featured_media":{"alt":null,"id":25822738612323,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-297-RK17.png?v=1750410128","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-295-RK17_daa797a9-7650-4249-b920-c9a2bb49ddb0.png?v=1750823684","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08a292c4c1cd9117a064041f41ff2e95157ab8fb.webp?v=1752572052","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aea26d4473001a10f25ed2edeeeb6e7e03ed86.webp?v=1752572054","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e593eb75a5fd66eb476f504e2ff17b8927763a1.webp?v=1752572054","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c11de32c6995b5962ddf8774ea679988f8285a78.webp?v=1752572055","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a94f0b963f28e298d51e2246deb7e6668acaa64c.webp?v=1752572056"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-297-RK17.png?v=1750410128","options":["color"],"media":[{"alt":null,"id":25721579569251,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-297-RK17.png?v=1750410128"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-297-RK17.png?v=1750410128","width":2000},{"alt":null,"id":25735499939939,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-295-RK17_daa797a9-7650-4249-b920-c9a2bb49ddb0.png?v=1750823684"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/SolidX-52-295-RK17_daa797a9-7650-4249-b920-c9a2bb49ddb0.png?v=1750823684","width":2000},{"alt":null,"id":25822736711779,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051","width":2000},{"alt":null,"id":25822737039459,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051","width":2000},{"alt":null,"id":25822737662051,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08a292c4c1cd9117a064041f41ff2e95157ab8fb.webp?v=1752572052"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08a292c4c1cd9117a064041f41ff2e95157ab8fb.webp?v=1752572052","width":2000},{"alt":null,"id":25822738022499,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052","width":2000},{"alt":null,"id":25822738317411,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053","width":2000},{"alt":null,"id":25822738612323,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053","width":2000},{"alt":null,"id":25822738972771,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aea26d4473001a10f25ed2edeeeb6e7e03ed86.webp?v=1752572054"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aea26d4473001a10f25ed2edeeeb6e7e03ed86.webp?v=1752572054","width":2000},{"alt":null,"id":25822739267683,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e593eb75a5fd66eb476f504e2ff17b8927763a1.webp?v=1752572054"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5e593eb75a5fd66eb476f504e2ff17b8927763a1.webp?v=1752572054","width":2000},{"alt":null,"id":25822739529827,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c11de32c6995b5962ddf8774ea679988f8285a78.webp?v=1752572055"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c11de32c6995b5962ddf8774ea679988f8285a78.webp?v=1752572055","width":2000},{"alt":null,"id":25822739824739,"position":12,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a94f0b963f28e298d51e2246deb7e6668acaa64c.webp?v=1752572056"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a94f0b963f28e298d51e2246deb7e6668acaa64c.webp?v=1752572056","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":43475548700771,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NST0129752-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187373772899,"product_id":7824067100771,"position":7,"created_at":"2025-07-15T17:34:11+08:00","updated_at":"2025-07-15T17:34:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053","variant_ids":[43475548700771]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Black","public_title":"Black","options":["Black"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129752-RK17","featured_media":{"alt":null,"id":25822738317411,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551551587,"title":"Ocean Blue","option1":"Ocean Blue","option2":null,"option3":null,"sku":"NST012970A-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187372003427,"product_id":7824067100771,"position":4,"created_at":"2025-07-15T17:34:09+08:00","updated_at":"2025-07-15T17:34:11+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051","variant_ids":[43475551551587]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Ocean Blue","public_title":"Ocean Blue","options":["Ocean Blue"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST012970A-RK17","featured_media":{"alt":null,"id":25822737039459,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33c2b3fe44b93dd682bedb520116e261d5086dfd.webp?v=1752572051"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551584355,"title":"White","option1":"White","option2":null,"option3":null,"sku":"NST0129753-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187371348067,"product_id":7824067100771,"position":3,"created_at":"2025-07-15T17:34:09+08:00","updated_at":"2025-07-15T17:34:11+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051","variant_ids":[43475551584355]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - White","public_title":"White","options":["White"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129753-RK17","featured_media":{"alt":null,"id":25822736711779,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10939dd83a6e2ce0e96e032d5cf021b94e34cf04.webp?v=1752572051"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551617123,"title":"Shell Beige","option1":"Shell Beige","option2":null,"option3":null,"sku":"NST012970B-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187373019235,"product_id":7824067100771,"position":6,"created_at":"2025-07-15T17:34:10+08:00","updated_at":"2025-07-15T17:34:12+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052","variant_ids":[43475551617123]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - 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":"NST012970B-RK17","featured_media":{"alt":null,"id":25822738022499,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be6c3a4cb09200f843cb603d2d5437e302cd8dd7.webp?v=1752572052"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43475551649891,"title":"Seaweed Green","option1":"Seaweed Green","option2":null,"option3":null,"sku":"NST01297Z8-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187374231651,"product_id":7824067100771,"position":8,"created_at":"2025-07-15T17:34:12+08:00","updated_at":"2025-07-15T17:34:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053","variant_ids":[43475551649891]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Seaweed Green","public_title":"Seaweed Green","options":["Seaweed Green"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST01297Z8-RK17","featured_media":{"alt":null,"id":25822738612323,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4ef545584168620fa806f91b76108f7612e5d3b3.webp?v=1752572053"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43475548700771,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NST0129752-RK17","requires_shipping":true,"taxable":true,"featured_image":{"id":34187373772899,"product_id":7824067100771,"position":7,"created_at":"2025-07-15T17:34:11+08:00","updated_at":"2025-07-15T17:34:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053","variant_ids":[43475548700771]},"available":true,"name":"iPhone 15 Pro SolidX 方坊 Square Studio 今天好嗎? - Black","public_title":"Black","options":["Black"],"price":125000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NST0129752-RK17","featured_media":{"alt":null,"id":25822738317411,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a16606c28a486960ab75740ce32e6434305c4bd.webp?v=1752572053"}},"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: "停產" }