$product = {"id":7408426680419,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 伊沃克人1-塗鴉藝術","handle":"iphone-12-pro-max-mod-nx-printable-pb37","description":null,"published_at":"2024-06-11T16:36:55+08:00","created_at":"2024-05-03T15:24:33+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-star-wars","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":41885355278435,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB37","requires_shipping":true,"taxable":true,"featured_image":{"id":31472244949091,"product_id":7408426680419,"position":1,"created_at":"2024-05-03T15:24:35+08:00","updated_at":"2024-05-03T15:24:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","variant_ids":[41885355278435]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 伊沃克人1-塗鴉藝術 - 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-PB37","featured_media":{"alt":null,"id":23877161123939,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2c2a392e1b91dd3c7dcbb574e35e35594cf297_3b9c6f50-7e7a-4693-bdd9-b019caacfd2f.webp?v=1714721077","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bbbae72eb1367d62dd2e1a5585a92bd9088672be_0e93950a-c06f-4a88-bc28-a16242df8dcf.webp?v=1714721080","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/403dfe01236a18e043c832c971f518adea05d7c8_baec22e9-e149-4063-9682-3d15785e441c.webp?v=1714721082","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0a786f40fd7c0ca196dae1bf0bd29bb59f08ea25_1c76337f-47ad-4d50-a35c-95910c62a746.webp?v=1714721084","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/393e1c890f4385d4720ab76fb3e2d172e6288180_ed0720bf-3942-4481-bb1e-64a84ca9971a.webp?v=1714721087","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dc344e088a38a457645d992216c2a1da5af68cb_a18f2974-bdad-47a2-b5d7-60a3b49ec4c5.webp?v=1714721089","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc2f3654a01104a047b90efd3f6d26b93e017253_005e9fd1-a909-4189-be5f-e4bc86a12e04.webp?v=1714721091","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b28dff359c2e7c2566cbfa57719a155451068b6_1accfd0d-9970-45e0-8420-b14fcc80596f.webp?v=1714721093","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/544db67a1d54458c5c043ed58faabc0057256c78_3093560a-8510-411b-a861-99a9f0287b9d.webp?v=1714721095"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","options":["color"],"media":[{"alt":null,"id":23877161123939,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","width":2000},{"alt":null,"id":23877161451619,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2c2a392e1b91dd3c7dcbb574e35e35594cf297_3b9c6f50-7e7a-4693-bdd9-b019caacfd2f.webp?v=1714721077"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2c2a392e1b91dd3c7dcbb574e35e35594cf297_3b9c6f50-7e7a-4693-bdd9-b019caacfd2f.webp?v=1714721077","width":2000},{"alt":null,"id":23877161943139,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bbbae72eb1367d62dd2e1a5585a92bd9088672be_0e93950a-c06f-4a88-bc28-a16242df8dcf.webp?v=1714721080"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bbbae72eb1367d62dd2e1a5585a92bd9088672be_0e93950a-c06f-4a88-bc28-a16242df8dcf.webp?v=1714721080","width":2000},{"alt":null,"id":23877162303587,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/403dfe01236a18e043c832c971f518adea05d7c8_baec22e9-e149-4063-9682-3d15785e441c.webp?v=1714721082"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/403dfe01236a18e043c832c971f518adea05d7c8_baec22e9-e149-4063-9682-3d15785e441c.webp?v=1714721082","width":2000},{"alt":null,"id":23877162991715,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0a786f40fd7c0ca196dae1bf0bd29bb59f08ea25_1c76337f-47ad-4d50-a35c-95910c62a746.webp?v=1714721084"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0a786f40fd7c0ca196dae1bf0bd29bb59f08ea25_1c76337f-47ad-4d50-a35c-95910c62a746.webp?v=1714721084","width":2000},{"alt":null,"id":23877163384931,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/393e1c890f4385d4720ab76fb3e2d172e6288180_ed0720bf-3942-4481-bb1e-64a84ca9971a.webp?v=1714721087"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/393e1c890f4385d4720ab76fb3e2d172e6288180_ed0720bf-3942-4481-bb1e-64a84ca9971a.webp?v=1714721087","width":2000},{"alt":null,"id":23877163876451,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dc344e088a38a457645d992216c2a1da5af68cb_a18f2974-bdad-47a2-b5d7-60a3b49ec4c5.webp?v=1714721089"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dc344e088a38a457645d992216c2a1da5af68cb_a18f2974-bdad-47a2-b5d7-60a3b49ec4c5.webp?v=1714721089","width":2000},{"alt":null,"id":23877164564579,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc2f3654a01104a047b90efd3f6d26b93e017253_005e9fd1-a909-4189-be5f-e4bc86a12e04.webp?v=1714721091"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc2f3654a01104a047b90efd3f6d26b93e017253_005e9fd1-a909-4189-be5f-e4bc86a12e04.webp?v=1714721091","width":2000},{"alt":null,"id":23877165023331,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b28dff359c2e7c2566cbfa57719a155451068b6_1accfd0d-9970-45e0-8420-b14fcc80596f.webp?v=1714721093"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b28dff359c2e7c2566cbfa57719a155451068b6_1accfd0d-9970-45e0-8420-b14fcc80596f.webp?v=1714721093","width":2000},{"alt":null,"id":23877165351011,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/544db67a1d54458c5c043ed58faabc0057256c78_3093560a-8510-411b-a861-99a9f0287b9d.webp?v=1714721095"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/544db67a1d54458c5c043ed58faabc0057256c78_3093560a-8510-411b-a861-99a9f0287b9d.webp?v=1714721095","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41885355278435,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB37","requires_shipping":true,"taxable":true,"featured_image":{"id":31472244949091,"product_id":7408426680419,"position":1,"created_at":"2024-05-03T15:24:35+08:00","updated_at":"2024-05-03T15:24:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","variant_ids":[41885355278435]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 伊沃克人1-塗鴉藝術 - 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-PB37","featured_media":{"alt":null,"id":23877161123939,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41885355278435,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB37","requires_shipping":true,"taxable":true,"featured_image":{"id":31472244949091,"product_id":7408426680419,"position":1,"created_at":"2024-05-03T15:24:35+08:00","updated_at":"2024-05-03T15:24:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075","variant_ids":[41885355278435]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 伊沃克人1-塗鴉藝術 - 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-PB37","featured_media":{"alt":null,"id":23877161123939,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cbddfed86d84ef126fbc251c70db6fc799086c90_d1ae3acd-381a-496b-86c1-f516f8d7664d.webp?v=1714721075"}},"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: "停產"
}