$product = {"id":7408512893027,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭貓貓","handle":"iphone-12-pro-max-mod-nx-printable-hq01","description":null,"published_at":"2024-06-11T16:39:20+08:00","created_at":"2024-05-03T15:41:14+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Pixel Jeff 皮傑","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-pixeljeff","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-pixeljeff","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":41886327963747,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-HQ01","requires_shipping":true,"taxable":true,"featured_image":{"id":31472470392931,"product_id":7408512893027,"position":8,"created_at":"2024-05-03T15:41:33+08:00","updated_at":"2024-05-03T15:41:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093","variant_ids":[41886327963747]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭貓貓 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-HQ01","featured_media":{"alt":null,"id":23877387616355,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8fd2a30a31227b792e0e3f5bc6217757c2ed671_c2ef8e81-7060-4d82-a740-8d2e233e0806.webp?v=1714722077","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de07649955fd2fd7485c4efa88ff3467bdf7774d_c05aac4b-38ab-40f6-a525-34a648dac911.webp?v=1714722079","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46816901a59d611acf90c98ee2e77b4692ce6601_0183abd8-27ac-4cb6-8390-2862a267c9ab.webp?v=1714722082","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/920c8179276363f639de0b3a3b48b8754cc4fae1_f61ab61b-3141-4328-a2bb-9858e8756c7a.webp?v=1714722084","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa891816dc06e7ada067e0db1b9d6be52cbc869_f76f6323-5f2d-4d40-9fd2-271e38f480a4.webp?v=1714722086","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/320b0c34228552cf635cf19fc1c36685fbb67c3b_4ade38c1-ab56-459a-9d6e-0bbd2869df5b.webp?v=1714722088","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/23b5fbc16c69998d00b2b40a2e71ab84f3cce54c_1347f4cd-40bb-4d14-9d3b-165257129955.webp?v=1714722091","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f2490b3257b9dc5283024b781b4af5e5af9318b_f942fa58-b7f3-4515-a0e2-016d4546c1e0.webp?v=1714722095","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be67d868946785545c3f2b3c22a93aed5fe8e3f9_a62b76ea-115e-4cfe-ba03-e7325bdd5745.webp?v=1714722098"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8fd2a30a31227b792e0e3f5bc6217757c2ed671_c2ef8e81-7060-4d82-a740-8d2e233e0806.webp?v=1714722077","options":["color"],"media":[{"alt":null,"id":23877383815267,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8fd2a30a31227b792e0e3f5bc6217757c2ed671_c2ef8e81-7060-4d82-a740-8d2e233e0806.webp?v=1714722077"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8fd2a30a31227b792e0e3f5bc6217757c2ed671_c2ef8e81-7060-4d82-a740-8d2e233e0806.webp?v=1714722077","width":2000},{"alt":null,"id":23877384274019,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de07649955fd2fd7485c4efa88ff3467bdf7774d_c05aac4b-38ab-40f6-a525-34a648dac911.webp?v=1714722079"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de07649955fd2fd7485c4efa88ff3467bdf7774d_c05aac4b-38ab-40f6-a525-34a648dac911.webp?v=1714722079","width":2000},{"alt":null,"id":23877384831075,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46816901a59d611acf90c98ee2e77b4692ce6601_0183abd8-27ac-4cb6-8390-2862a267c9ab.webp?v=1714722082"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46816901a59d611acf90c98ee2e77b4692ce6601_0183abd8-27ac-4cb6-8390-2862a267c9ab.webp?v=1714722082","width":2000},{"alt":null,"id":23877385322595,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/920c8179276363f639de0b3a3b48b8754cc4fae1_f61ab61b-3141-4328-a2bb-9858e8756c7a.webp?v=1714722084"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/920c8179276363f639de0b3a3b48b8754cc4fae1_f61ab61b-3141-4328-a2bb-9858e8756c7a.webp?v=1714722084","width":2000},{"alt":null,"id":23877385977955,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa891816dc06e7ada067e0db1b9d6be52cbc869_f76f6323-5f2d-4d40-9fd2-271e38f480a4.webp?v=1714722086"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa891816dc06e7ada067e0db1b9d6be52cbc869_f76f6323-5f2d-4d40-9fd2-271e38f480a4.webp?v=1714722086","width":2000},{"alt":null,"id":23877386535011,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/320b0c34228552cf635cf19fc1c36685fbb67c3b_4ade38c1-ab56-459a-9d6e-0bbd2869df5b.webp?v=1714722088"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/320b0c34228552cf635cf19fc1c36685fbb67c3b_4ade38c1-ab56-459a-9d6e-0bbd2869df5b.webp?v=1714722088","width":2000},{"alt":null,"id":23877387124835,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/23b5fbc16c69998d00b2b40a2e71ab84f3cce54c_1347f4cd-40bb-4d14-9d3b-165257129955.webp?v=1714722091"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/23b5fbc16c69998d00b2b40a2e71ab84f3cce54c_1347f4cd-40bb-4d14-9d3b-165257129955.webp?v=1714722091","width":2000},{"alt":null,"id":23877387616355,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093","width":2000},{"alt":null,"id":23877388107875,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f2490b3257b9dc5283024b781b4af5e5af9318b_f942fa58-b7f3-4515-a0e2-016d4546c1e0.webp?v=1714722095"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f2490b3257b9dc5283024b781b4af5e5af9318b_f942fa58-b7f3-4515-a0e2-016d4546c1e0.webp?v=1714722095","width":2000},{"alt":null,"id":23877388697699,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be67d868946785545c3f2b3c22a93aed5fe8e3f9_a62b76ea-115e-4cfe-ba03-e7325bdd5745.webp?v=1714722098"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be67d868946785545c3f2b3c22a93aed5fe8e3f9_a62b76ea-115e-4cfe-ba03-e7325bdd5745.webp?v=1714722098","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41886327963747,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-HQ01","requires_shipping":true,"taxable":true,"featured_image":{"id":31472470392931,"product_id":7408512893027,"position":8,"created_at":"2024-05-03T15:41:33+08:00","updated_at":"2024-05-03T15:41:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093","variant_ids":[41886327963747]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭貓貓 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-HQ01","featured_media":{"alt":null,"id":23877387616355,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41886327963747,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-HQ01","requires_shipping":true,"taxable":true,"featured_image":{"id":31472470392931,"product_id":7408512893027,"position":8,"created_at":"2024-05-03T15:41:33+08:00","updated_at":"2024-05-03T15:41:33+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093","variant_ids":[41886327963747]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭貓貓 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118724-HQ01","featured_media":{"alt":null,"id":23877387616355,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3a15a6cdcde97447fc321201be83bd03e4c7f81_cb78560d-d48f-4690-a7c6-f217ce79f269.webp?v=1714722093"}},"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: "停產"
}