$product = {"id":7414949740643,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Batman - 小丑與蝙蝠俠撲克牌","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-sb15","description":null,"published_at":"2024-06-11T17:53:54+08:00","created_at":"2024-05-05T19:54:24+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Batman","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-batman","device-iPhone 12 pro max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-batman","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":41910261448803,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-SB15","requires_shipping":true,"taxable":true,"featured_image":{"id":31487759515747,"product_id":7414949740643,"position":7,"created_at":"2024-05-05T19:54:41+08:00","updated_at":"2024-05-05T19:54:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081","variant_ids":[41910261448803]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Batman - 小丑與蝙蝠俠撲克牌 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-SB15","featured_media":{"alt":null,"id":23893103444067,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4aa780d7fed9ddc5c19ca6bfd852947e82f1aed8_6a59e1c0-f106-46ff-a1fc-31e12b1cc0c5.webp?v=1714910067","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a15a859b22de561a3c820b8cfbb1b62c27b43b3b_db65c684-1435-459d-ae0f-fb8b83ab17ce.webp?v=1714910069","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24bd628c0d3546d618cb2f78dba7e1d10457a88f_e857491e-43c6-4784-96a8-8232c455bfb7.webp?v=1714910072","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd39c3e7d2be1235882d5fe2ad56d2d3f8be8af6_9e9f3850-b2be-4535-99a6-0760b49e46c8.webp?v=1714910074","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf06c4d56de7818701ea688e9edc4bbe0545d3b_11f39a97-b6a2-4f15-b78e-ea6f755260a4.webp?v=1714910076","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b658343e0381dd553172e8580d683753cd87f8d_e9507a7f-8121-42a4-90b3-4eb80e92d2d3.webp?v=1714910079","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/022a3c9177ed66a70b30d8f6e1e18bce7e9b81ee_c1ecd833-6e56-4f64-b14e-ee919e27b7be.webp?v=1714910084","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16e57af6acefcc0fa54ef515a662bdc6f5697c8_77f9acce-d672-40df-9b86-5450e96cac01.webp?v=1714910086","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9aa0ce3071c4b4c34d0e9f2392c2cccedae10bdd_1247866a-8e5b-4307-b30e-73d293b017cd.webp?v=1714910089"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4aa780d7fed9ddc5c19ca6bfd852947e82f1aed8_6a59e1c0-f106-46ff-a1fc-31e12b1cc0c5.webp?v=1714910067","options":["color"],"media":[{"alt":null,"id":23893100331107,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4aa780d7fed9ddc5c19ca6bfd852947e82f1aed8_6a59e1c0-f106-46ff-a1fc-31e12b1cc0c5.webp?v=1714910067"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4aa780d7fed9ddc5c19ca6bfd852947e82f1aed8_6a59e1c0-f106-46ff-a1fc-31e12b1cc0c5.webp?v=1714910067","width":2000},{"alt":null,"id":23893100626019,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a15a859b22de561a3c820b8cfbb1b62c27b43b3b_db65c684-1435-459d-ae0f-fb8b83ab17ce.webp?v=1714910069"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a15a859b22de561a3c820b8cfbb1b62c27b43b3b_db65c684-1435-459d-ae0f-fb8b83ab17ce.webp?v=1714910069","width":2000},{"alt":null,"id":23893101117539,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24bd628c0d3546d618cb2f78dba7e1d10457a88f_e857491e-43c6-4784-96a8-8232c455bfb7.webp?v=1714910072"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/24bd628c0d3546d618cb2f78dba7e1d10457a88f_e857491e-43c6-4784-96a8-8232c455bfb7.webp?v=1714910072","width":2000},{"alt":null,"id":23893101674595,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd39c3e7d2be1235882d5fe2ad56d2d3f8be8af6_9e9f3850-b2be-4535-99a6-0760b49e46c8.webp?v=1714910074"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd39c3e7d2be1235882d5fe2ad56d2d3f8be8af6_9e9f3850-b2be-4535-99a6-0760b49e46c8.webp?v=1714910074","width":2000},{"alt":null,"id":23893102100579,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf06c4d56de7818701ea688e9edc4bbe0545d3b_11f39a97-b6a2-4f15-b78e-ea6f755260a4.webp?v=1714910076"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf06c4d56de7818701ea688e9edc4bbe0545d3b_11f39a97-b6a2-4f15-b78e-ea6f755260a4.webp?v=1714910076","width":2000},{"alt":null,"id":23893102821475,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b658343e0381dd553172e8580d683753cd87f8d_e9507a7f-8121-42a4-90b3-4eb80e92d2d3.webp?v=1714910079"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b658343e0381dd553172e8580d683753cd87f8d_e9507a7f-8121-42a4-90b3-4eb80e92d2d3.webp?v=1714910079","width":2000},{"alt":null,"id":23893103444067,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081","width":2000},{"alt":null,"id":23893103837283,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/022a3c9177ed66a70b30d8f6e1e18bce7e9b81ee_c1ecd833-6e56-4f64-b14e-ee919e27b7be.webp?v=1714910084"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/022a3c9177ed66a70b30d8f6e1e18bce7e9b81ee_c1ecd833-6e56-4f64-b14e-ee919e27b7be.webp?v=1714910084","width":2000},{"alt":null,"id":23893104328803,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16e57af6acefcc0fa54ef515a662bdc6f5697c8_77f9acce-d672-40df-9b86-5450e96cac01.webp?v=1714910086"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16e57af6acefcc0fa54ef515a662bdc6f5697c8_77f9acce-d672-40df-9b86-5450e96cac01.webp?v=1714910086","width":2000},{"alt":null,"id":23893104787555,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9aa0ce3071c4b4c34d0e9f2392c2cccedae10bdd_1247866a-8e5b-4307-b30e-73d293b017cd.webp?v=1714910089"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9aa0ce3071c4b4c34d0e9f2392c2cccedae10bdd_1247866a-8e5b-4307-b30e-73d293b017cd.webp?v=1714910089","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41910261448803,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-SB15","requires_shipping":true,"taxable":true,"featured_image":{"id":31487759515747,"product_id":7414949740643,"position":7,"created_at":"2024-05-05T19:54:41+08:00","updated_at":"2024-05-05T19:54:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081","variant_ids":[41910261448803]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Batman - 小丑與蝙蝠俠撲克牌 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-SB15","featured_media":{"alt":null,"id":23893103444067,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41910261448803,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-SB15","requires_shipping":true,"taxable":true,"featured_image":{"id":31487759515747,"product_id":7414949740643,"position":7,"created_at":"2024-05-05T19:54:41+08:00","updated_at":"2024-05-05T19:54:41+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081","variant_ids":[41910261448803]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Batman - 小丑與蝙蝠俠撲克牌 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118724-SB15","featured_media":{"alt":null,"id":23893103444067,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2ae4b16b02c2f686a893faf59755f97f3f01cbb1_68879628-046b-4184-9694-3feb676961b1.webp?v=1714910081"}},"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: "停產" }