$product = {"id":7411238273123,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - 千年鷹-美式復古","handle":"iphone-14-plus-mod-nx-magsafe-printable-pb99","description":null,"published_at":"2024-06-11T17:39:35+08:00","created_at":"2024-05-04T23:51:23+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-star-wars","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":41896380432483,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB99","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929471075,"product_id":7411238273123,"position":5,"created_at":"2024-05-04T23:51:34+08:00","updated_at":"2024-05-04T23:51:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894","variant_ids":[41896380432483]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - 千年鷹-美式復古 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PB99","featured_media":{"alt":null,"id":23885179912291,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14d1a46f5ca583d85f9c328075677e15f5cb03d4_9001ccab-b250-45cd-b5c3-5d23659815c3.webp?v=1714837885","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8488d8f1790955a5aa2cf5ccfd95d77b42b04792_85567da7-6e41-4f9b-a57b-384c8c5b6f2f.webp?v=1714837887","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8695e44fee9c6f6cc9f8e8081338de1208e182e3_8edcc963-1ffa-4933-b679-110aa17b9465.webp?v=1714837889","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4542434c3ad78ec9c4926f2491c5cc734964b0c4_fbc8f393-dab3-47fd-984b-c40f8898451e.webp?v=1714837892","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9ec045f83bf459474e9e21566f6d7f7b5597bcf4_cf8a80d0-19d7-408d-9a99-60dee01d3c03.webp?v=1714837896","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b87f6500192840fa88e29b7db3f2e473633191a_e65dba4a-69d1-4be1-a714-cb3863503ae9.webp?v=1714837899","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a9d0132067fdab0cc361659cdb8fb8bf3a3f783_619ad0b7-ca72-4d20-b194-e433a413623c.webp?v=1714837901","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f897e4d9766a3b23c77b03206900fed22d87074_8fbf2619-cfbe-4c0f-a433-6d7d54c731dd.webp?v=1714837903","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6aab6e252833b1ec66404168b70e2da4edacd9a8_44ee7813-3530-4854-9e3e-bc027c22daef.webp?v=1714837906"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14d1a46f5ca583d85f9c328075677e15f5cb03d4_9001ccab-b250-45cd-b5c3-5d23659815c3.webp?v=1714837885","options":["color"],"media":[{"alt":null,"id":23885177847907,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14d1a46f5ca583d85f9c328075677e15f5cb03d4_9001ccab-b250-45cd-b5c3-5d23659815c3.webp?v=1714837885"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/14d1a46f5ca583d85f9c328075677e15f5cb03d4_9001ccab-b250-45cd-b5c3-5d23659815c3.webp?v=1714837885","width":2000},{"alt":null,"id":23885178503267,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8488d8f1790955a5aa2cf5ccfd95d77b42b04792_85567da7-6e41-4f9b-a57b-384c8c5b6f2f.webp?v=1714837887"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8488d8f1790955a5aa2cf5ccfd95d77b42b04792_85567da7-6e41-4f9b-a57b-384c8c5b6f2f.webp?v=1714837887","width":2000},{"alt":null,"id":23885178929251,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8695e44fee9c6f6cc9f8e8081338de1208e182e3_8edcc963-1ffa-4933-b679-110aa17b9465.webp?v=1714837889"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8695e44fee9c6f6cc9f8e8081338de1208e182e3_8edcc963-1ffa-4933-b679-110aa17b9465.webp?v=1714837889","width":2000},{"alt":null,"id":23885179420771,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4542434c3ad78ec9c4926f2491c5cc734964b0c4_fbc8f393-dab3-47fd-984b-c40f8898451e.webp?v=1714837892"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4542434c3ad78ec9c4926f2491c5cc734964b0c4_fbc8f393-dab3-47fd-984b-c40f8898451e.webp?v=1714837892","width":2000},{"alt":null,"id":23885179912291,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894","width":2000},{"alt":null,"id":23885180403811,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9ec045f83bf459474e9e21566f6d7f7b5597bcf4_cf8a80d0-19d7-408d-9a99-60dee01d3c03.webp?v=1714837896"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9ec045f83bf459474e9e21566f6d7f7b5597bcf4_cf8a80d0-19d7-408d-9a99-60dee01d3c03.webp?v=1714837896","width":2000},{"alt":null,"id":23885180797027,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b87f6500192840fa88e29b7db3f2e473633191a_e65dba4a-69d1-4be1-a714-cb3863503ae9.webp?v=1714837899"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6b87f6500192840fa88e29b7db3f2e473633191a_e65dba4a-69d1-4be1-a714-cb3863503ae9.webp?v=1714837899","width":2000},{"alt":null,"id":23885181255779,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a9d0132067fdab0cc361659cdb8fb8bf3a3f783_619ad0b7-ca72-4d20-b194-e433a413623c.webp?v=1714837901"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a9d0132067fdab0cc361659cdb8fb8bf3a3f783_619ad0b7-ca72-4d20-b194-e433a413623c.webp?v=1714837901","width":2000},{"alt":null,"id":23885181747299,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f897e4d9766a3b23c77b03206900fed22d87074_8fbf2619-cfbe-4c0f-a433-6d7d54c731dd.webp?v=1714837903"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7f897e4d9766a3b23c77b03206900fed22d87074_8fbf2619-cfbe-4c0f-a433-6d7d54c731dd.webp?v=1714837903","width":2000},{"alt":null,"id":23885182271587,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6aab6e252833b1ec66404168b70e2da4edacd9a8_44ee7813-3530-4854-9e3e-bc027c22daef.webp?v=1714837906"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6aab6e252833b1ec66404168b70e2da4edacd9a8_44ee7813-3530-4854-9e3e-bc027c22daef.webp?v=1714837906","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41896380432483,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB99","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929471075,"product_id":7411238273123,"position":5,"created_at":"2024-05-04T23:51:34+08:00","updated_at":"2024-05-04T23:51:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894","variant_ids":[41896380432483]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - 千年鷹-美式復古 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PB99","featured_media":{"alt":null,"id":23885179912291,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41896380432483,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB99","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929471075,"product_id":7411238273123,"position":5,"created_at":"2024-05-04T23:51:34+08:00","updated_at":"2024-05-04T23:51:34+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894","variant_ids":[41896380432483]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - 千年鷹-美式復古 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PB99","featured_media":{"alt":null,"id":23885179912291,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/08cfea7d15a23c642c3073a1424961511ff0bc5d_b5d2440f-10d8-44f1-9621-71c968aada25.webp?v=1714837894"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}};
$device_handle = null;
$type = "";
var sellingStatus
if ($isMerge) {
$(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: "停產"
}