$product = {"id":7408392011875,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Batman - 黑白畫風-蝙蝠俠","handle":"iphone-12-pro-max-mod-nx-printable-sb12","description":null,"published_at":"2024-06-11T16:35:58+08:00","created_at":"2024-05-03T15:17:27+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Batman","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-batman","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-batman","Top50","type-Mod NX Printable"],"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":41884966486115,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-SB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31472141860963,"product_id":7408392011875,"position":3,"created_at":"2024-05-03T15:17:34+08:00","updated_at":"2024-05-03T15:17:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654","variant_ids":[41884966486115]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Batman - 黑白畫風-蝙蝠俠 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-SB12","featured_media":{"alt":null,"id":23877057445987,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/075a3ce262724d8485ed5288d14dcb3c16bcc00d_cad009c3-49e2-47ae-802d-3e7f42cf4bca.webp?v=1714720650","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fc5bf41165f1ca9337fcac14212e3e6da5e1284b_69709f1d-e9e8-43e7-b596-cb72bfc4744a.webp?v=1714720652","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/da0e43786fbca98123a6004babada8535c4f6961_45cc2413-9e95-479e-94ec-4469adc8da0b.webp?v=1714720657","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9c5f549e347222a37b2aaf90d156d8582afa2822_04544c43-32d9-4f47-87c0-7de47d63d26f.webp?v=1714720659","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c8173e18fe354bf1f0d847170c98f32ee85178b0_122f6c0b-4175-496a-8a86-8d9679847441.webp?v=1714720661","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d6e585bd5045fe4bbce04a114a7431b77f50881_c52a8785-6063-4245-95b6-7d6825a620ac.webp?v=1714720664","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b158a2ef782a3628738635a2b3ccdee05480a09_6fd1216b-7ce7-4219-a740-12b0ca394b24.webp?v=1714720666","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7caabf33dd78fb8502092d7dcdb408b9939eb1d0_11df49eb-c64c-43f8-bed1-c6322e7bef2f.webp?v=1714720668","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b55a4d552649dc943156fe8684895763f432fc3f_dbce5f59-87cd-4c5c-b419-6093b2f844d5.webp?v=1714720670"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/075a3ce262724d8485ed5288d14dcb3c16bcc00d_cad009c3-49e2-47ae-802d-3e7f42cf4bca.webp?v=1714720650","options":["color"],"media":[{"alt":null,"id":23877056168035,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/075a3ce262724d8485ed5288d14dcb3c16bcc00d_cad009c3-49e2-47ae-802d-3e7f42cf4bca.webp?v=1714720650"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/075a3ce262724d8485ed5288d14dcb3c16bcc00d_cad009c3-49e2-47ae-802d-3e7f42cf4bca.webp?v=1714720650","width":2000},{"alt":null,"id":23877056528483,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fc5bf41165f1ca9337fcac14212e3e6da5e1284b_69709f1d-e9e8-43e7-b596-cb72bfc4744a.webp?v=1714720652"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fc5bf41165f1ca9337fcac14212e3e6da5e1284b_69709f1d-e9e8-43e7-b596-cb72bfc4744a.webp?v=1714720652","width":2000},{"alt":null,"id":23877057445987,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654","width":2000},{"alt":null,"id":23877058035811,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/da0e43786fbca98123a6004babada8535c4f6961_45cc2413-9e95-479e-94ec-4469adc8da0b.webp?v=1714720657"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/da0e43786fbca98123a6004babada8535c4f6961_45cc2413-9e95-479e-94ec-4469adc8da0b.webp?v=1714720657","width":2000},{"alt":null,"id":23877058625635,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9c5f549e347222a37b2aaf90d156d8582afa2822_04544c43-32d9-4f47-87c0-7de47d63d26f.webp?v=1714720659"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9c5f549e347222a37b2aaf90d156d8582afa2822_04544c43-32d9-4f47-87c0-7de47d63d26f.webp?v=1714720659","width":2000},{"alt":null,"id":23877058953315,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c8173e18fe354bf1f0d847170c98f32ee85178b0_122f6c0b-4175-496a-8a86-8d9679847441.webp?v=1714720661"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c8173e18fe354bf1f0d847170c98f32ee85178b0_122f6c0b-4175-496a-8a86-8d9679847441.webp?v=1714720661","width":2000},{"alt":null,"id":23877059543139,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d6e585bd5045fe4bbce04a114a7431b77f50881_c52a8785-6063-4245-95b6-7d6825a620ac.webp?v=1714720664"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d6e585bd5045fe4bbce04a114a7431b77f50881_c52a8785-6063-4245-95b6-7d6825a620ac.webp?v=1714720664","width":2000},{"alt":null,"id":23877059870819,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b158a2ef782a3628738635a2b3ccdee05480a09_6fd1216b-7ce7-4219-a740-12b0ca394b24.webp?v=1714720666"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b158a2ef782a3628738635a2b3ccdee05480a09_6fd1216b-7ce7-4219-a740-12b0ca394b24.webp?v=1714720666","width":2000},{"alt":null,"id":23877060427875,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7caabf33dd78fb8502092d7dcdb408b9939eb1d0_11df49eb-c64c-43f8-bed1-c6322e7bef2f.webp?v=1714720668"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7caabf33dd78fb8502092d7dcdb408b9939eb1d0_11df49eb-c64c-43f8-bed1-c6322e7bef2f.webp?v=1714720668","width":2000},{"alt":null,"id":23877060722787,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b55a4d552649dc943156fe8684895763f432fc3f_dbce5f59-87cd-4c5c-b419-6093b2f844d5.webp?v=1714720670"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b55a4d552649dc943156fe8684895763f432fc3f_dbce5f59-87cd-4c5c-b419-6093b2f844d5.webp?v=1714720670","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41884966486115,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-SB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31472141860963,"product_id":7408392011875,"position":3,"created_at":"2024-05-03T15:17:34+08:00","updated_at":"2024-05-03T15:17:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654","variant_ids":[41884966486115]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Batman - 黑白畫風-蝙蝠俠 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-SB12","featured_media":{"alt":null,"id":23877057445987,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41884966486115,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-SB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31472141860963,"product_id":7408392011875,"position":3,"created_at":"2024-05-03T15:17:34+08:00","updated_at":"2024-05-03T15:17:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654","variant_ids":[41884966486115]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Batman - 黑白畫風-蝙蝠俠 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-SB12","featured_media":{"alt":null,"id":23877057445987,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/17a89cacc9c33a3202527d273d7861c62b8c1388_a41e2757-9c90-4c0b-8894-38bc8e57e505.webp?v=1714720654"}},"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: "停產" }