$product = {"id":7408491528291,"title":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 爪哇族1-塗鴉藝術","handle":"iphone-12-mini-mod-nx-printable-pb35","description":null,"published_at":"2024-06-11T16:38:44+08:00","created_at":"2024-05-03T15:37:05+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 12 mini","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-star-wars","Top50","type-Mod NX Printable"],"price":90000,"price_min":90000,"price_max":90000,"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":41886088101987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB35","requires_shipping":true,"taxable":true,"featured_image":{"id":31472416292963,"product_id":7408491528291,"position":10,"created_at":"2024-05-03T15:37:27+08:00","updated_at":"2024-05-03T15:37:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847","variant_ids":[41886088101987]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 爪哇族1-塗鴉藝術 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118424-PB35","featured_media":{"alt":null,"id":23877333221475,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60e6e9961ead225dabd6495897f648b393f4e488_258aac03-820f-4332-81c9-50b7a521212c.webp?v=1714721828","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/500f04074efea4c45fcfbb3840f0716b0ab25e23_29605c57-b6af-47e1-b85f-7c17f0411657.webp?v=1714721830","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16c2a85a6dec8f60330eb37c61766b769cbb8e3_fd6b580f-48b9-47af-91a7-d26cc5fec565.webp?v=1714721832","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0309f5522630eae340565a4a5308defdc760768_e3c84c55-af89-4165-8073-ccb47d5037e7.webp?v=1714721834","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8f6715e55df2977b6cee92125e9b4b61abc555d6_9533fea7-4af5-4b38-9fad-2e822b564d5a.webp?v=1714721837","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bc5926e0cc28c17db7671ea564455b0709d594a_77ac723e-1d94-46b8-bc01-d6f3fc2c7d6d.webp?v=1714721839","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f5a8c0b6f8e490ff9c751f65b3943918a2e0017_bc27e30a-7066-4142-a703-05c9592aec4e.webp?v=1714721841","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e57e4c07c5b2a46a04808405a183176e973cc31c_4ebcdd03-f166-4bb5-87f9-a3d4fdb34fca.webp?v=1714721843","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9d2f5566022fe3f4a7cbce072d9855db60cf818_88ddf355-79f6-4953-8f1d-1a0f9867b991.webp?v=1714721845","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f22b01d3bd89dd7f719fcca89d1ca5e98c82c10_87ae186a-876a-4e24-a4c9-1020215dcbad.webp?v=1714721850"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60e6e9961ead225dabd6495897f648b393f4e488_258aac03-820f-4332-81c9-50b7a521212c.webp?v=1714721828","options":["color"],"media":[{"alt":null,"id":23877328666723,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60e6e9961ead225dabd6495897f648b393f4e488_258aac03-820f-4332-81c9-50b7a521212c.webp?v=1714721828"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/60e6e9961ead225dabd6495897f648b393f4e488_258aac03-820f-4332-81c9-50b7a521212c.webp?v=1714721828","width":2000},{"alt":null,"id":23877329125475,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/500f04074efea4c45fcfbb3840f0716b0ab25e23_29605c57-b6af-47e1-b85f-7c17f0411657.webp?v=1714721830"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/500f04074efea4c45fcfbb3840f0716b0ab25e23_29605c57-b6af-47e1-b85f-7c17f0411657.webp?v=1714721830","width":2000},{"alt":null,"id":23877329551459,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16c2a85a6dec8f60330eb37c61766b769cbb8e3_fd6b580f-48b9-47af-91a7-d26cc5fec565.webp?v=1714721832"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d16c2a85a6dec8f60330eb37c61766b769cbb8e3_fd6b580f-48b9-47af-91a7-d26cc5fec565.webp?v=1714721832","width":2000},{"alt":null,"id":23877330206819,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0309f5522630eae340565a4a5308defdc760768_e3c84c55-af89-4165-8073-ccb47d5037e7.webp?v=1714721834"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b0309f5522630eae340565a4a5308defdc760768_e3c84c55-af89-4165-8073-ccb47d5037e7.webp?v=1714721834","width":2000},{"alt":null,"id":23877330862179,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8f6715e55df2977b6cee92125e9b4b61abc555d6_9533fea7-4af5-4b38-9fad-2e822b564d5a.webp?v=1714721837"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8f6715e55df2977b6cee92125e9b4b61abc555d6_9533fea7-4af5-4b38-9fad-2e822b564d5a.webp?v=1714721837","width":2000},{"alt":null,"id":23877331419235,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bc5926e0cc28c17db7671ea564455b0709d594a_77ac723e-1d94-46b8-bc01-d6f3fc2c7d6d.webp?v=1714721839"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bc5926e0cc28c17db7671ea564455b0709d594a_77ac723e-1d94-46b8-bc01-d6f3fc2c7d6d.webp?v=1714721839","width":2000},{"alt":null,"id":23877331910755,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f5a8c0b6f8e490ff9c751f65b3943918a2e0017_bc27e30a-7066-4142-a703-05c9592aec4e.webp?v=1714721841"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f5a8c0b6f8e490ff9c751f65b3943918a2e0017_bc27e30a-7066-4142-a703-05c9592aec4e.webp?v=1714721841","width":2000},{"alt":null,"id":23877332271203,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e57e4c07c5b2a46a04808405a183176e973cc31c_4ebcdd03-f166-4bb5-87f9-a3d4fdb34fca.webp?v=1714721843"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e57e4c07c5b2a46a04808405a183176e973cc31c_4ebcdd03-f166-4bb5-87f9-a3d4fdb34fca.webp?v=1714721843","width":2000},{"alt":null,"id":23877332861027,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9d2f5566022fe3f4a7cbce072d9855db60cf818_88ddf355-79f6-4953-8f1d-1a0f9867b991.webp?v=1714721845"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b9d2f5566022fe3f4a7cbce072d9855db60cf818_88ddf355-79f6-4953-8f1d-1a0f9867b991.webp?v=1714721845","width":2000},{"alt":null,"id":23877333221475,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847","width":2000},{"alt":null,"id":23877333745763,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f22b01d3bd89dd7f719fcca89d1ca5e98c82c10_87ae186a-876a-4e24-a4c9-1020215dcbad.webp?v=1714721850"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f22b01d3bd89dd7f719fcca89d1ca5e98c82c10_87ae186a-876a-4e24-a4c9-1020215dcbad.webp?v=1714721850","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886088101987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB35","requires_shipping":true,"taxable":true,"featured_image":{"id":31472416292963,"product_id":7408491528291,"position":10,"created_at":"2024-05-03T15:37:27+08:00","updated_at":"2024-05-03T15:37:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847","variant_ids":[41886088101987]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 爪哇族1-塗鴉藝術 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118424-PB35","featured_media":{"alt":null,"id":23877333221475,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886088101987,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118424-PB35","requires_shipping":true,"taxable":true,"featured_image":{"id":31472416292963,"product_id":7408491528291,"position":10,"created_at":"2024-05-03T15:37:27+08:00","updated_at":"2024-05-03T15:37:27+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847","variant_ids":[41886088101987]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 mini - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 爪哇族1-塗鴉藝術 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0118424-PB35","featured_media":{"alt":null,"id":23877333221475,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdcd6833b93902fa24dce8525e7861edf17588c1_db104b3b-d526-4331-93ab-3fef4ead2cd9.webp?v=1714721847"}},"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: "停產" }