$product = {"id":7414936174691,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Weiweiboy - 可愛大王上甜點","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-eo04","description":null,"published_at":"2024-06-11T17:53:32+08:00","created_at":"2024-05-05T19:51:59+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Weiweiboy","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-weiweiboy","device-iPhone 12 pro max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-weiweiboy","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":41910115237987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-EO04","requires_shipping":true,"taxable":true,"featured_image":{"id":31487722815587,"product_id":7414936174691,"position":2,"created_at":"2024-05-05T19:52:04+08:00","updated_at":"2024-05-05T19:52:04+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924","variant_ids":[41910115237987]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Weiweiboy - 可愛大王上甜點 - 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":"MPB0118724-EO04","featured_media":{"alt":null,"id":23893066678371,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25e09c761b9f464caf7a9f6b05add56b238e7bdd_1f08fa4f-6e04-4753-8787-878c0c2fec7e.webp?v=1714909922","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4857f0db9f700b0a50c79e50f0283cc8d2f512df_20214238-fc07-490c-bfb6-7421b8e4926f.webp?v=1714909927","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9928ccd841248e6a9d87bb70246ffdae07b1ea5c_8ae52662-5f16-44f9-9390-4d5c396fd217.webp?v=1714909929","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a0b5cdc7efdcfb42accaf9faf413225e36a0b225_d5cfea87-3a5f-4978-b7e5-33addfc64436.webp?v=1714909931","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e59ab84b21596021348e32427432f655dee0101_e6fd8525-30d8-4e1a-9e5a-d1a8c8bf8ff4.webp?v=1714909934","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf552a2ef4782e1ebad13dc0add60be866e20bea_1ea7898f-436b-4d3c-9f5d-c3bd9dac4167.webp?v=1714909936","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8256c8460bbcfe075ee43085af3f81469c61fc2_d839479e-68f8-484d-baa4-372e5952591d.webp?v=1714909939","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9d2ff14b3c46935000d4c41cbe352d709616968_948fb152-542e-4423-85b6-7075de8fa7ad.webp?v=1714909941","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11dd6acb791f524f846550f721cfd37295ff1316_57f9ad20-e82e-4cdd-a2ab-b142938f54b9.webp?v=1714909944","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7dd9a291b4a90b6f311d7ddf6b8061198d8f5df1_ce9fc262-8431-4e2d-a8e2-446c380087b5.webp?v=1714909946"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25e09c761b9f464caf7a9f6b05add56b238e7bdd_1f08fa4f-6e04-4753-8787-878c0c2fec7e.webp?v=1714909922","options":["color"],"media":[{"alt":null,"id":23893066055779,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25e09c761b9f464caf7a9f6b05add56b238e7bdd_1f08fa4f-6e04-4753-8787-878c0c2fec7e.webp?v=1714909922"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25e09c761b9f464caf7a9f6b05add56b238e7bdd_1f08fa4f-6e04-4753-8787-878c0c2fec7e.webp?v=1714909922","width":2000},{"alt":null,"id":23893066678371,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924","width":2000},{"alt":null,"id":23893067137123,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4857f0db9f700b0a50c79e50f0283cc8d2f512df_20214238-fc07-490c-bfb6-7421b8e4926f.webp?v=1714909927"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4857f0db9f700b0a50c79e50f0283cc8d2f512df_20214238-fc07-490c-bfb6-7421b8e4926f.webp?v=1714909927","width":2000},{"alt":null,"id":23893067595875,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9928ccd841248e6a9d87bb70246ffdae07b1ea5c_8ae52662-5f16-44f9-9390-4d5c396fd217.webp?v=1714909929"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9928ccd841248e6a9d87bb70246ffdae07b1ea5c_8ae52662-5f16-44f9-9390-4d5c396fd217.webp?v=1714909929","width":2000},{"alt":null,"id":23893068218467,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a0b5cdc7efdcfb42accaf9faf413225e36a0b225_d5cfea87-3a5f-4978-b7e5-33addfc64436.webp?v=1714909931"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a0b5cdc7efdcfb42accaf9faf413225e36a0b225_d5cfea87-3a5f-4978-b7e5-33addfc64436.webp?v=1714909931","width":2000},{"alt":null,"id":23893069037667,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e59ab84b21596021348e32427432f655dee0101_e6fd8525-30d8-4e1a-9e5a-d1a8c8bf8ff4.webp?v=1714909934"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4e59ab84b21596021348e32427432f655dee0101_e6fd8525-30d8-4e1a-9e5a-d1a8c8bf8ff4.webp?v=1714909934","width":2000},{"alt":null,"id":23893069463651,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf552a2ef4782e1ebad13dc0add60be866e20bea_1ea7898f-436b-4d3c-9f5d-c3bd9dac4167.webp?v=1714909936"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf552a2ef4782e1ebad13dc0add60be866e20bea_1ea7898f-436b-4d3c-9f5d-c3bd9dac4167.webp?v=1714909936","width":2000},{"alt":null,"id":23893069856867,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8256c8460bbcfe075ee43085af3f81469c61fc2_d839479e-68f8-484d-baa4-372e5952591d.webp?v=1714909939"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a8256c8460bbcfe075ee43085af3f81469c61fc2_d839479e-68f8-484d-baa4-372e5952591d.webp?v=1714909939","width":2000},{"alt":null,"id":23893070577763,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9d2ff14b3c46935000d4c41cbe352d709616968_948fb152-542e-4423-85b6-7075de8fa7ad.webp?v=1714909941"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9d2ff14b3c46935000d4c41cbe352d709616968_948fb152-542e-4423-85b6-7075de8fa7ad.webp?v=1714909941","width":2000},{"alt":null,"id":23893071003747,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11dd6acb791f524f846550f721cfd37295ff1316_57f9ad20-e82e-4cdd-a2ab-b142938f54b9.webp?v=1714909944"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/11dd6acb791f524f846550f721cfd37295ff1316_57f9ad20-e82e-4cdd-a2ab-b142938f54b9.webp?v=1714909944","width":2000},{"alt":null,"id":23893071528035,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7dd9a291b4a90b6f311d7ddf6b8061198d8f5df1_ce9fc262-8431-4e2d-a8e2-446c380087b5.webp?v=1714909946"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7dd9a291b4a90b6f311d7ddf6b8061198d8f5df1_ce9fc262-8431-4e2d-a8e2-446c380087b5.webp?v=1714909946","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41910115237987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-EO04","requires_shipping":true,"taxable":true,"featured_image":{"id":31487722815587,"product_id":7414936174691,"position":2,"created_at":"2024-05-05T19:52:04+08:00","updated_at":"2024-05-05T19:52:04+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924","variant_ids":[41910115237987]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Weiweiboy - 可愛大王上甜點 - 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":"MPB0118724-EO04","featured_media":{"alt":null,"id":23893066678371,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41910115237987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-EO04","requires_shipping":true,"taxable":true,"featured_image":{"id":31487722815587,"product_id":7414936174691,"position":2,"created_at":"2024-05-05T19:52:04+08:00","updated_at":"2024-05-05T19:52:04+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924","variant_ids":[41910115237987]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Weiweiboy - 可愛大王上甜點 - 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":"MPB0118724-EO04","featured_media":{"alt":null,"id":23893066678371,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a81f490f9fd8943bd190ec69ec7e171ebd4df04e_674e106e-0f8d-42ee-8c3b-0c8d9086aced.webp?v=1714909924"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}; $device_handle = null; $type = ""; var sellingStatus if ($isMerge) { $(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: "停產" }