$product = {"id":7407678029923,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-日文字系列","handle":"iphone-14-plus-mod-nx-printable-pb64","description":null,"published_at":"2024-06-11T16:21:52+08:00","created_at":"2024-05-03T10:40:33+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 14 Plus","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":41877536505955,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB64","requires_shipping":true,"taxable":true,"featured_image":{"id":31470203732067,"product_id":7407678029923,"position":6,"created_at":"2024-05-03T10:40:50+08:00","updated_at":"2024-05-03T10:40:50+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050","variant_ids":[41877536505955]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-日文字系列 - 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":"NPB0126124-PB64","featured_media":{"alt":null,"id":23875106701411,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a7dfc4c6bb39a93246caed7b9138272a7a76383_e04b3ed7-89ee-4e65-8316-d4793978144e.webp?v=1714704036","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1ac690134b7e45ba73f5e92583d76f2e427a177_94c0af38-b219-4790-a3f1-b322734481b7.webp?v=1714704039","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/857078af47708a435e014b6256191d1b47e6e25e_c1ff5ade-88e7-4c34-b24f-87270548ce4b.webp?v=1714704041","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6dda520fd29b7173f251b2c52066e994e296fcb8_e7506857-4c5e-4896-a0aa-919424f990de.webp?v=1714704044","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03892761351e532f1787fcfff612d55c14ec24a1_69f1daa8-ed70-43e8-9980-74d88fba870d.webp?v=1714704046","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2e8bf38d144cad74e1f618ca4be9d75124eed61_f6d60a90-bab5-4ebb-8300-2018b7831504.webp?v=1714704052","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f9211b49af1bc5fa209fde9cada8d2bd42ad3fb_0e2d7773-0445-4225-b5cb-955292cddd2c.webp?v=1714704055","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/39af7cc967c8b7a08ebc01c47e935872468350ed_46638e87-300c-4058-8b17-50aea7cfe009.webp?v=1714704057","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8124892029f3cc373348505a7c42b78b63e2c4e3_31e991ae-4bd4-4b7c-b125-76171ac939c5.webp?v=1714704060"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a7dfc4c6bb39a93246caed7b9138272a7a76383_e04b3ed7-89ee-4e65-8316-d4793978144e.webp?v=1714704036","options":["color"],"media":[{"alt":null,"id":23875102507107,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a7dfc4c6bb39a93246caed7b9138272a7a76383_e04b3ed7-89ee-4e65-8316-d4793978144e.webp?v=1714704036"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1a7dfc4c6bb39a93246caed7b9138272a7a76383_e04b3ed7-89ee-4e65-8316-d4793978144e.webp?v=1714704036","width":2000},{"alt":null,"id":23875103162467,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1ac690134b7e45ba73f5e92583d76f2e427a177_94c0af38-b219-4790-a3f1-b322734481b7.webp?v=1714704039"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1ac690134b7e45ba73f5e92583d76f2e427a177_94c0af38-b219-4790-a3f1-b322734481b7.webp?v=1714704039","width":2000},{"alt":null,"id":23875104538723,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/857078af47708a435e014b6256191d1b47e6e25e_c1ff5ade-88e7-4c34-b24f-87270548ce4b.webp?v=1714704041"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/857078af47708a435e014b6256191d1b47e6e25e_c1ff5ade-88e7-4c34-b24f-87270548ce4b.webp?v=1714704041","width":2000},{"alt":null,"id":23875105030243,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6dda520fd29b7173f251b2c52066e994e296fcb8_e7506857-4c5e-4896-a0aa-919424f990de.webp?v=1714704044"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6dda520fd29b7173f251b2c52066e994e296fcb8_e7506857-4c5e-4896-a0aa-919424f990de.webp?v=1714704044","width":2000},{"alt":null,"id":23875105685603,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03892761351e532f1787fcfff612d55c14ec24a1_69f1daa8-ed70-43e8-9980-74d88fba870d.webp?v=1714704046"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/03892761351e532f1787fcfff612d55c14ec24a1_69f1daa8-ed70-43e8-9980-74d88fba870d.webp?v=1714704046","width":2000},{"alt":null,"id":23875106701411,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050","width":2000},{"alt":null,"id":23875107291235,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2e8bf38d144cad74e1f618ca4be9d75124eed61_f6d60a90-bab5-4ebb-8300-2018b7831504.webp?v=1714704052"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2e8bf38d144cad74e1f618ca4be9d75124eed61_f6d60a90-bab5-4ebb-8300-2018b7831504.webp?v=1714704052","width":2000},{"alt":null,"id":23875107946595,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f9211b49af1bc5fa209fde9cada8d2bd42ad3fb_0e2d7773-0445-4225-b5cb-955292cddd2c.webp?v=1714704055"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0f9211b49af1bc5fa209fde9cada8d2bd42ad3fb_0e2d7773-0445-4225-b5cb-955292cddd2c.webp?v=1714704055","width":2000},{"alt":null,"id":23875108864099,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/39af7cc967c8b7a08ebc01c47e935872468350ed_46638e87-300c-4058-8b17-50aea7cfe009.webp?v=1714704057"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/39af7cc967c8b7a08ebc01c47e935872468350ed_46638e87-300c-4058-8b17-50aea7cfe009.webp?v=1714704057","width":2000},{"alt":null,"id":23875109453923,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8124892029f3cc373348505a7c42b78b63e2c4e3_31e991ae-4bd4-4b7c-b125-76171ac939c5.webp?v=1714704060"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8124892029f3cc373348505a7c42b78b63e2c4e3_31e991ae-4bd4-4b7c-b125-76171ac939c5.webp?v=1714704060","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41877536505955,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB64","requires_shipping":true,"taxable":true,"featured_image":{"id":31470203732067,"product_id":7407678029923,"position":6,"created_at":"2024-05-03T10:40:50+08:00","updated_at":"2024-05-03T10:40:50+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050","variant_ids":[41877536505955]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-日文字系列 - 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":"NPB0126124-PB64","featured_media":{"alt":null,"id":23875106701411,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41877536505955,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-PB64","requires_shipping":true,"taxable":true,"featured_image":{"id":31470203732067,"product_id":7407678029923,"position":6,"created_at":"2024-05-03T10:40:50+08:00","updated_at":"2024-05-03T10:40:50+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050","variant_ids":[41877536505955]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - R2D2-日文字系列 - 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":"NPB0126124-PB64","featured_media":{"alt":null,"id":23875106701411,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f5455ac7fb66310150f9f647fc7b292c984f753b_b72da879-3d10-4f52-81ba-ddbdea98296e.webp?v=1714704050"}},"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: "停產" }