$product = {"id":7415092346979,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - Care Bears - 美食派對","handle":"iphone-12-mini-mod-nx-magsafe-printable-yb11","description":null,"published_at":"2024-06-11T17:57:46+08:00","created_at":"2024-05-05T20:21:17+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 12 mini","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":41911786438755,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-YB11","requires_shipping":true,"taxable":true,"featured_image":{"id":31488140017763,"product_id":7415092346979,"position":6,"created_at":"2024-05-05T20:21:31+08:00","updated_at":"2024-05-05T20:21:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691","variant_ids":[41911786438755]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 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":"MPB0118424-YB11","featured_media":{"alt":null,"id":23893484568675,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a54ebd8ce88702077b7931c57c5daed4c5f6b05_67745827-4be3-4c30-968d-ca073f1ff057.webp?v=1714911679","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd880f7ec1a288ac7c9501509133dda73914dbc_c52d1a0e-04a7-4310-9e70-670ab098f025.webp?v=1714911682","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbea4c12e7f356b3293a594843bf1845248e61e6_a730d435-3010-451e-b7ad-47a4c2107611.webp?v=1714911684","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a184f83caf67ba0fe808f07dfb29720847ce3525_347cf7d6-0fa5-4ba4-aeb4-63221e9b391d.webp?v=1714911686","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8606c84e0814f12ffe5930cc9d7e41cb9420ce64_ee92de59-6d09-4257-ab0a-6467f65d49ce.webp?v=1714911689","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/529f401d5ce1bb526329577a0a655ee96b7b2f17_644460c2-c336-415a-8e3c-a98a5d6dc3d3.webp?v=1714911694","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/01a51ded7f2b538aacb43537516f6be8edbe5c15_1305106b-3b2c-449f-bd60-bc9713fd27a5.webp?v=1714911696","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e4f9ee528c9829ed97465dce4a3b869f208faa17_be9984a5-8671-405f-ab77-b4a6e49ffbc8.webp?v=1714911698","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51346db5675093817e6246549b15eb9989a204e3_09e86e92-91e8-4c7b-a21e-cb685b418129.webp?v=1714911701","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76a9b713a174c87a4918beafe2d6f04afa126fb8_bd8a1781-fdd8-4cf0-8d40-65bc96833c48.webp?v=1714911703"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a54ebd8ce88702077b7931c57c5daed4c5f6b05_67745827-4be3-4c30-968d-ca073f1ff057.webp?v=1714911679","options":["color"],"media":[{"alt":null,"id":23893481390179,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a54ebd8ce88702077b7931c57c5daed4c5f6b05_67745827-4be3-4c30-968d-ca073f1ff057.webp?v=1714911679"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a54ebd8ce88702077b7931c57c5daed4c5f6b05_67745827-4be3-4c30-968d-ca073f1ff057.webp?v=1714911679","width":2000},{"alt":null,"id":23893482176611,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd880f7ec1a288ac7c9501509133dda73914dbc_c52d1a0e-04a7-4310-9e70-670ab098f025.webp?v=1714911682"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecd880f7ec1a288ac7c9501509133dda73914dbc_c52d1a0e-04a7-4310-9e70-670ab098f025.webp?v=1714911682","width":2000},{"alt":null,"id":23893482864739,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbea4c12e7f356b3293a594843bf1845248e61e6_a730d435-3010-451e-b7ad-47a4c2107611.webp?v=1714911684"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fbea4c12e7f356b3293a594843bf1845248e61e6_a730d435-3010-451e-b7ad-47a4c2107611.webp?v=1714911684","width":2000},{"alt":null,"id":23893483356259,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a184f83caf67ba0fe808f07dfb29720847ce3525_347cf7d6-0fa5-4ba4-aeb4-63221e9b391d.webp?v=1714911686"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a184f83caf67ba0fe808f07dfb29720847ce3525_347cf7d6-0fa5-4ba4-aeb4-63221e9b391d.webp?v=1714911686","width":2000},{"alt":null,"id":23893483880547,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8606c84e0814f12ffe5930cc9d7e41cb9420ce64_ee92de59-6d09-4257-ab0a-6467f65d49ce.webp?v=1714911689"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8606c84e0814f12ffe5930cc9d7e41cb9420ce64_ee92de59-6d09-4257-ab0a-6467f65d49ce.webp?v=1714911689","width":2000},{"alt":null,"id":23893484568675,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691","width":2000},{"alt":null,"id":23893484961891,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/529f401d5ce1bb526329577a0a655ee96b7b2f17_644460c2-c336-415a-8e3c-a98a5d6dc3d3.webp?v=1714911694"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/529f401d5ce1bb526329577a0a655ee96b7b2f17_644460c2-c336-415a-8e3c-a98a5d6dc3d3.webp?v=1714911694","width":2000},{"alt":null,"id":23893485486179,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/01a51ded7f2b538aacb43537516f6be8edbe5c15_1305106b-3b2c-449f-bd60-bc9713fd27a5.webp?v=1714911696"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/01a51ded7f2b538aacb43537516f6be8edbe5c15_1305106b-3b2c-449f-bd60-bc9713fd27a5.webp?v=1714911696","width":2000},{"alt":null,"id":23893486403683,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e4f9ee528c9829ed97465dce4a3b869f208faa17_be9984a5-8671-405f-ab77-b4a6e49ffbc8.webp?v=1714911698"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e4f9ee528c9829ed97465dce4a3b869f208faa17_be9984a5-8671-405f-ab77-b4a6e49ffbc8.webp?v=1714911698","width":2000},{"alt":null,"id":23893486993507,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51346db5675093817e6246549b15eb9989a204e3_09e86e92-91e8-4c7b-a21e-cb685b418129.webp?v=1714911701"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51346db5675093817e6246549b15eb9989a204e3_09e86e92-91e8-4c7b-a21e-cb685b418129.webp?v=1714911701","width":2000},{"alt":null,"id":23893487550563,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76a9b713a174c87a4918beafe2d6f04afa126fb8_bd8a1781-fdd8-4cf0-8d40-65bc96833c48.webp?v=1714911703"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76a9b713a174c87a4918beafe2d6f04afa126fb8_bd8a1781-fdd8-4cf0-8d40-65bc96833c48.webp?v=1714911703","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41911786438755,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-YB11","requires_shipping":true,"taxable":true,"featured_image":{"id":31488140017763,"product_id":7415092346979,"position":6,"created_at":"2024-05-05T20:21:31+08:00","updated_at":"2024-05-05T20:21:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691","variant_ids":[41911786438755]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 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":"MPB0118424-YB11","featured_media":{"alt":null,"id":23893484568675,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41911786438755,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-YB11","requires_shipping":true,"taxable":true,"featured_image":{"id":31488140017763,"product_id":7415092346979,"position":6,"created_at":"2024-05-05T20:21:31+08:00","updated_at":"2024-05-05T20:21:31+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691","variant_ids":[41911786438755]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 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":"MPB0118424-YB11","featured_media":{"alt":null,"id":23893484568675,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581787e4a37f8ead53bb3872c0a017d6e0f55805_907aface-d31d-47b4-bb5b-d989db0b054c.webp?v=1714911691"}},"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: "停產" }