$product = {"id":7411333103715,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Pattern 伊沃克人-Galaxy","handle":"iphone-14-plus-mod-nx-magsafe-printable-pb60","description":null,"published_at":"2024-06-11T17:42:06+08:00","created_at":"2024-05-05T00:09:20+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":41897560342627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB60","requires_shipping":true,"taxable":true,"featured_image":{"id":31480162123875,"product_id":7411333103715,"position":2,"created_at":"2024-05-05T00:09:24+08:00","updated_at":"2024-05-05T00:09:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964","variant_ids":[41897560342627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Pattern 伊沃克人-Galaxy - 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-PB60","featured_media":{"alt":null,"id":23885413154915,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/19722b5309241014ef649ac41c016c5874ef1951_f78eb145-7a84-45cf-b76a-2e5bf89a5a90.webp?v=1714838962","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d58acaf62bce03f15071b5e65a90fd76898bad51_0a5926b0-e9e5-49ec-af59-dbf92da151b5.webp?v=1714838967","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10da448b3d0819576291b64c3889b7eff0e5fb1b_523426d6-4c6f-45fe-b20a-0a79c69a6fb4.webp?v=1714838969","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa0c330c70fdceef85b693b0951908c906d6576b_36fe5fad-c7cc-414b-b21e-439ada5e4eaa.webp?v=1714838971","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/598b4f8bc38766e539439838b1c004ff0fa53542_d48bfa7a-ccb8-4833-b0d4-b19c0e9a2f96.webp?v=1714838974","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4f1bc443996f64aacb57376a967d386f37ab8b65_987a0246-6f52-4623-bf7e-d53cbac3bf98.webp?v=1714838976","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1445c44b03550945e97e7706e9464a33e28e2647_614e6408-8bf7-47ad-8b46-1935ef8b49d4.webp?v=1714838978","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ea2113a6e118df280a21b281bfc7989e709129c6_228c1949-32b9-43f4-b650-b3c04d51bb22.webp?v=1714838981","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/869ee5c088c6c3255e0be242f634c4446ca9dfd9_667bc270-6e9a-46d3-8151-eb814ac57677.webp?v=1714838983"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/19722b5309241014ef649ac41c016c5874ef1951_f78eb145-7a84-45cf-b76a-2e5bf89a5a90.webp?v=1714838962","options":["color"],"media":[{"alt":null,"id":23885412663395,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/19722b5309241014ef649ac41c016c5874ef1951_f78eb145-7a84-45cf-b76a-2e5bf89a5a90.webp?v=1714838962"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/19722b5309241014ef649ac41c016c5874ef1951_f78eb145-7a84-45cf-b76a-2e5bf89a5a90.webp?v=1714838962","width":2000},{"alt":null,"id":23885413154915,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964","width":2000},{"alt":null,"id":23885413777507,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d58acaf62bce03f15071b5e65a90fd76898bad51_0a5926b0-e9e5-49ec-af59-dbf92da151b5.webp?v=1714838967"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d58acaf62bce03f15071b5e65a90fd76898bad51_0a5926b0-e9e5-49ec-af59-dbf92da151b5.webp?v=1714838967","width":2000},{"alt":null,"id":23885414170723,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10da448b3d0819576291b64c3889b7eff0e5fb1b_523426d6-4c6f-45fe-b20a-0a79c69a6fb4.webp?v=1714838969"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/10da448b3d0819576291b64c3889b7eff0e5fb1b_523426d6-4c6f-45fe-b20a-0a79c69a6fb4.webp?v=1714838969","width":2000},{"alt":null,"id":23885414793315,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa0c330c70fdceef85b693b0951908c906d6576b_36fe5fad-c7cc-414b-b21e-439ada5e4eaa.webp?v=1714838971"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aa0c330c70fdceef85b693b0951908c906d6576b_36fe5fad-c7cc-414b-b21e-439ada5e4eaa.webp?v=1714838971","width":2000},{"alt":null,"id":23885415186531,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/598b4f8bc38766e539439838b1c004ff0fa53542_d48bfa7a-ccb8-4833-b0d4-b19c0e9a2f96.webp?v=1714838974"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/598b4f8bc38766e539439838b1c004ff0fa53542_d48bfa7a-ccb8-4833-b0d4-b19c0e9a2f96.webp?v=1714838974","width":2000},{"alt":null,"id":23885415678051,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4f1bc443996f64aacb57376a967d386f37ab8b65_987a0246-6f52-4623-bf7e-d53cbac3bf98.webp?v=1714838976"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4f1bc443996f64aacb57376a967d386f37ab8b65_987a0246-6f52-4623-bf7e-d53cbac3bf98.webp?v=1714838976","width":2000},{"alt":null,"id":23885416267875,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1445c44b03550945e97e7706e9464a33e28e2647_614e6408-8bf7-47ad-8b46-1935ef8b49d4.webp?v=1714838978"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1445c44b03550945e97e7706e9464a33e28e2647_614e6408-8bf7-47ad-8b46-1935ef8b49d4.webp?v=1714838978","width":2000},{"alt":null,"id":23885416792163,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ea2113a6e118df280a21b281bfc7989e709129c6_228c1949-32b9-43f4-b650-b3c04d51bb22.webp?v=1714838981"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ea2113a6e118df280a21b281bfc7989e709129c6_228c1949-32b9-43f4-b650-b3c04d51bb22.webp?v=1714838981","width":2000},{"alt":null,"id":23885417185379,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/869ee5c088c6c3255e0be242f634c4446ca9dfd9_667bc270-6e9a-46d3-8151-eb814ac57677.webp?v=1714838983"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/869ee5c088c6c3255e0be242f634c4446ca9dfd9_667bc270-6e9a-46d3-8151-eb814ac57677.webp?v=1714838983","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $bumper = null; $variants = [{"id":41897560342627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB60","requires_shipping":true,"taxable":true,"featured_image":{"id":31480162123875,"product_id":7411333103715,"position":2,"created_at":"2024-05-05T00:09:24+08:00","updated_at":"2024-05-05T00:09:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964","variant_ids":[41897560342627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Pattern 伊沃克人-Galaxy - 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-PB60","featured_media":{"alt":null,"id":23885413154915,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41897560342627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB60","requires_shipping":true,"taxable":true,"featured_image":{"id":31480162123875,"product_id":7411333103715,"position":2,"created_at":"2024-05-05T00:09:24+08:00","updated_at":"2024-05-05T00:09:24+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964","variant_ids":[41897560342627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Pattern 伊沃克人-Galaxy - 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-PB60","featured_media":{"alt":null,"id":23885413154915,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ef474f0b88a52c21888abb355f80ab8faa6f7a63_632c919c-89d7-479b-9c3b-49989b90d50b.webp?v=1714838964"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}; $device_handle = null var sellingStatus if ($bumper) { $(document).ready(function() { var productImg = $product.images[0] var bumperVariants = $bumper.variants; var bumperColors = new Object(); var currentVariant = ''; var productType = ''; bumperVariants.forEach(variant => { bumperColors[`${variant.title.split(' (')[0].toLowerCase()}`] = variant.featured_image.src; }); if (productType === 'mod-nx-backplate' || productType === 'mod-backplate') { mergeImages( [productImg, bumperColors[currentVariant]], { crossOrigin: 'anonymous' } ).then(mergedImg => { $('.merged-img').attr('src', mergedImg); }); } else { mergeImages( [bumperColors[currentVariant], productImg], { crossOrigin: 'anonymous' } ).then(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: "停產" }