$product = {"id":7415036215395,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 迪士尼-星際大戰 Star Wars - 絕地武士-光劍系列","handle":"iphone-12-pro-max-mod-nx-magsafe-printable-pb71","description":null,"published_at":"2024-06-11T17:56:15+08:00","created_at":"2024-05-05T20:10:58+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 12 pro max","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":41911185408099,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PB71","requires_shipping":true,"taxable":true,"featured_image":{"id":31487992135779,"product_id":7415036215395,"position":10,"created_at":"2024-05-05T20:11:21+08:00","updated_at":"2024-05-05T20:11:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082","variant_ids":[41911185408099]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 迪士尼-星際大戰 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":"MPB0118724-PB71","featured_media":{"alt":null,"id":23893336391779,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5bbb4d8f93e5b591caffbd2483f1e48e23c9e861_ec958123-2c2a-404a-9167-047954a28f4a.webp?v=1714911061","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d1112e58fa1ddcf8ad6a53cccacb784d2b0a05e_0f22e615-794c-4091-8de5-41b1c4ee700b.webp?v=1714911063","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55df5f54a6775bdf3b94af541d0c3795aa62638d_e1addd72-64b9-4dbb-ba3d-5b4147dbcbbb.webp?v=1714911065","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3d8bd86091d7e15a685237c164e346326b5b9d9_a83d41c3-ab77-4caf-8a10-7e0590bee6aa.webp?v=1714911068","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cadf3db19b44624221d213f9922f168bfb8733d_b8a8c8d4-45b0-4ead-a21a-a4beee99529c.webp?v=1714911070","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/65e0b7bd62c486f2f8f559635af8c3856fc370fd_dd1a2f88-84c1-49be-bdd3-1daff5b85f04.webp?v=1714911072","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5b0fc46fbf5da89f56c01871b093b95a752e4ddb_c21bab4e-d718-4f47-86c0-978488323554.webp?v=1714911074","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/453dbfdd203545c2b993202274bcb69fbac65301_46573516-8178-46f6-96e2-46e0b26e5dfe.webp?v=1714911077","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2558386012b36c8f9ed5e886b4342966985775c6_cd89b5cb-470b-4a46-aa81-4118a0a415c7.webp?v=1714911079","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5bbb4d8f93e5b591caffbd2483f1e48e23c9e861_ec958123-2c2a-404a-9167-047954a28f4a.webp?v=1714911061","options":["color"],"media":[{"alt":null,"id":23893331083363,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5bbb4d8f93e5b591caffbd2483f1e48e23c9e861_ec958123-2c2a-404a-9167-047954a28f4a.webp?v=1714911061"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5bbb4d8f93e5b591caffbd2483f1e48e23c9e861_ec958123-2c2a-404a-9167-047954a28f4a.webp?v=1714911061","width":2000},{"alt":null,"id":23893331640419,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d1112e58fa1ddcf8ad6a53cccacb784d2b0a05e_0f22e615-794c-4091-8de5-41b1c4ee700b.webp?v=1714911063"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4d1112e58fa1ddcf8ad6a53cccacb784d2b0a05e_0f22e615-794c-4091-8de5-41b1c4ee700b.webp?v=1714911063","width":2000},{"alt":null,"id":23893331968099,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55df5f54a6775bdf3b94af541d0c3795aa62638d_e1addd72-64b9-4dbb-ba3d-5b4147dbcbbb.webp?v=1714911065"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/55df5f54a6775bdf3b94af541d0c3795aa62638d_e1addd72-64b9-4dbb-ba3d-5b4147dbcbbb.webp?v=1714911065","width":2000},{"alt":null,"id":23893333016675,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3d8bd86091d7e15a685237c164e346326b5b9d9_a83d41c3-ab77-4caf-8a10-7e0590bee6aa.webp?v=1714911068"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3d8bd86091d7e15a685237c164e346326b5b9d9_a83d41c3-ab77-4caf-8a10-7e0590bee6aa.webp?v=1714911068","width":2000},{"alt":null,"id":23893333540963,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cadf3db19b44624221d213f9922f168bfb8733d_b8a8c8d4-45b0-4ead-a21a-a4beee99529c.webp?v=1714911070"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4cadf3db19b44624221d213f9922f168bfb8733d_b8a8c8d4-45b0-4ead-a21a-a4beee99529c.webp?v=1714911070","width":2000},{"alt":null,"id":23893334163555,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/65e0b7bd62c486f2f8f559635af8c3856fc370fd_dd1a2f88-84c1-49be-bdd3-1daff5b85f04.webp?v=1714911072"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/65e0b7bd62c486f2f8f559635af8c3856fc370fd_dd1a2f88-84c1-49be-bdd3-1daff5b85f04.webp?v=1714911072","width":2000},{"alt":null,"id":23893334851683,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5b0fc46fbf5da89f56c01871b093b95a752e4ddb_c21bab4e-d718-4f47-86c0-978488323554.webp?v=1714911074"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5b0fc46fbf5da89f56c01871b093b95a752e4ddb_c21bab4e-d718-4f47-86c0-978488323554.webp?v=1714911074","width":2000},{"alt":null,"id":23893335310435,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/453dbfdd203545c2b993202274bcb69fbac65301_46573516-8178-46f6-96e2-46e0b26e5dfe.webp?v=1714911077"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/453dbfdd203545c2b993202274bcb69fbac65301_46573516-8178-46f6-96e2-46e0b26e5dfe.webp?v=1714911077","width":2000},{"alt":null,"id":23893335998563,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2558386012b36c8f9ed5e886b4342966985775c6_cd89b5cb-470b-4a46-aa81-4118a0a415c7.webp?v=1714911079"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2558386012b36c8f9ed5e886b4342966985775c6_cd89b5cb-470b-4a46-aa81-4118a0a415c7.webp?v=1714911079","width":2000},{"alt":null,"id":23893336391779,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41911185408099,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PB71","requires_shipping":true,"taxable":true,"featured_image":{"id":31487992135779,"product_id":7415036215395,"position":10,"created_at":"2024-05-05T20:11:21+08:00","updated_at":"2024-05-05T20:11:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082","variant_ids":[41911185408099]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 迪士尼-星際大戰 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":"MPB0118724-PB71","featured_media":{"alt":null,"id":23893336391779,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41911185408099,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118724-PB71","requires_shipping":true,"taxable":true,"featured_image":{"id":31487992135779,"product_id":7415036215395,"position":10,"created_at":"2024-05-05T20:11:21+08:00","updated_at":"2024-05-05T20:11:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082","variant_ids":[41911185408099]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 Pro Max - 迪士尼-星際大戰 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":"MPB0118724-PB71","featured_media":{"alt":null,"id":23893336391779,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb0cf6806c3da8b544f44339b1bf53922de2cbb4_25f0ac8c-4719-40f1-8c5d-98a13253ac5e.webp?v=1714911082"}},"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: "停產" }