$product = {"id":7415925964899,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具3","handle":"iphone-xs-max-mod-nx-printable-pb26","description":null,"published_at":"2024-06-11T16:48:06+08:00","created_at":"2024-05-06T12:26:07+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":41915595161699,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB26","requires_shipping":true,"taxable":true,"featured_image":{"id":31490754216035,"product_id":7415925964899,"position":6,"created_at":"2024-05-06T12:26:22+08:00","updated_at":"2024-05-06T12:26:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582","variant_ids":[41915595161699]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具3 - 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-PB26","featured_media":{"alt":null,"id":23896160993379,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1877826b9fb7d9ecc79b39542a41b14cb674e29_575140c2-0ed9-42cd-b607-abf6c19c2c4b.webp?v=1714969569","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf4ff376119eb77b9715e5f049928b403e3595c_3ceecba3-38fa-4278-a72c-615ce14ae34b.webp?v=1714969572","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/410b45bb7b75919dd7fd79a97eb582ee5def8b01_81a1882d-d842-442b-a509-b11bdd96cfcc.webp?v=1714969574","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8a55c43a89dc922814a763953c09ad508f81b6a_14865877-b959-4593-8ba3-514f397b755a.webp?v=1714969577","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab9dc64a36afeefc7db9c6de4c88e8a17c05024_5c19774d-4e62-460f-aad3-1dd57a6e55d5.webp?v=1714969579","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cc21c2f61b4fda3285683510d88a0a944600916c_f9a1d9e6-8bf4-4b0b-8253-b39e533ac708.webp?v=1714969585","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b5d168d04970cddbb07c1374305546238fae336_f4342f48-0ba8-4e3e-a4be-ee370c26cfe5.webp?v=1714969587","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d29a92ec3fae81441c7600dbd1651a4facff0bdc_ac4beef9-e144-47d3-8233-45bb9315caf5.webp?v=1714969591","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a972fa39ade89bac5169d74f68208b00d484b924_e79f461f-5631-4179-9861-f0e162b9b96a.webp?v=1714969593"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1877826b9fb7d9ecc79b39542a41b14cb674e29_575140c2-0ed9-42cd-b607-abf6c19c2c4b.webp?v=1714969569","options":["color"],"media":[{"alt":null,"id":23896157519971,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1877826b9fb7d9ecc79b39542a41b14cb674e29_575140c2-0ed9-42cd-b607-abf6c19c2c4b.webp?v=1714969569"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e1877826b9fb7d9ecc79b39542a41b14cb674e29_575140c2-0ed9-42cd-b607-abf6c19c2c4b.webp?v=1714969569","width":2000},{"alt":null,"id":23896158077027,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf4ff376119eb77b9715e5f049928b403e3595c_3ceecba3-38fa-4278-a72c-615ce14ae34b.webp?v=1714969572"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/edf4ff376119eb77b9715e5f049928b403e3595c_3ceecba3-38fa-4278-a72c-615ce14ae34b.webp?v=1714969572","width":2000},{"alt":null,"id":23896158928995,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/410b45bb7b75919dd7fd79a97eb582ee5def8b01_81a1882d-d842-442b-a509-b11bdd96cfcc.webp?v=1714969574"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/410b45bb7b75919dd7fd79a97eb582ee5def8b01_81a1882d-d842-442b-a509-b11bdd96cfcc.webp?v=1714969574","width":2000},{"alt":null,"id":23896159780963,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8a55c43a89dc922814a763953c09ad508f81b6a_14865877-b959-4593-8ba3-514f397b755a.webp?v=1714969577"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f8a55c43a89dc922814a763953c09ad508f81b6a_14865877-b959-4593-8ba3-514f397b755a.webp?v=1714969577","width":2000},{"alt":null,"id":23896160272483,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab9dc64a36afeefc7db9c6de4c88e8a17c05024_5c19774d-4e62-460f-aad3-1dd57a6e55d5.webp?v=1714969579"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5ab9dc64a36afeefc7db9c6de4c88e8a17c05024_5c19774d-4e62-460f-aad3-1dd57a6e55d5.webp?v=1714969579","width":2000},{"alt":null,"id":23896160993379,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582","width":2000},{"alt":null,"id":23896161419363,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cc21c2f61b4fda3285683510d88a0a944600916c_f9a1d9e6-8bf4-4b0b-8253-b39e533ac708.webp?v=1714969585"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cc21c2f61b4fda3285683510d88a0a944600916c_f9a1d9e6-8bf4-4b0b-8253-b39e533ac708.webp?v=1714969585","width":2000},{"alt":null,"id":23896162041955,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b5d168d04970cddbb07c1374305546238fae336_f4342f48-0ba8-4e3e-a4be-ee370c26cfe5.webp?v=1714969587"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b5d168d04970cddbb07c1374305546238fae336_f4342f48-0ba8-4e3e-a4be-ee370c26cfe5.webp?v=1714969587","width":2000},{"alt":null,"id":23896162664547,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d29a92ec3fae81441c7600dbd1651a4facff0bdc_ac4beef9-e144-47d3-8233-45bb9315caf5.webp?v=1714969591"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d29a92ec3fae81441c7600dbd1651a4facff0bdc_ac4beef9-e144-47d3-8233-45bb9315caf5.webp?v=1714969591","width":2000},{"alt":null,"id":23896163549283,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a972fa39ade89bac5169d74f68208b00d484b924_e79f461f-5631-4179-9861-f0e162b9b96a.webp?v=1714969593"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a972fa39ade89bac5169d74f68208b00d484b924_e79f461f-5631-4179-9861-f0e162b9b96a.webp?v=1714969593","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41915595161699,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB26","requires_shipping":true,"taxable":true,"featured_image":{"id":31490754216035,"product_id":7415925964899,"position":6,"created_at":"2024-05-06T12:26:22+08:00","updated_at":"2024-05-06T12:26:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582","variant_ids":[41915595161699]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具3 - 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-PB26","featured_media":{"alt":null,"id":23896160993379,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41915595161699,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB26","requires_shipping":true,"taxable":true,"featured_image":{"id":31490754216035,"product_id":7415925964899,"position":6,"created_at":"2024-05-06T12:26:22+08:00","updated_at":"2024-05-06T12:26:22+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582","variant_ids":[41915595161699]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - POP全載具3 - 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-PB26","featured_media":{"alt":null,"id":23896160993379,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d65c1413cd49e68fb52aa383cde256fe5c8a93a4_8fd027df-3fc2-43d7-ba98-48e2ec7d04db.webp?v=1714969582"}},"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: "停產" }