$product = {"id":7411372490851,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Care Bears - 熊滿星空","handle":"iphone-14-plus-mod-nx-magsafe-printable-yb09","description":null,"published_at":"2024-06-11T17:43:10+08:00","created_at":"2024-05-05T00:16:57+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Care Bears","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-carebears","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-carebears","Top50","type-Mod NX Printable MagSafe Printable"],"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":41898055762019,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-YB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480262099043,"product_id":7411372490851,"position":10,"created_at":"2024-05-05T00:17:21+08:00","updated_at":"2024-05-05T00:17:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441","variant_ids":[41898055762019]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Care Bears - 熊滿星空 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-YB09","featured_media":{"alt":null,"id":23885513359459,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75ea32ad5cb17d56d005a0199e1c904fee626541_853461a4-20e4-4057-abb0-1e88b8c6567c.webp?v=1714839419","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60f0ab5ab2e964b48ac15d0f73b3e4eae51eb085_fccd08d9-f50c-4bc0-9fa3-8867a1ba3ba6.webp?v=1714839422","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f02426e5d1769853a5807138a079ac3778f41f2b_e5f6213f-21b4-4140-bb98-8719640f49c8.webp?v=1714839424","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a94459bebd198776437ce6ea76874cdd87a4e21_d4961f50-db16-4ef8-854e-eb9d1a601f3c.webp?v=1714839426","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e59040258b25d4ab03aab2112024de7ec0628aea_0fece6b7-2946-4a74-be96-3e2ce65689b5.webp?v=1714839429","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b8ceeffc9a1784adab3584d743a837c59f107e00_697157b8-a42b-4378-858a-a3ff930a46da.webp?v=1714839431","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b79176f79475ae7b8348186d4799e0c59159d93d_d18fa721-135e-430a-b2e2-c78ffed0c9ba.webp?v=1714839434","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3535f4ad704c47db10bbaee0a7dcdfa4745adb9b_c557fa0c-b17e-4428-9729-5802727735f8.webp?v=1714839436","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60409f9c430d368ea537f685d17318d2329273a5_018d9ce7-d6a7-44dd-b9dc-e8ee49558bc1.webp?v=1714839438","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75ea32ad5cb17d56d005a0199e1c904fee626541_853461a4-20e4-4057-abb0-1e88b8c6567c.webp?v=1714839419","options":["color"],"media":[{"alt":null,"id":23885508771939,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75ea32ad5cb17d56d005a0199e1c904fee626541_853461a4-20e4-4057-abb0-1e88b8c6567c.webp?v=1714839419"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75ea32ad5cb17d56d005a0199e1c904fee626541_853461a4-20e4-4057-abb0-1e88b8c6567c.webp?v=1714839419","width":2000},{"alt":null,"id":23885509296227,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60f0ab5ab2e964b48ac15d0f73b3e4eae51eb085_fccd08d9-f50c-4bc0-9fa3-8867a1ba3ba6.webp?v=1714839422"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60f0ab5ab2e964b48ac15d0f73b3e4eae51eb085_fccd08d9-f50c-4bc0-9fa3-8867a1ba3ba6.webp?v=1714839422","width":2000},{"alt":null,"id":23885509722211,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f02426e5d1769853a5807138a079ac3778f41f2b_e5f6213f-21b4-4140-bb98-8719640f49c8.webp?v=1714839424"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f02426e5d1769853a5807138a079ac3778f41f2b_e5f6213f-21b4-4140-bb98-8719640f49c8.webp?v=1714839424","width":2000},{"alt":null,"id":23885510246499,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a94459bebd198776437ce6ea76874cdd87a4e21_d4961f50-db16-4ef8-854e-eb9d1a601f3c.webp?v=1714839426"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4a94459bebd198776437ce6ea76874cdd87a4e21_d4961f50-db16-4ef8-854e-eb9d1a601f3c.webp?v=1714839426","width":2000},{"alt":null,"id":23885510836323,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e59040258b25d4ab03aab2112024de7ec0628aea_0fece6b7-2946-4a74-be96-3e2ce65689b5.webp?v=1714839429"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e59040258b25d4ab03aab2112024de7ec0628aea_0fece6b7-2946-4a74-be96-3e2ce65689b5.webp?v=1714839429","width":2000},{"alt":null,"id":23885511229539,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b8ceeffc9a1784adab3584d743a837c59f107e00_697157b8-a42b-4378-858a-a3ff930a46da.webp?v=1714839431"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b8ceeffc9a1784adab3584d743a837c59f107e00_697157b8-a42b-4378-858a-a3ff930a46da.webp?v=1714839431","width":2000},{"alt":null,"id":23885511786595,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b79176f79475ae7b8348186d4799e0c59159d93d_d18fa721-135e-430a-b2e2-c78ffed0c9ba.webp?v=1714839434"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b79176f79475ae7b8348186d4799e0c59159d93d_d18fa721-135e-430a-b2e2-c78ffed0c9ba.webp?v=1714839434","width":2000},{"alt":null,"id":23885512343651,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3535f4ad704c47db10bbaee0a7dcdfa4745adb9b_c557fa0c-b17e-4428-9729-5802727735f8.webp?v=1714839436"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3535f4ad704c47db10bbaee0a7dcdfa4745adb9b_c557fa0c-b17e-4428-9729-5802727735f8.webp?v=1714839436","width":2000},{"alt":null,"id":23885512867939,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60409f9c430d368ea537f685d17318d2329273a5_018d9ce7-d6a7-44dd-b9dc-e8ee49558bc1.webp?v=1714839438"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60409f9c430d368ea537f685d17318d2329273a5_018d9ce7-d6a7-44dd-b9dc-e8ee49558bc1.webp?v=1714839438","width":2000},{"alt":null,"id":23885513359459,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41898055762019,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-YB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480262099043,"product_id":7411372490851,"position":10,"created_at":"2024-05-05T00:17:21+08:00","updated_at":"2024-05-05T00:17:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441","variant_ids":[41898055762019]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Care Bears - 熊滿星空 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-YB09","featured_media":{"alt":null,"id":23885513359459,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41898055762019,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-YB09","requires_shipping":true,"taxable":true,"featured_image":{"id":31480262099043,"product_id":7411372490851,"position":10,"created_at":"2024-05-05T00:17:21+08:00","updated_at":"2024-05-05T00:17:21+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441","variant_ids":[41898055762019]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Care Bears - 熊滿星空 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-YB09","featured_media":{"alt":null,"id":23885513359459,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/afe1d68d21249161ce26bc5b2aab82c011ed71fd_91b63d72-e824-40bf-a7a1-84a48e7fcc21.webp?v=1714839441"}},"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: "停產" }