$product = {"id":7411027411043,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 Star Wars - 黑武士-黑白條紋","handle":"iphone-15-plus-mod-nx-magsafe-printable-pb20","description":null,"published_at":"2024-06-11T17:34:23+08:00","created_at":"2024-05-04T22:29:19+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 15 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":41894248939619,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0129624-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31479326146659,"product_id":7411027411043,"position":10,"created_at":"2024-05-04T22:29:43+08:00","updated_at":"2024-05-04T22:29:43+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983","variant_ids":[41894248939619]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 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":"MPB0129624-PB20","featured_media":{"alt":null,"id":23884573442147,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41894249070691,"title":"Mod NX-櫻花粉邊框","option1":"Mod NX-櫻花粉邊框","option2":null,"option3":null,"sku":"MPB0129657-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31479322640483,"product_id":7411027411043,"position":4,"created_at":"2024-05-04T22:29:29+08:00","updated_at":"2024-05-04T22:29:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969","variant_ids":[41894249070691]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 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":"MPB0129657-PB20","featured_media":{"alt":null,"id":23884570001507,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31a793e99afddf558b39f512d7e151eb1a87b138_681eac25-3f5b-44ba-be3e-ba60274f61c4.webp?v=1714832962","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a452fbcab9db3dfdd7a8658c34f0480eb66e9cf3_fd1a63e1-480d-4cc5-98da-7d553652506e.webp?v=1714832964","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec06301ae6a78646a307cb5459e0fb8e63513647_32f731db-24c4-4485-892d-bf147a846107.webp?v=1714832966","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/929910e2a768e435761ee1fd07301572f2354a90_859c956f-84bb-4f42-a998-0fb299999263.webp?v=1714832971","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a75b7946eba9c8ccdd4d31734a8d047de6f5cdd_7a562a35-1f9f-41f9-9d98-5b2f0e3023f0.webp?v=1714832973","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9d3b5301f39ccb311dc2c3d83ae6dcd5cde58bc2_c1c47384-c037-45f9-84ec-308fe35603a3.webp?v=1714832976","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf88e347827888d1b29673348392985f34b68b4a_7f6e0d49-eb0b-4b2b-8d60-e651cf51de61.webp?v=1714832978","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/488b71f18cfa0d3e6d3b73c1adab8eaaf854d619_211a7775-aa6f-4e5f-ab23-3cfc53da42ab.webp?v=1714832980","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31a793e99afddf558b39f512d7e151eb1a87b138_681eac25-3f5b-44ba-be3e-ba60274f61c4.webp?v=1714832962","options":["color"],"media":[{"alt":null,"id":23884568166499,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31a793e99afddf558b39f512d7e151eb1a87b138_681eac25-3f5b-44ba-be3e-ba60274f61c4.webp?v=1714832962"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31a793e99afddf558b39f512d7e151eb1a87b138_681eac25-3f5b-44ba-be3e-ba60274f61c4.webp?v=1714832962","width":2000},{"alt":null,"id":23884568625251,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a452fbcab9db3dfdd7a8658c34f0480eb66e9cf3_fd1a63e1-480d-4cc5-98da-7d553652506e.webp?v=1714832964"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a452fbcab9db3dfdd7a8658c34f0480eb66e9cf3_fd1a63e1-480d-4cc5-98da-7d553652506e.webp?v=1714832964","width":2000},{"alt":null,"id":23884569182307,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec06301ae6a78646a307cb5459e0fb8e63513647_32f731db-24c4-4485-892d-bf147a846107.webp?v=1714832966"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec06301ae6a78646a307cb5459e0fb8e63513647_32f731db-24c4-4485-892d-bf147a846107.webp?v=1714832966","width":2000},{"alt":null,"id":23884570001507,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969","width":2000},{"alt":null,"id":23884570591331,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/929910e2a768e435761ee1fd07301572f2354a90_859c956f-84bb-4f42-a998-0fb299999263.webp?v=1714832971"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/929910e2a768e435761ee1fd07301572f2354a90_859c956f-84bb-4f42-a998-0fb299999263.webp?v=1714832971","width":2000},{"alt":null,"id":23884571082851,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a75b7946eba9c8ccdd4d31734a8d047de6f5cdd_7a562a35-1f9f-41f9-9d98-5b2f0e3023f0.webp?v=1714832973"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a75b7946eba9c8ccdd4d31734a8d047de6f5cdd_7a562a35-1f9f-41f9-9d98-5b2f0e3023f0.webp?v=1714832973","width":2000},{"alt":null,"id":23884571738211,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9d3b5301f39ccb311dc2c3d83ae6dcd5cde58bc2_c1c47384-c037-45f9-84ec-308fe35603a3.webp?v=1714832976"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9d3b5301f39ccb311dc2c3d83ae6dcd5cde58bc2_c1c47384-c037-45f9-84ec-308fe35603a3.webp?v=1714832976","width":2000},{"alt":null,"id":23884572328035,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf88e347827888d1b29673348392985f34b68b4a_7f6e0d49-eb0b-4b2b-8d60-e651cf51de61.webp?v=1714832978"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bf88e347827888d1b29673348392985f34b68b4a_7f6e0d49-eb0b-4b2b-8d60-e651cf51de61.webp?v=1714832978","width":2000},{"alt":null,"id":23884572852323,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/488b71f18cfa0d3e6d3b73c1adab8eaaf854d619_211a7775-aa6f-4e5f-ab23-3cfc53da42ab.webp?v=1714832980"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/488b71f18cfa0d3e6d3b73c1adab8eaaf854d619_211a7775-aa6f-4e5f-ab23-3cfc53da42ab.webp?v=1714832980","width":2000},{"alt":null,"id":23884573442147,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $bumper = null; $variants = [{"id":41894248939619,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0129624-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31479326146659,"product_id":7411027411043,"position":10,"created_at":"2024-05-04T22:29:43+08:00","updated_at":"2024-05-04T22:29:43+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983","variant_ids":[41894248939619]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 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":"MPB0129624-PB20","featured_media":{"alt":null,"id":23884573442147,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}},{"id":41894249070691,"title":"Mod NX-櫻花粉邊框","option1":"Mod NX-櫻花粉邊框","option2":null,"option3":null,"sku":"MPB0129657-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31479322640483,"product_id":7411027411043,"position":4,"created_at":"2024-05-04T22:29:29+08:00","updated_at":"2024-05-04T22:29:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969","variant_ids":[41894249070691]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 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":"MPB0129657-PB20","featured_media":{"alt":null,"id":23884570001507,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1ce077cb061ce809aaead6252074543973d3df82_aeca5861-07f3-49f1-9bd1-70ec4786fc3c.webp?v=1714832969"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41894248939619,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0129624-PB20","requires_shipping":true,"taxable":true,"featured_image":{"id":31479326146659,"product_id":7411027411043,"position":10,"created_at":"2024-05-04T22:29:43+08:00","updated_at":"2024-05-04T22:29:43+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983","variant_ids":[41894248939619]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 15 Plus - 迪士尼-星際大戰 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":"MPB0129624-PB20","featured_media":{"alt":null,"id":23884573442147,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/64ab027e20132d9dc351bd6f7778ab22d8e3cb68_8d2f974b-22d5-41ee-8a8a-e79df7e240bc.webp?v=1714832983"}},"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: "停產" }