$product = {"id":7411237814371,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - 黑武士-溜溜球炫技-幽默系列","handle":"iphone-14-plus-mod-nx-magsafe-printable-pc11","description":null,"published_at":"2024-06-11T17:39:35+08:00","created_at":"2024-05-04T23:51:15+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":41896369586275,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PC11","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929897059,"product_id":7411237814371,"position":9,"created_at":"2024-05-04T23:51:36+08:00","updated_at":"2024-05-04T23:51:36+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896","variant_ids":[41896369586275]},"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-PC11","featured_media":{"alt":null,"id":23885180239971,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/00e1f200b99f02cfd851919b54fae760043d5af2_adeabf4c-e2cd-459c-becd-975e3d3d135a.webp?v=1714837878","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16bf6bdfb9d678d063ec1294956737b6a0aa6029_7241edd4-e45b-4672-95c0-0c96ea348c7a.webp?v=1714837880","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/692e1e50b1900cac80c421bb4c8c5236f93b2f0e_5bfe4615-ce9c-451d-80da-756289394c34.webp?v=1714837882","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e3b9f0966c566306f6b39da13be8d65bfa5057c2_9fd9de66-dd0d-436f-a6a1-8dedaf7eb8dc.webp?v=1714837885","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80ab4072f94511c69a8c07aa0206e5e528420c2c_21155553-f510-4fbd-9500-3e7daee3c7fa.webp?v=1714837887","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f283ea5f6b2fb0e6438cb21bd39f95bfa63cb78_3b54959f-0fe4-45d9-b951-95f2ddb8c6ad.webp?v=1714837889","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0c590c3ec824d97ce3eb731120e47a5ed8ad7024_8d74d0e5-9f1c-4ed8-bd4e-04fdc5a3a69e.webp?v=1714837891","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe098cfcec4db5dcdc1ff8322cb67521eeedd022_cf8aa450-824b-442f-bd01-88bf7f9d01f5.webp?v=1714837893","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/188a309d655d1e0e396222e5e3bbaccf0ea91a88_a9d8ff69-8c00-4dea-843f-1002066ee7c7.webp?v=1714837898"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/00e1f200b99f02cfd851919b54fae760043d5af2_adeabf4c-e2cd-459c-becd-975e3d3d135a.webp?v=1714837878","options":["color"],"media":[{"alt":null,"id":23885176111203,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/00e1f200b99f02cfd851919b54fae760043d5af2_adeabf4c-e2cd-459c-becd-975e3d3d135a.webp?v=1714837878"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/00e1f200b99f02cfd851919b54fae760043d5af2_adeabf4c-e2cd-459c-becd-975e3d3d135a.webp?v=1714837878","width":2000},{"alt":null,"id":23885176569955,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16bf6bdfb9d678d063ec1294956737b6a0aa6029_7241edd4-e45b-4672-95c0-0c96ea348c7a.webp?v=1714837880"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/16bf6bdfb9d678d063ec1294956737b6a0aa6029_7241edd4-e45b-4672-95c0-0c96ea348c7a.webp?v=1714837880","width":2000},{"alt":null,"id":23885177192547,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/692e1e50b1900cac80c421bb4c8c5236f93b2f0e_5bfe4615-ce9c-451d-80da-756289394c34.webp?v=1714837882"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/692e1e50b1900cac80c421bb4c8c5236f93b2f0e_5bfe4615-ce9c-451d-80da-756289394c34.webp?v=1714837882","width":2000},{"alt":null,"id":23885177782371,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e3b9f0966c566306f6b39da13be8d65bfa5057c2_9fd9de66-dd0d-436f-a6a1-8dedaf7eb8dc.webp?v=1714837885"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e3b9f0966c566306f6b39da13be8d65bfa5057c2_9fd9de66-dd0d-436f-a6a1-8dedaf7eb8dc.webp?v=1714837885","width":2000},{"alt":null,"id":23885178339427,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80ab4072f94511c69a8c07aa0206e5e528420c2c_21155553-f510-4fbd-9500-3e7daee3c7fa.webp?v=1714837887"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/80ab4072f94511c69a8c07aa0206e5e528420c2c_21155553-f510-4fbd-9500-3e7daee3c7fa.webp?v=1714837887","width":2000},{"alt":null,"id":23885178863715,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f283ea5f6b2fb0e6438cb21bd39f95bfa63cb78_3b54959f-0fe4-45d9-b951-95f2ddb8c6ad.webp?v=1714837889"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f283ea5f6b2fb0e6438cb21bd39f95bfa63cb78_3b54959f-0fe4-45d9-b951-95f2ddb8c6ad.webp?v=1714837889","width":2000},{"alt":null,"id":23885179256931,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0c590c3ec824d97ce3eb731120e47a5ed8ad7024_8d74d0e5-9f1c-4ed8-bd4e-04fdc5a3a69e.webp?v=1714837891"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0c590c3ec824d97ce3eb731120e47a5ed8ad7024_8d74d0e5-9f1c-4ed8-bd4e-04fdc5a3a69e.webp?v=1714837891","width":2000},{"alt":null,"id":23885179781219,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe098cfcec4db5dcdc1ff8322cb67521eeedd022_cf8aa450-824b-442f-bd01-88bf7f9d01f5.webp?v=1714837893"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe098cfcec4db5dcdc1ff8322cb67521eeedd022_cf8aa450-824b-442f-bd01-88bf7f9d01f5.webp?v=1714837893","width":2000},{"alt":null,"id":23885180239971,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896","width":2000},{"alt":null,"id":23885180698723,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/188a309d655d1e0e396222e5e3bbaccf0ea91a88_a9d8ff69-8c00-4dea-843f-1002066ee7c7.webp?v=1714837898"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/188a309d655d1e0e396222e5e3bbaccf0ea91a88_a9d8ff69-8c00-4dea-843f-1002066ee7c7.webp?v=1714837898","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41896369586275,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PC11","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929897059,"product_id":7411237814371,"position":9,"created_at":"2024-05-04T23:51:36+08:00","updated_at":"2024-05-04T23:51:36+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896","variant_ids":[41896369586275]},"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-PC11","featured_media":{"alt":null,"id":23885180239971,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41896369586275,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PC11","requires_shipping":true,"taxable":true,"featured_image":{"id":31479929897059,"product_id":7411237814371,"position":9,"created_at":"2024-05-04T23:51:36+08:00","updated_at":"2024-05-04T23:51:36+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896","variant_ids":[41896369586275]},"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-PC11","featured_media":{"alt":null,"id":23885180239971,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c4baf8ab21a20ef3b20f1a0bbbe57c050aa8072_259d16ef-3a58-4b93-a73e-adff0df11bd3.webp?v=1714837896"}},"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: "停產"
}