$product = {"id":7407549153379,"title":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8","handle":"iphone-15-plus-mod-nx-printable-pc04","description":null,"published_at":"2024-06-11T16:18:54+08:00","created_at":"2024-05-03T10:08:48+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 15 Plus","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":41876201111651,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0129624-PC04","requires_shipping":true,"taxable":true,"featured_image":{"id":31469870121059,"product_id":7407549153379,"position":3,"created_at":"2024-05-03T10:08:56+08:00","updated_at":"2024-05-03T10:08:56+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136","variant_ids":[41876201111651]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8 - 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":"NPB0129624-PC04","featured_media":{"alt":null,"id":23874771681379,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41876201242723,"title":"Mod NX-櫻花粉邊框","option1":"Mod NX-櫻花粉邊框","option2":null,"option3":null,"sku":"NPB0129657-PC04","requires_shipping":true,"taxable":true,"featured_image":{"id":31469874348131,"product_id":7407549153379,"position":9,"created_at":"2024-05-03T10:09:13+08:00","updated_at":"2024-05-03T10:09:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153","variant_ids":[41876201242723]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8 - 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":"NPB0129657-PC04","featured_media":{"alt":null,"id":23874775908451,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/671d95a3eb384470d1ac2fac7d35023e89124182_cc428661-02d0-4d00-8d42-ac95d43464b4.webp?v=1714702130","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0cf00fcc530a0f7cc92e3fe38ade179f60221c6_eb39aa17-00ed-4716-a803-24f57486a4f5.webp?v=1714702133","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/332c54869edd61f6ba1fcbf09efbe4489661183a_94956128-2867-443e-a239-07bc78ec9780.webp?v=1714702138","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a89492e7a577cef4eb0e09f0e1690ecf99053611_e96a532c-07db-4511-bf10-e5d67dd24fec.webp?v=1714702140","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d30eda6d7a59c352ddf8d7b6a18ad1502775f5d_7892df45-163c-448d-a400-0605ac66b5cf.webp?v=1714702145","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b2c459898e9d5d0501ed3c53246e6b991d53e98_de2a4f28-ad5e-40a0-825a-21b524a441a2.webp?v=1714702148","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1ab3f34ec19badc4bca129d9af0a313ed74ece4_d3e0862c-20fb-472c-bb26-cc97404291e7.webp?v=1714702150","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/671d95a3eb384470d1ac2fac7d35023e89124182_cc428661-02d0-4d00-8d42-ac95d43464b4.webp?v=1714702130","options":["color"],"media":[{"alt":null,"id":23874770141283,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/671d95a3eb384470d1ac2fac7d35023e89124182_cc428661-02d0-4d00-8d42-ac95d43464b4.webp?v=1714702130"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/671d95a3eb384470d1ac2fac7d35023e89124182_cc428661-02d0-4d00-8d42-ac95d43464b4.webp?v=1714702130","width":2000},{"alt":null,"id":23874771091555,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0cf00fcc530a0f7cc92e3fe38ade179f60221c6_eb39aa17-00ed-4716-a803-24f57486a4f5.webp?v=1714702133"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f0cf00fcc530a0f7cc92e3fe38ade179f60221c6_eb39aa17-00ed-4716-a803-24f57486a4f5.webp?v=1714702133","width":2000},{"alt":null,"id":23874771681379,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136","width":2000},{"alt":null,"id":23874772205667,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/332c54869edd61f6ba1fcbf09efbe4489661183a_94956128-2867-443e-a239-07bc78ec9780.webp?v=1714702138"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/332c54869edd61f6ba1fcbf09efbe4489661183a_94956128-2867-443e-a239-07bc78ec9780.webp?v=1714702138","width":2000},{"alt":null,"id":23874772697187,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a89492e7a577cef4eb0e09f0e1690ecf99053611_e96a532c-07db-4511-bf10-e5d67dd24fec.webp?v=1714702140"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a89492e7a577cef4eb0e09f0e1690ecf99053611_e96a532c-07db-4511-bf10-e5d67dd24fec.webp?v=1714702140","width":2000},{"alt":null,"id":23874774237283,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d30eda6d7a59c352ddf8d7b6a18ad1502775f5d_7892df45-163c-448d-a400-0605ac66b5cf.webp?v=1714702145"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7d30eda6d7a59c352ddf8d7b6a18ad1502775f5d_7892df45-163c-448d-a400-0605ac66b5cf.webp?v=1714702145","width":2000},{"alt":null,"id":23874774696035,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b2c459898e9d5d0501ed3c53246e6b991d53e98_de2a4f28-ad5e-40a0-825a-21b524a441a2.webp?v=1714702148"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7b2c459898e9d5d0501ed3c53246e6b991d53e98_de2a4f28-ad5e-40a0-825a-21b524a441a2.webp?v=1714702148","width":2000},{"alt":null,"id":23874775351395,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1ab3f34ec19badc4bca129d9af0a313ed74ece4_d3e0862c-20fb-472c-bb26-cc97404291e7.webp?v=1714702150"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b1ab3f34ec19badc4bca129d9af0a313ed74ece4_d3e0862c-20fb-472c-bb26-cc97404291e7.webp?v=1714702150","width":2000},{"alt":null,"id":23874775908451,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41876201111651,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0129624-PC04","requires_shipping":true,"taxable":true,"featured_image":{"id":31469870121059,"product_id":7407549153379,"position":3,"created_at":"2024-05-03T10:08:56+08:00","updated_at":"2024-05-03T10:08:56+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136","variant_ids":[41876201111651]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8 - 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":"NPB0129624-PC04","featured_media":{"alt":null,"id":23874771681379,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41876201242723,"title":"Mod NX-櫻花粉邊框","option1":"Mod NX-櫻花粉邊框","option2":null,"option3":null,"sku":"NPB0129657-PC04","requires_shipping":true,"taxable":true,"featured_image":{"id":31469874348131,"product_id":7407549153379,"position":9,"created_at":"2024-05-03T10:09:13+08:00","updated_at":"2024-05-03T10:09:13+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153","variant_ids":[41876201242723]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8 - 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":"NPB0129657-PC04","featured_media":{"alt":null,"id":23874775908451,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e6d22f49f74bc6350f4fe7fb7f072240fa1de937_7b2d6cab-e6ff-4a03-8dbf-72bb2beed118.webp?v=1714702153"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41876201111651,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0129624-PC04","requires_shipping":true,"taxable":true,"featured_image":{"id":31469870121059,"product_id":7407549153379,"position":3,"created_at":"2024-05-03T10:08:56+08:00","updated_at":"2024-05-03T10:08:56+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136","variant_ids":[41876201111651]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 15 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 小圖款-BB8 - 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":"NPB0129624-PC04","featured_media":{"alt":null,"id":23874771681379,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f9d8a0ad1c18a46d16a63c986675f1bea27c700_ccd58403-6786-4b74-b874-351efc24bc16.webp?v=1714702136"}},"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: "停產"
}