$product = {"id":7769615466595,"title":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓","handle":"iphone-xr-mod-nx-printable-xf53","description":null,"published_at":"2025-07-16T17:17:51+08:00","created_at":"2025-04-15T18:29:08+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-I Love Doodle","tags":["10%","20%","30%","40%","50%","brand-Apple","designer","designer-ilovedoodle","device-iPhone XR","merge","reseller-ilovedoodle"],"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":43303182008419,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0108524-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196718911587,"product_id":7769615466595,"position":7,"created_at":"2025-07-16T14:49:47+08:00","updated_at":"2025-07-16T14:49:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589","variant_ids":[43303182008419]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108524-XF53","featured_media":{"alt":null,"id":25829507661923,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185547363,"title":"White","option1":"White","option2":null,"option3":null,"sku":"NPB0108504-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196717994083,"product_id":7769615466595,"position":4,"created_at":"2025-07-16T14:49:45+08:00","updated_at":"2025-07-16T14:49:47+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587","variant_ids":[43303185547363]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - White","public_title":"White","options":["White"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108504-XF53","featured_media":{"alt":null,"id":25829506744419,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185645667,"title":"Camo Green","option1":"Camo Green","option2":null,"option3":null,"sku":"NPB0108515-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196719272035,"product_id":7769615466595,"position":8,"created_at":"2025-07-16T14:49:48+08:00","updated_at":"2025-07-16T14:49:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589","variant_ids":[43303185645667]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Camo Green","public_title":"Camo Green","options":["Camo Green"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108515-XF53","featured_media":{"alt":null,"id":25829507825763,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185678435,"title":"Lavender","option1":"Lavender","option2":null,"option3":null,"sku":"NPB01085C1-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196718780515,"product_id":7769615466595,"position":6,"created_at":"2025-07-16T14:49:46+08:00","updated_at":"2025-07-16T14:49:48+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588","variant_ids":[43303185678435]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Lavender","public_title":"Lavender","options":["Lavender"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB01085C1-XF53","featured_media":{"alt":null,"id":25829507104867,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c55a327c67dbddf71c832c5c962df126c4e7eb14.webp?v=1744712955","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ada683087d9503c866f479a92183cb18c1529edc_6ff57a66-2a62-43fa-a40f-6bcec41cfc42.webp?v=1752648586","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/905c173f7132f3b37464e4571a154496b7d04b43_7d22bfaa-d20f-4848-b19f-12fcfc580730.webp?v=1752648587","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/613d1565b000eb0f8221b107ad25b17597b765dd_6eccf915-9b36-4e41-914a-b0fd55cd65c4.webp?v=1752648588","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44de6c88955593afb16a5d20491db26ed0edc2d0_8416b044-f5a7-4679-8dc5-3f2746389d45.webp?v=1752648590","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d9baaf451757ff4593a2692cec10510bebcd557_f4a8fc95-ec95-4c70-a91e-d2cd2c072121.webp?v=1752648590","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03e6b7a74bfd26159ba907b36e169a54540af6b2_647d027e-f9f9-4c0d-8a95-2cbff93ecb3e.webp?v=1752648591"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c55a327c67dbddf71c832c5c962df126c4e7eb14.webp?v=1744712955","options":["color"],"media":[{"alt":null,"id":25495964450915,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c55a327c67dbddf71c832c5c962df126c4e7eb14.webp?v=1744712955"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c55a327c67dbddf71c832c5c962df126c4e7eb14.webp?v=1744712955","width":2000},{"alt":null,"id":25829506089059,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ada683087d9503c866f479a92183cb18c1529edc_6ff57a66-2a62-43fa-a40f-6bcec41cfc42.webp?v=1752648586"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ada683087d9503c866f479a92183cb18c1529edc_6ff57a66-2a62-43fa-a40f-6bcec41cfc42.webp?v=1752648586","width":2000},{"alt":null,"id":25829506646115,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/905c173f7132f3b37464e4571a154496b7d04b43_7d22bfaa-d20f-4848-b19f-12fcfc580730.webp?v=1752648587"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/905c173f7132f3b37464e4571a154496b7d04b43_7d22bfaa-d20f-4848-b19f-12fcfc580730.webp?v=1752648587","width":2000},{"alt":null,"id":25829506744419,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587","width":2000},{"alt":null,"id":25829506941027,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/613d1565b000eb0f8221b107ad25b17597b765dd_6eccf915-9b36-4e41-914a-b0fd55cd65c4.webp?v=1752648588"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/613d1565b000eb0f8221b107ad25b17597b765dd_6eccf915-9b36-4e41-914a-b0fd55cd65c4.webp?v=1752648588","width":2000},{"alt":null,"id":25829507104867,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588","width":2000},{"alt":null,"id":25829507661923,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589","width":2000},{"alt":null,"id":25829507825763,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589","width":2000},{"alt":null,"id":25829508055139,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44de6c88955593afb16a5d20491db26ed0edc2d0_8416b044-f5a7-4679-8dc5-3f2746389d45.webp?v=1752648590"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44de6c88955593afb16a5d20491db26ed0edc2d0_8416b044-f5a7-4679-8dc5-3f2746389d45.webp?v=1752648590","width":2000},{"alt":null,"id":25829508251747,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d9baaf451757ff4593a2692cec10510bebcd557_f4a8fc95-ec95-4c70-a91e-d2cd2c072121.webp?v=1752648590"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d9baaf451757ff4593a2692cec10510bebcd557_f4a8fc95-ec95-4c70-a91e-d2cd2c072121.webp?v=1752648590","width":2000},{"alt":null,"id":25829508415587,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03e6b7a74bfd26159ba907b36e169a54540af6b2_647d027e-f9f9-4c0d-8a95-2cbff93ecb3e.webp?v=1752648591"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03e6b7a74bfd26159ba907b36e169a54540af6b2_647d027e-f9f9-4c0d-8a95-2cbff93ecb3e.webp?v=1752648591","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":43303182008419,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0108524-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196718911587,"product_id":7769615466595,"position":7,"created_at":"2025-07-16T14:49:47+08:00","updated_at":"2025-07-16T14:49:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589","variant_ids":[43303182008419]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108524-XF53","featured_media":{"alt":null,"id":25829507661923,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185547363,"title":"White","option1":"White","option2":null,"option3":null,"sku":"NPB0108504-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196717994083,"product_id":7769615466595,"position":4,"created_at":"2025-07-16T14:49:45+08:00","updated_at":"2025-07-16T14:49:47+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587","variant_ids":[43303185547363]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - White","public_title":"White","options":["White"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108504-XF53","featured_media":{"alt":null,"id":25829506744419,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c0152a2c69fd96ac69a573ddebda0b9df142e22_ff3ffa8d-d05b-4061-92ce-a634827b1363.webp?v=1752648587"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185645667,"title":"Camo Green","option1":"Camo Green","option2":null,"option3":null,"sku":"NPB0108515-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196719272035,"product_id":7769615466595,"position":8,"created_at":"2025-07-16T14:49:48+08:00","updated_at":"2025-07-16T14:49:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589","variant_ids":[43303185645667]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Camo Green","public_title":"Camo Green","options":["Camo Green"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108515-XF53","featured_media":{"alt":null,"id":25829507825763,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0657b4a53fd19a762ef48eec9be9d1cf997108d8_d9f9d018-5252-4a57-8fd0-c2734d9b824f.webp?v=1752648589"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":43303185678435,"title":"Lavender","option1":"Lavender","option2":null,"option3":null,"sku":"NPB01085C1-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196718780515,"product_id":7769615466595,"position":6,"created_at":"2025-07-16T14:49:46+08:00","updated_at":"2025-07-16T14:49:48+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588","variant_ids":[43303185678435]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Lavender","public_title":"Lavender","options":["Lavender"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB01085C1-XF53","featured_media":{"alt":null,"id":25829507104867,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6e1af8bf9bed1c08ff4698caedd39fb3381aa961_9a8ba976-6695-4a60-a13e-e1eda1661083.webp?v=1752648588"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":43303182008419,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"NPB0108524-XF53","requires_shipping":true,"taxable":true,"featured_image":{"id":34196718911587,"product_id":7769615466595,"position":7,"created_at":"2025-07-16T14:49:47+08:00","updated_at":"2025-07-16T14:49:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589","variant_ids":[43303182008419]},"available":true,"name":"iPhone XR Mod NX ilovedoodle Lunar Mirage Cat - 月光貓 - Black","public_title":"Black","options":["Black"],"price":90000,"weight":0,"compare_at_price":null,"inventory_quantity":0,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108524-XF53","featured_media":{"alt":null,"id":25829507661923,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0d48b8e47b155dd3cd2ab1cb0272dcfdfdff11b_50f34d20-47c2-4f9d-855f-6ce6d70658fa.webp?v=1752648589"}},"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: "停產" }