$product = {"id":7411233849443,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Sticker-紅","handle":"iphone-14-plus-mod-nx-magsafe-printable-pb33","description":null,"published_at":"2024-06-11T17:39:28+08:00","created_at":"2024-05-04T23:50:30+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":41896321220707,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB33","requires_shipping":true,"taxable":true,"featured_image":{"id":31479917674595,"product_id":7411233849443,"position":2,"created_at":"2024-05-04T23:50:34+08:00","updated_at":"2024-05-04T23:50:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835","variant_ids":[41896321220707]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Sticker-紅 - 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-PB33","featured_media":{"alt":null,"id":23885168083043,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db3bd3d3affaec6d63f4d6e69491a96fbe9bd62a_21a1c40b-27de-4009-bb21-0eff63e1d5f8.webp?v=1714837832","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/faa1391453448965437d0b78fbfc060875222ea9_15b00c5f-888a-433c-8711-459648f14daa.webp?v=1714837837","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55dc62152f8c0ff5817ea76ac2b210f728b395bc_7da4368f-18b2-4b4b-b54b-0038f7973c9f.webp?v=1714837839","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c7949444a69f2a4309effea7d5d5a411424d3738_2953cc91-02aa-4021-9d59-87c5794112a0.webp?v=1714837841","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a1a9e203abaf2785c25b2c6d2b9d330f28287f2_53ad1dd8-34fa-4eb4-84ee-b233811b867b.webp?v=1714837844","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0791bf4664c179c82039db6112f3dc3161662559_a9372660-a922-4b1f-9abd-b8ae683c233c.webp?v=1714837846","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7afeacaeb84b96ed5a06fb44e63c87a4e3da2e66_ff039f99-1871-427d-8608-a8a1605be721.webp?v=1714837848","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4041efe340f5dc9dfeca7b293094cb53ffc7932d_03992b2b-a7cc-44bc-9ed6-10b0614454d4.webp?v=1714837851","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/494e6b1e4e15b554924337d72414437c614a669e_3024d1a1-86c0-4629-b539-7628aec27864.webp?v=1714837853"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db3bd3d3affaec6d63f4d6e69491a96fbe9bd62a_21a1c40b-27de-4009-bb21-0eff63e1d5f8.webp?v=1714837832","options":["color"],"media":[{"alt":null,"id":23885167525987,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db3bd3d3affaec6d63f4d6e69491a96fbe9bd62a_21a1c40b-27de-4009-bb21-0eff63e1d5f8.webp?v=1714837832"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/db3bd3d3affaec6d63f4d6e69491a96fbe9bd62a_21a1c40b-27de-4009-bb21-0eff63e1d5f8.webp?v=1714837832","width":2000},{"alt":null,"id":23885168083043,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835","width":2000},{"alt":null,"id":23885168443491,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/faa1391453448965437d0b78fbfc060875222ea9_15b00c5f-888a-433c-8711-459648f14daa.webp?v=1714837837"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/faa1391453448965437d0b78fbfc060875222ea9_15b00c5f-888a-433c-8711-459648f14daa.webp?v=1714837837","width":2000},{"alt":null,"id":23885168902243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55dc62152f8c0ff5817ea76ac2b210f728b395bc_7da4368f-18b2-4b4b-b54b-0038f7973c9f.webp?v=1714837839"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55dc62152f8c0ff5817ea76ac2b210f728b395bc_7da4368f-18b2-4b4b-b54b-0038f7973c9f.webp?v=1714837839","width":2000},{"alt":null,"id":23885169328227,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c7949444a69f2a4309effea7d5d5a411424d3738_2953cc91-02aa-4021-9d59-87c5794112a0.webp?v=1714837841"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c7949444a69f2a4309effea7d5d5a411424d3738_2953cc91-02aa-4021-9d59-87c5794112a0.webp?v=1714837841","width":2000},{"alt":null,"id":23885170016355,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a1a9e203abaf2785c25b2c6d2b9d330f28287f2_53ad1dd8-34fa-4eb4-84ee-b233811b867b.webp?v=1714837844"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a1a9e203abaf2785c25b2c6d2b9d330f28287f2_53ad1dd8-34fa-4eb4-84ee-b233811b867b.webp?v=1714837844","width":2000},{"alt":null,"id":23885170475107,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0791bf4664c179c82039db6112f3dc3161662559_a9372660-a922-4b1f-9abd-b8ae683c233c.webp?v=1714837846"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0791bf4664c179c82039db6112f3dc3161662559_a9372660-a922-4b1f-9abd-b8ae683c233c.webp?v=1714837846","width":2000},{"alt":null,"id":23885170999395,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7afeacaeb84b96ed5a06fb44e63c87a4e3da2e66_ff039f99-1871-427d-8608-a8a1605be721.webp?v=1714837848"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7afeacaeb84b96ed5a06fb44e63c87a4e3da2e66_ff039f99-1871-427d-8608-a8a1605be721.webp?v=1714837848","width":2000},{"alt":null,"id":23885171327075,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4041efe340f5dc9dfeca7b293094cb53ffc7932d_03992b2b-a7cc-44bc-9ed6-10b0614454d4.webp?v=1714837851"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4041efe340f5dc9dfeca7b293094cb53ffc7932d_03992b2b-a7cc-44bc-9ed6-10b0614454d4.webp?v=1714837851","width":2000},{"alt":null,"id":23885171621987,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/494e6b1e4e15b554924337d72414437c614a669e_3024d1a1-86c0-4629-b539-7628aec27864.webp?v=1714837853"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/494e6b1e4e15b554924337d72414437c614a669e_3024d1a1-86c0-4629-b539-7628aec27864.webp?v=1714837853","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41896321220707,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB33","requires_shipping":true,"taxable":true,"featured_image":{"id":31479917674595,"product_id":7411233849443,"position":2,"created_at":"2024-05-04T23:50:34+08:00","updated_at":"2024-05-04T23:50:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835","variant_ids":[41896321220707]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Sticker-紅 - 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-PB33","featured_media":{"alt":null,"id":23885168083043,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41896321220707,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB33","requires_shipping":true,"taxable":true,"featured_image":{"id":31479917674595,"product_id":7411233849443,"position":2,"created_at":"2024-05-04T23:50:34+08:00","updated_at":"2024-05-04T23:50:35+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835","variant_ids":[41896321220707]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Sticker-紅 - 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-PB33","featured_media":{"alt":null,"id":23885168083043,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f3e458c8f1df6686a98eb841708c736e28806c4_ff1de5a6-fd84-443a-beed-c52fd881a142.webp?v=1714837835"}},"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: "停產" }