$product = {"id":7415018586211,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Look - 大自然的傑作(亞馬遜雨林)","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-af09","description":null,"published_at":"2024-06-11T17:55:47+08:00","created_at":"2024-05-05T20:07:25+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Look","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-look","device-iPhone 12 pro max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-look","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":41910994272355,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31487941705827,"product_id":7415018586211,"position":8,"created_at":"2024-05-05T20:07:45+08:00","updated_at":"2024-05-05T20:07:45+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865","variant_ids":[41910994272355]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Look - 大自然的傑作(亞馬遜雨林) - 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-AF09","featured_media":{"alt":null,"id":23893285896291,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/578cfb5d291f04b4f2e88dc726d92c4596577f3d_7122e3f3-dd0c-4fce-aebf-b763c2d8a84f.webp?v=1714910848","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/86e003fe68ca197c8d20555db2868c462ee23427_7b40f2e1-397f-4607-b807-f6b29b1df688.webp?v=1714910851","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c751eb313f2ec4ada5454c99489f4dd5a9184ab7_c4c79ab5-80c1-4fde-a968-b8be5cb14b6f.webp?v=1714910853","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8b42bd44369a89d480d8829e1206b2e46a17304_d9933b05-7c5a-46c4-9722-d1543cf1c6fc.webp?v=1714910856","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ab8c6be137730a25f001894de3e4a3bf9650408e_28b37924-5012-4673-995e-05a85d380148.webp?v=1714910858","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aec3a86fc525e179ccc48d0927502264cf28cd_e9fa73ed-6bc0-4e3e-b81e-49518e5c9b67.webp?v=1714910861","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/850ed969a1325a155743220648e9464629018e37_8cdde4b1-4eaa-4fef-a199-71503cf6df7c.webp?v=1714910863","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/360ae66e5d52788d3924c9ba748fa6b1ffcc85df_7b8f7626-f878-45df-aa9b-cc5210e25cd3.webp?v=1714910868","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1377743fd9498c71c07ef60ef1492b0af66fd72b_2179f660-bd3c-4dec-9de5-23986fd12235.webp?v=1714910870"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/578cfb5d291f04b4f2e88dc726d92c4596577f3d_7122e3f3-dd0c-4fce-aebf-b763c2d8a84f.webp?v=1714910848","options":["color"],"media":[{"alt":null,"id":23893280948323,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/578cfb5d291f04b4f2e88dc726d92c4596577f3d_7122e3f3-dd0c-4fce-aebf-b763c2d8a84f.webp?v=1714910848"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/578cfb5d291f04b4f2e88dc726d92c4596577f3d_7122e3f3-dd0c-4fce-aebf-b763c2d8a84f.webp?v=1714910848","width":2000},{"alt":null,"id":23893281669219,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/86e003fe68ca197c8d20555db2868c462ee23427_7b40f2e1-397f-4607-b807-f6b29b1df688.webp?v=1714910851"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/86e003fe68ca197c8d20555db2868c462ee23427_7b40f2e1-397f-4607-b807-f6b29b1df688.webp?v=1714910851","width":2000},{"alt":null,"id":23893282193507,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c751eb313f2ec4ada5454c99489f4dd5a9184ab7_c4c79ab5-80c1-4fde-a968-b8be5cb14b6f.webp?v=1714910853"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c751eb313f2ec4ada5454c99489f4dd5a9184ab7_c4c79ab5-80c1-4fde-a968-b8be5cb14b6f.webp?v=1714910853","width":2000},{"alt":null,"id":23893283209315,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8b42bd44369a89d480d8829e1206b2e46a17304_d9933b05-7c5a-46c4-9722-d1543cf1c6fc.webp?v=1714910856"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8b42bd44369a89d480d8829e1206b2e46a17304_d9933b05-7c5a-46c4-9722-d1543cf1c6fc.webp?v=1714910856","width":2000},{"alt":null,"id":23893284028515,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ab8c6be137730a25f001894de3e4a3bf9650408e_28b37924-5012-4673-995e-05a85d380148.webp?v=1714910858"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ab8c6be137730a25f001894de3e4a3bf9650408e_28b37924-5012-4673-995e-05a85d380148.webp?v=1714910858","width":2000},{"alt":null,"id":23893284585571,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aec3a86fc525e179ccc48d0927502264cf28cd_e9fa73ed-6bc0-4e3e-b81e-49518e5c9b67.webp?v=1714910861"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/82aec3a86fc525e179ccc48d0927502264cf28cd_e9fa73ed-6bc0-4e3e-b81e-49518e5c9b67.webp?v=1714910861","width":2000},{"alt":null,"id":23893285240931,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/850ed969a1325a155743220648e9464629018e37_8cdde4b1-4eaa-4fef-a199-71503cf6df7c.webp?v=1714910863"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/850ed969a1325a155743220648e9464629018e37_8cdde4b1-4eaa-4fef-a199-71503cf6df7c.webp?v=1714910863","width":2000},{"alt":null,"id":23893285896291,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865","width":2000},{"alt":null,"id":23893286420579,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/360ae66e5d52788d3924c9ba748fa6b1ffcc85df_7b8f7626-f878-45df-aa9b-cc5210e25cd3.webp?v=1714910868"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/360ae66e5d52788d3924c9ba748fa6b1ffcc85df_7b8f7626-f878-45df-aa9b-cc5210e25cd3.webp?v=1714910868","width":2000},{"alt":null,"id":23893287305315,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1377743fd9498c71c07ef60ef1492b0af66fd72b_2179f660-bd3c-4dec-9de5-23986fd12235.webp?v=1714910870"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1377743fd9498c71c07ef60ef1492b0af66fd72b_2179f660-bd3c-4dec-9de5-23986fd12235.webp?v=1714910870","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41910994272355,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31487941705827,"product_id":7415018586211,"position":8,"created_at":"2024-05-05T20:07:45+08:00","updated_at":"2024-05-05T20:07:45+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865","variant_ids":[41910994272355]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Look - 大自然的傑作(亞馬遜雨林) - 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-AF09","featured_media":{"alt":null,"id":23893285896291,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41910994272355,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-AF09","requires_shipping":true,"taxable":true,"featured_image":{"id":31487941705827,"product_id":7415018586211,"position":8,"created_at":"2024-05-05T20:07:45+08:00","updated_at":"2024-05-05T20:07:45+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865","variant_ids":[41910994272355]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - Look - 大自然的傑作(亞馬遜雨林) - 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-AF09","featured_media":{"alt":null,"id":23893285896291,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f90f6ec3c6a4beb702a362c05ad1aa25b7e7dc45_4c25eda4-cd12-49b5-9b1f-59c467fbf270.webp?v=1714910865"}},"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: "停產"
}