$product = {"id":7414020309091,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看","handle":"iphone-13-pro-max-mod-nx-magsafe-printable-iv04","description":null,"published_at":"2024-06-11T17:47:55+08:00","created_at":"2024-05-05T14:02:27+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區1G","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-1chun","device-iPhone 13 Pro Max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-1chun","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":41903411593315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0123224-IV04","requires_shipping":true,"taxable":true,"featured_image":{"id":31484479471715,"product_id":7414020309091,"position":9,"created_at":"2024-05-05T14:02:48+08:00","updated_at":"2024-05-05T14:02:48+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968","variant_ids":[41903411593315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看 - 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":"MPB0123224-IV04","featured_media":{"alt":null,"id":23889773625443,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41903411920995,"title":"Mod NX-海軍藍邊框","option1":"Mod NX-海軍藍邊框","option2":null,"option3":null,"sku":"MPB01232J5-IV04","requires_shipping":true,"taxable":true,"featured_image":{"id":31484478947427,"product_id":7414020309091,"position":8,"created_at":"2024-05-05T14:02:45+08:00","updated_at":"2024-05-05T14:02:45+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965","variant_ids":[41903411920995]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看 - 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":"MPB01232J5-IV04","featured_media":{"alt":null,"id":23889773068387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e134355a9cefb8142dd142349bb8f4ae3ad36c6e_2b9b8947-c737-4e41-bf93-b0c74b73fc04.webp?v=1714888949","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6120aa59987ea491a4e056f2956bdd9fc39ab352_df05d666-867c-4bff-86d1-54f8c3d5148c.webp?v=1714888952","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/089560fb56cd3b9da73031c1b1fade29b1b2ba37_985d8f7e-6584-450b-aa43-ee086208ec6a.webp?v=1714888954","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ff48a2c0731e3b77be4c0db46f016dd490537ae3_d4306500-d608-434d-825d-665e91280ed4.webp?v=1714888956","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6bb5c7ed638d3deb8fda08284ef8bcb8279729d4_ac9d5c9c-b023-41fc-8c79-7b780b254ee0.webp?v=1714888958","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0129862405e0844d9789869660c2c648e6c6e185_fefc6eaa-8378-4983-a384-5961def7cbb4.webp?v=1714888961","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b825a695dd32d2ad2d0eb33df8ad58541909a210_051b252d-9b39-43c7-a5b2-a3cc50224be6.webp?v=1714888963","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/37466b40b45f0b7eb0c528f176a13ccab4f53747_ddd0189b-21e3-4244-9dd9-6143688a2e27.webp?v=1714888970","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de88575c646ba126b4686bd4af37ba61db98b0e3_2433e8b4-4884-4127-9f09-72eb60e7d26f.webp?v=1714888972"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e134355a9cefb8142dd142349bb8f4ae3ad36c6e_2b9b8947-c737-4e41-bf93-b0c74b73fc04.webp?v=1714888949","options":["color"],"media":[{"alt":null,"id":23889769791587,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e134355a9cefb8142dd142349bb8f4ae3ad36c6e_2b9b8947-c737-4e41-bf93-b0c74b73fc04.webp?v=1714888949"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e134355a9cefb8142dd142349bb8f4ae3ad36c6e_2b9b8947-c737-4e41-bf93-b0c74b73fc04.webp?v=1714888949","width":2000},{"alt":null,"id":23889770381411,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6120aa59987ea491a4e056f2956bdd9fc39ab352_df05d666-867c-4bff-86d1-54f8c3d5148c.webp?v=1714888952"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6120aa59987ea491a4e056f2956bdd9fc39ab352_df05d666-867c-4bff-86d1-54f8c3d5148c.webp?v=1714888952","width":2000},{"alt":null,"id":23889770741859,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/089560fb56cd3b9da73031c1b1fade29b1b2ba37_985d8f7e-6584-450b-aa43-ee086208ec6a.webp?v=1714888954"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/089560fb56cd3b9da73031c1b1fade29b1b2ba37_985d8f7e-6584-450b-aa43-ee086208ec6a.webp?v=1714888954","width":2000},{"alt":null,"id":23889771200611,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ff48a2c0731e3b77be4c0db46f016dd490537ae3_d4306500-d608-434d-825d-665e91280ed4.webp?v=1714888956"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ff48a2c0731e3b77be4c0db46f016dd490537ae3_d4306500-d608-434d-825d-665e91280ed4.webp?v=1714888956","width":2000},{"alt":null,"id":23889771626595,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6bb5c7ed638d3deb8fda08284ef8bcb8279729d4_ac9d5c9c-b023-41fc-8c79-7b780b254ee0.webp?v=1714888958"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6bb5c7ed638d3deb8fda08284ef8bcb8279729d4_ac9d5c9c-b023-41fc-8c79-7b780b254ee0.webp?v=1714888958","width":2000},{"alt":null,"id":23889772216419,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0129862405e0844d9789869660c2c648e6c6e185_fefc6eaa-8378-4983-a384-5961def7cbb4.webp?v=1714888961"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0129862405e0844d9789869660c2c648e6c6e185_fefc6eaa-8378-4983-a384-5961def7cbb4.webp?v=1714888961","width":2000},{"alt":null,"id":23889772675171,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b825a695dd32d2ad2d0eb33df8ad58541909a210_051b252d-9b39-43c7-a5b2-a3cc50224be6.webp?v=1714888963"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b825a695dd32d2ad2d0eb33df8ad58541909a210_051b252d-9b39-43c7-a5b2-a3cc50224be6.webp?v=1714888963","width":2000},{"alt":null,"id":23889773068387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965","width":2000},{"alt":null,"id":23889773625443,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968","width":2000},{"alt":null,"id":23889774051427,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/37466b40b45f0b7eb0c528f176a13ccab4f53747_ddd0189b-21e3-4244-9dd9-6143688a2e27.webp?v=1714888970"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/37466b40b45f0b7eb0c528f176a13ccab4f53747_ddd0189b-21e3-4244-9dd9-6143688a2e27.webp?v=1714888970","width":2000},{"alt":null,"id":23889774542947,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de88575c646ba126b4686bd4af37ba61db98b0e3_2433e8b4-4884-4127-9f09-72eb60e7d26f.webp?v=1714888972"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/de88575c646ba126b4686bd4af37ba61db98b0e3_2433e8b4-4884-4127-9f09-72eb60e7d26f.webp?v=1714888972","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41903411593315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0123224-IV04","requires_shipping":true,"taxable":true,"featured_image":{"id":31484479471715,"product_id":7414020309091,"position":9,"created_at":"2024-05-05T14:02:48+08:00","updated_at":"2024-05-05T14:02:48+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968","variant_ids":[41903411593315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看 - 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":"MPB0123224-IV04","featured_media":{"alt":null,"id":23889773625443,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41903411920995,"title":"Mod NX-海軍藍邊框","option1":"Mod NX-海軍藍邊框","option2":null,"option3":null,"sku":"MPB01232J5-IV04","requires_shipping":true,"taxable":true,"featured_image":{"id":31484478947427,"product_id":7414020309091,"position":8,"created_at":"2024-05-05T14:02:45+08:00","updated_at":"2024-05-05T14:02:45+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965","variant_ids":[41903411920995]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看 - 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":"MPB01232J5-IV04","featured_media":{"alt":null,"id":23889773068387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/202a7b72b4cdc84863e06d973743f7f44de70208_6b9568c3-7d03-4a6b-bee1-624221afc211.webp?v=1714888965"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41903411593315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0123224-IV04","requires_shipping":true,"taxable":true,"featured_image":{"id":31484479471715,"product_id":7414020309091,"position":9,"created_at":"2024-05-05T14:02:48+08:00","updated_at":"2024-05-05T14:02:48+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968","variant_ids":[41903411593315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 13 Pro Max - 1G - 右看看 - 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":"MPB0123224-IV04","featured_media":{"alt":null,"id":23889773625443,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12d9d83aa255ed505037351cee818eb8cacbb5db_b7b63c58-c511-4c56-a6b9-9bb89954a69b.webp?v=1714888968"}},"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: "停產"
}