$product = {"id":7415069933667,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 史迪奇 - 夏威夷系列-每天搞怪","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-yf06","description":null,"published_at":"2024-06-11T17:57:09+08:00","created_at":"2024-05-05T20:17:01+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區史迪奇","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-stitch","device-iPhone 12 pro max","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-stitch","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":41911546249315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-YF06","requires_shipping":true,"taxable":true,"featured_image":{"id":31488074481763,"product_id":7415069933667,"position":1,"created_at":"2024-05-05T20:17:03+08:00","updated_at":"2024-05-05T20:17:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","variant_ids":[41911546249315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 史迪奇 - 夏威夷系列-每天搞怪 - 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":"MPB0118724-YF06","featured_media":{"alt":null,"id":23893418934371,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e9df169401f3cfc0adb292d5eb3105f76b9c30f_a77837d1-d761-4c91-9189-61345c94d9d4.webp?v=1714911426","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e185ba5a6897fd93ee55b1ab92c8d245c9d7a883_bca6140a-5d3a-4f42-807d-8341549f9062.webp?v=1714911428","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/85cab2696f8f8da6d003c03de8966e5963244443_3ca2ab36-f93a-4679-b52d-309905ead8fe.webp?v=1714911430","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/302442599367cf5780d10bff009b8ad3d741b32b_a0f946a1-d0eb-4a53-8a73-2d5ca19a8707.webp?v=1714911433","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a97cb500ffabca535083a8522a9f221d4d1a901_667abfcb-a117-4280-a469-ac0dabe44584.webp?v=1714911435","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/93028fdd176c55823d8c00f5bc01b49bc7161c04_47efc541-eee7-473f-9299-060fb96252c1.webp?v=1714911438","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0b7dca49244054a92413176b5ded5b48eb1e93f_93a02561-82ed-4fb5-8449-42d267695fbc.webp?v=1714911440","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2b862daf5bc591956bce5c154a8dcbb7a6e9ffe_70f4649f-4b68-494a-94a8-4317920c2ca6.webp?v=1714911443","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bbdc5abea317724dc91f713f701defd416695c5_ca265f2a-5880-48ac-a20a-32c286d2422c.webp?v=1714911445"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","options":["color"],"media":[{"alt":null,"id":23893418934371,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","width":2000},{"alt":null,"id":23893419327587,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e9df169401f3cfc0adb292d5eb3105f76b9c30f_a77837d1-d761-4c91-9189-61345c94d9d4.webp?v=1714911426"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e9df169401f3cfc0adb292d5eb3105f76b9c30f_a77837d1-d761-4c91-9189-61345c94d9d4.webp?v=1714911426","width":2000},{"alt":null,"id":23893420179555,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e185ba5a6897fd93ee55b1ab92c8d245c9d7a883_bca6140a-5d3a-4f42-807d-8341549f9062.webp?v=1714911428"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e185ba5a6897fd93ee55b1ab92c8d245c9d7a883_bca6140a-5d3a-4f42-807d-8341549f9062.webp?v=1714911428","width":2000},{"alt":null,"id":23893421064291,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/85cab2696f8f8da6d003c03de8966e5963244443_3ca2ab36-f93a-4679-b52d-309905ead8fe.webp?v=1714911430"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/85cab2696f8f8da6d003c03de8966e5963244443_3ca2ab36-f93a-4679-b52d-309905ead8fe.webp?v=1714911430","width":2000},{"alt":null,"id":23893421654115,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/302442599367cf5780d10bff009b8ad3d741b32b_a0f946a1-d0eb-4a53-8a73-2d5ca19a8707.webp?v=1714911433"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/302442599367cf5780d10bff009b8ad3d741b32b_a0f946a1-d0eb-4a53-8a73-2d5ca19a8707.webp?v=1714911433","width":2000},{"alt":null,"id":23893422145635,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a97cb500ffabca535083a8522a9f221d4d1a901_667abfcb-a117-4280-a469-ac0dabe44584.webp?v=1714911435"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9a97cb500ffabca535083a8522a9f221d4d1a901_667abfcb-a117-4280-a469-ac0dabe44584.webp?v=1714911435","width":2000},{"alt":null,"id":23893422899299,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/93028fdd176c55823d8c00f5bc01b49bc7161c04_47efc541-eee7-473f-9299-060fb96252c1.webp?v=1714911438"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/93028fdd176c55823d8c00f5bc01b49bc7161c04_47efc541-eee7-473f-9299-060fb96252c1.webp?v=1714911438","width":2000},{"alt":null,"id":23893423358051,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0b7dca49244054a92413176b5ded5b48eb1e93f_93a02561-82ed-4fb5-8449-42d267695fbc.webp?v=1714911440"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d0b7dca49244054a92413176b5ded5b48eb1e93f_93a02561-82ed-4fb5-8449-42d267695fbc.webp?v=1714911440","width":2000},{"alt":null,"id":23893423915107,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2b862daf5bc591956bce5c154a8dcbb7a6e9ffe_70f4649f-4b68-494a-94a8-4317920c2ca6.webp?v=1714911443"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c2b862daf5bc591956bce5c154a8dcbb7a6e9ffe_70f4649f-4b68-494a-94a8-4317920c2ca6.webp?v=1714911443","width":2000},{"alt":null,"id":23893424767075,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bbdc5abea317724dc91f713f701defd416695c5_ca265f2a-5880-48ac-a20a-32c286d2422c.webp?v=1714911445"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bbdc5abea317724dc91f713f701defd416695c5_ca265f2a-5880-48ac-a20a-32c286d2422c.webp?v=1714911445","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null};
$isMerge = null;
$variants = [{"id":41911546249315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-YF06","requires_shipping":true,"taxable":true,"featured_image":{"id":31488074481763,"product_id":7415069933667,"position":1,"created_at":"2024-05-05T20:17:03+08:00","updated_at":"2024-05-05T20:17:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","variant_ids":[41911546249315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 史迪奇 - 夏威夷系列-每天搞怪 - 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":"MPB0118724-YF06","featured_media":{"alt":null,"id":23893418934371,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}];
$defaultVariant = {"id":41911546249315,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-YF06","requires_shipping":true,"taxable":true,"featured_image":{"id":31488074481763,"product_id":7415069933667,"position":1,"created_at":"2024-05-05T20:17:03+08:00","updated_at":"2024-05-05T20:17:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423","variant_ids":[41911546249315]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 史迪奇 - 夏威夷系列-每天搞怪 - 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":"MPB0118724-YF06","featured_media":{"alt":null,"id":23893418934371,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd831dd3d0e1455d5af92be08ca429f43f683684_4c5c0669-1ab8-4d4b-a440-343d27522f75.webp?v=1714911423"}},"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: "停產"
}