$product = {"id":7415971807331,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭狗狗","handle":"iphone-xs-max-mod-nx-printable-hq02","description":null,"published_at":"2024-06-11T16:49:18+08:00","created_at":"2024-05-06T12:34:33+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Pixel Jeff 皮傑","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-pixeljeff","device-iPhone XS Max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-pixeljeff","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":41916078260323,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-HQ02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490871984227,"product_id":7415971807331,"position":5,"created_at":"2024-05-06T12:34:47+08:00","updated_at":"2024-05-06T12:34:47+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087","variant_ids":[41916078260323]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭狗狗 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108624-HQ02","featured_media":{"alt":null,"id":23896278958179,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2acbd714e9cdf27e47e8574948acd1b0eab902ff_3229a4c4-15ac-4adb-b421-f43a15db5720.webp?v=1714970075","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec2e1e8e42be71e0ace68bd99aee23c5a4886cab_52b35bd9-0045-423b-963e-bd6206a1543d.webp?v=1714970078","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f24f2f37ab4688d774afbbf5218dcf67d7c791f1_8ddbf272-d172-4699-8c5e-e52db7ed4aa9.webp?v=1714970082","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1fc2dff5a6d8e85bc2c51d2e9d55b3b8aeb366e5_fbd0e934-6154-46d1-b96c-06d5c822c99f.webp?v=1714970085","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b21d84d603ca764e4053ccbc2331c7b6e695c41f_d991670e-a451-493a-ac89-21d9ed56dd22.webp?v=1714970089","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1aab2325b9edf2cd4d0ccb54d3e9bb6ca4946551_b193d7a5-9636-44a0-a790-849a200482b2.webp?v=1714970091","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/702488fcb3ce1b3ac405d28fdf82aeca2cda3844_fb338808-3915-493f-8da7-53e740ad3e84.webp?v=1714970094","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e1df4928ed0a5e2ec4b4a37b49a82a87b930ae3_a6ac1053-994a-4131-9174-059d3c12281e.webp?v=1714970096"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2acbd714e9cdf27e47e8574948acd1b0eab902ff_3229a4c4-15ac-4adb-b421-f43a15db5720.webp?v=1714970075","options":["color"],"media":[{"alt":null,"id":23896276566115,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2acbd714e9cdf27e47e8574948acd1b0eab902ff_3229a4c4-15ac-4adb-b421-f43a15db5720.webp?v=1714970075"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2acbd714e9cdf27e47e8574948acd1b0eab902ff_3229a4c4-15ac-4adb-b421-f43a15db5720.webp?v=1714970075","width":2000},{"alt":null,"id":23896276992099,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec2e1e8e42be71e0ace68bd99aee23c5a4886cab_52b35bd9-0045-423b-963e-bd6206a1543d.webp?v=1714970078"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec2e1e8e42be71e0ace68bd99aee23c5a4886cab_52b35bd9-0045-423b-963e-bd6206a1543d.webp?v=1714970078","width":2000},{"alt":null,"id":23896278138979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f24f2f37ab4688d774afbbf5218dcf67d7c791f1_8ddbf272-d172-4699-8c5e-e52db7ed4aa9.webp?v=1714970082"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f24f2f37ab4688d774afbbf5218dcf67d7c791f1_8ddbf272-d172-4699-8c5e-e52db7ed4aa9.webp?v=1714970082","width":2000},{"alt":null,"id":23896278466659,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1fc2dff5a6d8e85bc2c51d2e9d55b3b8aeb366e5_fbd0e934-6154-46d1-b96c-06d5c822c99f.webp?v=1714970085"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1fc2dff5a6d8e85bc2c51d2e9d55b3b8aeb366e5_fbd0e934-6154-46d1-b96c-06d5c822c99f.webp?v=1714970085","width":2000},{"alt":null,"id":23896278958179,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087","width":2000},{"alt":null,"id":23896279548003,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b21d84d603ca764e4053ccbc2331c7b6e695c41f_d991670e-a451-493a-ac89-21d9ed56dd22.webp?v=1714970089"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b21d84d603ca764e4053ccbc2331c7b6e695c41f_d991670e-a451-493a-ac89-21d9ed56dd22.webp?v=1714970089","width":2000},{"alt":null,"id":23896280006755,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1aab2325b9edf2cd4d0ccb54d3e9bb6ca4946551_b193d7a5-9636-44a0-a790-849a200482b2.webp?v=1714970091"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1aab2325b9edf2cd4d0ccb54d3e9bb6ca4946551_b193d7a5-9636-44a0-a790-849a200482b2.webp?v=1714970091","width":2000},{"alt":null,"id":23896280989795,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/702488fcb3ce1b3ac405d28fdf82aeca2cda3844_fb338808-3915-493f-8da7-53e740ad3e84.webp?v=1714970094"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/702488fcb3ce1b3ac405d28fdf82aeca2cda3844_fb338808-3915-493f-8da7-53e740ad3e84.webp?v=1714970094","width":2000},{"alt":null,"id":23896281383011,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e1df4928ed0a5e2ec4b4a37b49a82a87b930ae3_a6ac1053-994a-4131-9174-059d3c12281e.webp?v=1714970096"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7e1df4928ed0a5e2ec4b4a37b49a82a87b930ae3_a6ac1053-994a-4131-9174-059d3c12281e.webp?v=1714970096","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41916078260323,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-HQ02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490871984227,"product_id":7415971807331,"position":5,"created_at":"2024-05-06T12:34:47+08:00","updated_at":"2024-05-06T12:34:47+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087","variant_ids":[41916078260323]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭狗狗 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108624-HQ02","featured_media":{"alt":null,"id":23896278958179,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41916078260323,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-HQ02","requires_shipping":true,"taxable":true,"featured_image":{"id":31490871984227,"product_id":7415971807331,"position":5,"created_at":"2024-05-06T12:34:47+08:00","updated_at":"2024-05-06T12:34:47+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087","variant_ids":[41916078260323]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - Pixel Jeff 皮傑 - 街頭狗狗 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":860,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0108624-HQ02","featured_media":{"alt":null,"id":23896278958179,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a31fa6f6aea810ff17f6118d1a6ef1b5f8341016_218d09c6-d31b-4395-9ae5-7a0bcae7c2a4.webp?v=1714970087"}},"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: "停產" }