$product = {"id":7415928094819,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 鈦戰機-線條黑","handle":"iphone-xs-max-mod-nx-printable-pb17","description":null,"published_at":"2024-06-11T16:48:09+08:00","created_at":"2024-05-06T12:26:31+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 XS Max","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":41915617738851,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB17","requires_shipping":true,"taxable":true,"featured_image":{"id":31490758738019,"product_id":7415928094819,"position":4,"created_at":"2024-05-06T12:26:42+08:00","updated_at":"2024-05-06T12:26:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602","variant_ids":[41915617738851]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 鈦戰機-線條黑 - 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":"NPB0108624-PB17","featured_media":{"alt":null,"id":23896165580899,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e19cf7932ff232d438bfab560178da0122ea634_e02c75c2-311b-4c69-be41-91877aa427ee.webp?v=1714969594","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be65fa25b9bff354a31c62402b7e5f6968c2d131_73723232-947f-40e2-bf91-c2fbb7f5626d.webp?v=1714969596","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8d39f3e7697326814f74afbdacd27d2e655c0fd_5111cca9-b9fc-4053-a693-065df2dd6dcb.webp?v=1714969599","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c59f7013b4cd369cd4ac29782e576c9dc67d5ae_33caf098-1f9a-48ca-9a0f-284f7b40b7a6.webp?v=1714969604","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b738e4acdd98b8b77fe160f89f19e5e29b0cc5ee_3961a18c-5ce9-4677-8208-16963777bfd8.webp?v=1714969607","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0e51f9c4a7b87b370162b1e6dfe3a0755141eb_0dd107a8-e2fb-470f-a0ee-48c563938eda.webp?v=1714969610","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6be8199f770f78f0ba5541ddfff2c15ab60c398c_89f60286-3b79-4f77-84ca-12b6f927fb29.webp?v=1714969612","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/72da131c9a421a8ba3683863a9653cfd7aa1e581_59362e0e-9ce5-4403-a54c-b541a0a1c66e.webp?v=1714969615","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d7bf5e42db22d3e713179cdcf75a34da60dad2c_ba39a903-962b-4825-83d2-ff850a2a0acb.webp?v=1714969617"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e19cf7932ff232d438bfab560178da0122ea634_e02c75c2-311b-4c69-be41-91877aa427ee.webp?v=1714969594","options":["color"],"media":[{"alt":null,"id":23896163647587,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e19cf7932ff232d438bfab560178da0122ea634_e02c75c2-311b-4c69-be41-91877aa427ee.webp?v=1714969594"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e19cf7932ff232d438bfab560178da0122ea634_e02c75c2-311b-4c69-be41-91877aa427ee.webp?v=1714969594","width":2000},{"alt":null,"id":23896164270179,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be65fa25b9bff354a31c62402b7e5f6968c2d131_73723232-947f-40e2-bf91-c2fbb7f5626d.webp?v=1714969596"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/be65fa25b9bff354a31c62402b7e5f6968c2d131_73723232-947f-40e2-bf91-c2fbb7f5626d.webp?v=1714969596","width":2000},{"alt":null,"id":23896164925539,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8d39f3e7697326814f74afbdacd27d2e655c0fd_5111cca9-b9fc-4053-a693-065df2dd6dcb.webp?v=1714969599"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d8d39f3e7697326814f74afbdacd27d2e655c0fd_5111cca9-b9fc-4053-a693-065df2dd6dcb.webp?v=1714969599","width":2000},{"alt":null,"id":23896165580899,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602","width":2000},{"alt":null,"id":23896166039651,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c59f7013b4cd369cd4ac29782e576c9dc67d5ae_33caf098-1f9a-48ca-9a0f-284f7b40b7a6.webp?v=1714969604"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4c59f7013b4cd369cd4ac29782e576c9dc67d5ae_33caf098-1f9a-48ca-9a0f-284f7b40b7a6.webp?v=1714969604","width":2000},{"alt":null,"id":23896166563939,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b738e4acdd98b8b77fe160f89f19e5e29b0cc5ee_3961a18c-5ce9-4677-8208-16963777bfd8.webp?v=1714969607"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b738e4acdd98b8b77fe160f89f19e5e29b0cc5ee_3961a18c-5ce9-4677-8208-16963777bfd8.webp?v=1714969607","width":2000},{"alt":null,"id":23896167579747,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0e51f9c4a7b87b370162b1e6dfe3a0755141eb_0dd107a8-e2fb-470f-a0ee-48c563938eda.webp?v=1714969610"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ce0e51f9c4a7b87b370162b1e6dfe3a0755141eb_0dd107a8-e2fb-470f-a0ee-48c563938eda.webp?v=1714969610","width":2000},{"alt":null,"id":23896168890467,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6be8199f770f78f0ba5541ddfff2c15ab60c398c_89f60286-3b79-4f77-84ca-12b6f927fb29.webp?v=1714969612"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6be8199f770f78f0ba5541ddfff2c15ab60c398c_89f60286-3b79-4f77-84ca-12b6f927fb29.webp?v=1714969612","width":2000},{"alt":null,"id":23896169414755,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/72da131c9a421a8ba3683863a9653cfd7aa1e581_59362e0e-9ce5-4403-a54c-b541a0a1c66e.webp?v=1714969615"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/72da131c9a421a8ba3683863a9653cfd7aa1e581_59362e0e-9ce5-4403-a54c-b541a0a1c66e.webp?v=1714969615","width":2000},{"alt":null,"id":23896169873507,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d7bf5e42db22d3e713179cdcf75a34da60dad2c_ba39a903-962b-4825-83d2-ff850a2a0acb.webp?v=1714969617"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d7bf5e42db22d3e713179cdcf75a34da60dad2c_ba39a903-962b-4825-83d2-ff850a2a0acb.webp?v=1714969617","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41915617738851,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB17","requires_shipping":true,"taxable":true,"featured_image":{"id":31490758738019,"product_id":7415928094819,"position":4,"created_at":"2024-05-06T12:26:42+08:00","updated_at":"2024-05-06T12:26:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602","variant_ids":[41915617738851]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 鈦戰機-線條黑 - 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":"NPB0108624-PB17","featured_media":{"alt":null,"id":23896165580899,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41915617738851,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB17","requires_shipping":true,"taxable":true,"featured_image":{"id":31490758738019,"product_id":7415928094819,"position":4,"created_at":"2024-05-06T12:26:42+08:00","updated_at":"2024-05-06T12:26:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602","variant_ids":[41915617738851]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 鈦戰機-線條黑 - 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":"NPB0108624-PB17","featured_media":{"alt":null,"id":23896165580899,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a80ca3f40c419b08f829b86785b9be42e3ccbe83_de747fae-b8dc-46b0-914e-94a3f26821e5.webp?v=1714969602"}},"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: "停產" }