$product = {"id":7408215425123,"title":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款","handle":"iphone-13-pro-max-mod-nx-printable-pb45","description":null,"published_at":"2024-06-11T16:34:28+08:00","created_at":"2024-05-03T12:22:31+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 13 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":41883943829603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0123224-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31471495250019,"product_id":7408215425123,"position":4,"created_at":"2024-05-03T12:22:40+08:00","updated_at":"2024-05-03T12:22:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160","variant_ids":[41883943829603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - 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":"NPB0123224-PB45","featured_media":{"alt":null,"id":23876401660003,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41883944124515,"title":"Mod NX-海軍藍邊框","option1":"Mod NX-海軍藍邊框","option2":null,"option3":null,"sku":"NPB01232J5-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31471497281635,"product_id":7408215425123,"position":8,"created_at":"2024-05-03T12:22:49+08:00","updated_at":"2024-05-03T12:22:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169","variant_ids":[41883944124515]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - 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":"NPB01232J5-PB45","featured_media":{"alt":null,"id":23876403724387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac21965a5e91c0a51bd76ad9ce68aaaa867fa3c6_dee697af-89ed-4113-b12f-322ff43cc996.webp?v=1714710153","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e90791b45664d882e0c68c3764566ae0f0a65787_8c38feee-b526-4fdd-952a-e7a6d5fc94c9.webp?v=1714710155","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/415a565bcff88fc40cb70e753a09053bfd3655a1_fff9e924-0cd3-4719-ad94-9ae55a183313.webp?v=1714710158","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8520b28fa7232a65cc71146183c899f3e357d0bc_e64f4c90-1999-4ef5-a8e0-7165cae06c73.webp?v=1714710162","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b4f8e8c31db4f942909d13ad630513fe333c64f0_90662fc2-3646-4cbb-a3d4-00521b70442e.webp?v=1714710165","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f32ba1f5b82bf3d48114097c0dbd959def6efcb5_c9421efc-f8e3-4687-8fbf-7080ffed1e46.webp?v=1714710167","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6eb144475cdd98fbe49dc6c9463460995626a0f6_69754209-0284-48c1-a224-03a550cdbca1.webp?v=1714710172","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/908af8f13592a78dd72f87e89111c94c19293c5f_a31eaa83-c80f-47be-926a-d3567e9c2b8e.webp?v=1714710174"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac21965a5e91c0a51bd76ad9ce68aaaa867fa3c6_dee697af-89ed-4113-b12f-322ff43cc996.webp?v=1714710153","options":["color"],"media":[{"alt":null,"id":23876399824995,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac21965a5e91c0a51bd76ad9ce68aaaa867fa3c6_dee697af-89ed-4113-b12f-322ff43cc996.webp?v=1714710153"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac21965a5e91c0a51bd76ad9ce68aaaa867fa3c6_dee697af-89ed-4113-b12f-322ff43cc996.webp?v=1714710153","width":2000},{"alt":null,"id":23876400578659,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e90791b45664d882e0c68c3764566ae0f0a65787_8c38feee-b526-4fdd-952a-e7a6d5fc94c9.webp?v=1714710155"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e90791b45664d882e0c68c3764566ae0f0a65787_8c38feee-b526-4fdd-952a-e7a6d5fc94c9.webp?v=1714710155","width":2000},{"alt":null,"id":23876401168483,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/415a565bcff88fc40cb70e753a09053bfd3655a1_fff9e924-0cd3-4719-ad94-9ae55a183313.webp?v=1714710158"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/415a565bcff88fc40cb70e753a09053bfd3655a1_fff9e924-0cd3-4719-ad94-9ae55a183313.webp?v=1714710158","width":2000},{"alt":null,"id":23876401660003,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160","width":2000},{"alt":null,"id":23876402217059,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8520b28fa7232a65cc71146183c899f3e357d0bc_e64f4c90-1999-4ef5-a8e0-7165cae06c73.webp?v=1714710162"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8520b28fa7232a65cc71146183c899f3e357d0bc_e64f4c90-1999-4ef5-a8e0-7165cae06c73.webp?v=1714710162","width":2000},{"alt":null,"id":23876402643043,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b4f8e8c31db4f942909d13ad630513fe333c64f0_90662fc2-3646-4cbb-a3d4-00521b70442e.webp?v=1714710165"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b4f8e8c31db4f942909d13ad630513fe333c64f0_90662fc2-3646-4cbb-a3d4-00521b70442e.webp?v=1714710165","width":2000},{"alt":null,"id":23876403069027,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f32ba1f5b82bf3d48114097c0dbd959def6efcb5_c9421efc-f8e3-4687-8fbf-7080ffed1e46.webp?v=1714710167"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f32ba1f5b82bf3d48114097c0dbd959def6efcb5_c9421efc-f8e3-4687-8fbf-7080ffed1e46.webp?v=1714710167","width":2000},{"alt":null,"id":23876403724387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169","width":2000},{"alt":null,"id":23876404609123,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6eb144475cdd98fbe49dc6c9463460995626a0f6_69754209-0284-48c1-a224-03a550cdbca1.webp?v=1714710172"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6eb144475cdd98fbe49dc6c9463460995626a0f6_69754209-0284-48c1-a224-03a550cdbca1.webp?v=1714710172","width":2000},{"alt":null,"id":23876405067875,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/908af8f13592a78dd72f87e89111c94c19293c5f_a31eaa83-c80f-47be-926a-d3567e9c2b8e.webp?v=1714710174"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/908af8f13592a78dd72f87e89111c94c19293c5f_a31eaa83-c80f-47be-926a-d3567e9c2b8e.webp?v=1714710174","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41883943829603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0123224-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31471495250019,"product_id":7408215425123,"position":4,"created_at":"2024-05-03T12:22:40+08:00","updated_at":"2024-05-03T12:22:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160","variant_ids":[41883943829603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - 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":"NPB0123224-PB45","featured_media":{"alt":null,"id":23876401660003,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41883944124515,"title":"Mod NX-海軍藍邊框","option1":"Mod NX-海軍藍邊框","option2":null,"option3":null,"sku":"NPB01232J5-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31471497281635,"product_id":7408215425123,"position":8,"created_at":"2024-05-03T12:22:49+08:00","updated_at":"2024-05-03T12:22:49+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169","variant_ids":[41883944124515]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - 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":"NPB01232J5-PB45","featured_media":{"alt":null,"id":23876403724387,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/583245bbd3f328f7c2675b6ed86ec7b3ea0565e8_0a2269f7-6e24-497f-9c2d-2e6efd1da28b.webp?v=1714710169"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41883943829603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0123224-PB45","requires_shipping":true,"taxable":true,"featured_image":{"id":31471495250019,"product_id":7408215425123,"position":4,"created_at":"2024-05-03T12:22:40+08:00","updated_at":"2024-05-03T12:22:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160","variant_ids":[41883943829603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 13 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 星戰Logo黑武士款 - 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":"NPB0123224-PB45","featured_media":{"alt":null,"id":23876401660003,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d24bc0f5059c6e2f878d79a5c1a1025037ba6895_677a84e5-da1d-4df1-83d9-ea6e4025ba36.webp?v=1714710160"}},"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: "停產"
}