$product = {"id":7411427344483,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 迪士尼-星際大戰 Star Wars - Sticker-藍","handle":"iphone-14-plus-mod-nx-magsafe-printable-pb32","description":null,"published_at":"2024-06-11T17:44:42+08:00","created_at":"2024-05-05T00:27:45+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":41898750705763,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB32","requires_shipping":true,"taxable":true,"featured_image":{"id":31480400511075,"product_id":7411427344483,"position":7,"created_at":"2024-05-05T00:28:03+08:00","updated_at":"2024-05-05T00:28:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083","variant_ids":[41898750705763]},"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-PB32","featured_media":{"alt":null,"id":23885652164707,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df3c680323e5b6dee29b90f691a90ee6f13d756d_e174f382-deb4-4105-92bd-a09a5dfd820d.webp?v=1714840068","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f3707f687ca9ab71bd1c081681cf7e03a669b36_152bcff8-804a-4201-b128-62cc4855a45c.webp?v=1714840070","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5726c1db87cc04d02147bf218b7689c2578b660_67a37f62-9d8e-41b7-8684-4a7a4ba3995c.webp?v=1714840073","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa82131c60a74d0e34b1019270c180234ea82a8_2ffae5c5-6e74-406e-abf5-e5ac0ed3cf7e.webp?v=1714840075","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecbbe49f6b3b61a5a7b10333877ffbf85312b583_5800b0bd-9564-48a8-9775-907f9258124c.webp?v=1714840078","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/382f614bf183a9a42482c5d2907488686eeb9416_dba11078-d4b7-4fec-a7ea-ce3cff98fc68.webp?v=1714840080","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aeecd8f48acd751907aee8e83f63ffb2f6edf20d_ec3d6328-8e22-4b80-89c7-2b8b8226a07d.webp?v=1714840085","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fd1cf99e90da6323b4d9d8b95698eddbf826c065_304afcfc-8085-445f-81d5-2d9505e7829a.webp?v=1714840088","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd6bdfa29a69c2f6d6d78889ac640d64454ddde5_a6db2f1a-03f6-4fa3-888e-3b37c22ac076.webp?v=1714840091"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df3c680323e5b6dee29b90f691a90ee6f13d756d_e174f382-deb4-4105-92bd-a09a5dfd820d.webp?v=1714840068","options":["color"],"media":[{"alt":null,"id":23885648855139,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df3c680323e5b6dee29b90f691a90ee6f13d756d_e174f382-deb4-4105-92bd-a09a5dfd820d.webp?v=1714840068"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/df3c680323e5b6dee29b90f691a90ee6f13d756d_e174f382-deb4-4105-92bd-a09a5dfd820d.webp?v=1714840068","width":2000},{"alt":null,"id":23885649313891,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f3707f687ca9ab71bd1c081681cf7e03a669b36_152bcff8-804a-4201-b128-62cc4855a45c.webp?v=1714840070"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f3707f687ca9ab71bd1c081681cf7e03a669b36_152bcff8-804a-4201-b128-62cc4855a45c.webp?v=1714840070","width":2000},{"alt":null,"id":23885649838179,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5726c1db87cc04d02147bf218b7689c2578b660_67a37f62-9d8e-41b7-8684-4a7a4ba3995c.webp?v=1714840073"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b5726c1db87cc04d02147bf218b7689c2578b660_67a37f62-9d8e-41b7-8684-4a7a4ba3995c.webp?v=1714840073","width":2000},{"alt":null,"id":23885650428003,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa82131c60a74d0e34b1019270c180234ea82a8_2ffae5c5-6e74-406e-abf5-e5ac0ed3cf7e.webp?v=1714840075"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aa82131c60a74d0e34b1019270c180234ea82a8_2ffae5c5-6e74-406e-abf5-e5ac0ed3cf7e.webp?v=1714840075","width":2000},{"alt":null,"id":23885651017827,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecbbe49f6b3b61a5a7b10333877ffbf85312b583_5800b0bd-9564-48a8-9775-907f9258124c.webp?v=1714840078"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ecbbe49f6b3b61a5a7b10333877ffbf85312b583_5800b0bd-9564-48a8-9775-907f9258124c.webp?v=1714840078","width":2000},{"alt":null,"id":23885651673187,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/382f614bf183a9a42482c5d2907488686eeb9416_dba11078-d4b7-4fec-a7ea-ce3cff98fc68.webp?v=1714840080"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/382f614bf183a9a42482c5d2907488686eeb9416_dba11078-d4b7-4fec-a7ea-ce3cff98fc68.webp?v=1714840080","width":2000},{"alt":null,"id":23885652164707,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083","width":2000},{"alt":null,"id":23885652721763,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aeecd8f48acd751907aee8e83f63ffb2f6edf20d_ec3d6328-8e22-4b80-89c7-2b8b8226a07d.webp?v=1714840085"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aeecd8f48acd751907aee8e83f63ffb2f6edf20d_ec3d6328-8e22-4b80-89c7-2b8b8226a07d.webp?v=1714840085","width":2000},{"alt":null,"id":23885653180515,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fd1cf99e90da6323b4d9d8b95698eddbf826c065_304afcfc-8085-445f-81d5-2d9505e7829a.webp?v=1714840088"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fd1cf99e90da6323b4d9d8b95698eddbf826c065_304afcfc-8085-445f-81d5-2d9505e7829a.webp?v=1714840088","width":2000},{"alt":null,"id":23885653835875,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd6bdfa29a69c2f6d6d78889ac640d64454ddde5_a6db2f1a-03f6-4fa3-888e-3b37c22ac076.webp?v=1714840091"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd6bdfa29a69c2f6d6d78889ac640d64454ddde5_a6db2f1a-03f6-4fa3-888e-3b37c22ac076.webp?v=1714840091","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41898750705763,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB32","requires_shipping":true,"taxable":true,"featured_image":{"id":31480400511075,"product_id":7411427344483,"position":7,"created_at":"2024-05-05T00:28:03+08:00","updated_at":"2024-05-05T00:28:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083","variant_ids":[41898750705763]},"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-PB32","featured_media":{"alt":null,"id":23885652164707,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41898750705763,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PB32","requires_shipping":true,"taxable":true,"featured_image":{"id":31480400511075,"product_id":7411427344483,"position":7,"created_at":"2024-05-05T00:28:03+08:00","updated_at":"2024-05-05T00:28:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083","variant_ids":[41898750705763]},"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-PB32","featured_media":{"alt":null,"id":23885652164707,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b334906d4b86e09f8c6c48fd9cc966f1e990338f_4aaefddb-a09f-4c7c-897f-5dd18ab3ebb1.webp?v=1714840083"}},"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: "停產" }