$product = {"id":7407685632099,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - Look - 大自然的傑作(優勝美地國家公園)","handle":"iphone-14-plus-mod-nx-printable-af13","description":null,"published_at":"2024-06-11T16:21:57+08:00","created_at":"2024-05-03T10:41:19+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Look","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-look","device-iPhone 14 Plus","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-look","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":41877625536611,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-AF13","requires_shipping":true,"taxable":true,"featured_image":{"id":31470218018915,"product_id":7407685632099,"position":8,"created_at":"2024-05-03T10:41:40+08:00","updated_at":"2024-05-03T10:41:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100","variant_ids":[41877625536611]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - Look - 大自然的傑作(優勝美地國家公園) - 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":"NPB0126124-AF13","featured_media":{"alt":null,"id":23875121053795,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdfd580966458c15c7a0634c0c5ab7b36f743af9_7d6f98c6-486b-4bc0-b620-0f98116868e9.webp?v=1714704082","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7247c2f160628e349befc125ff4d2f83c13be78_060c40e0-3bb5-4425-b42f-8e9d856e9ada.webp?v=1714704084","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a83e53dc679d934917732275b842abedfb69d8a0_f1f92d47-cc6f-4be8-8d6c-ec669e9e47d9.webp?v=1714704087","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f99c320e62399a02e4ee251e8307ed25b2ed1c8_a3125a4b-d4bc-4017-893d-882e1408dcf6.webp?v=1714704090","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e8bef5de4930e95e1b826e79f8d362879a48fc7_efb50517-9b08-4f87-a3d7-afaf5d04023f.webp?v=1714704092","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dc717a237c52c58a9c2b1853bf2381c86c35cce0_500cf064-2da3-45b6-8335-edb530c565b8.webp?v=1714704095","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9033e13837f137b041fad95600c57ec4d3664c2_1fcd3bcc-9fac-4dc0-a050-7132ba3fd9f5.webp?v=1714704097","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6690b8720e47d23d445d21d580f28490bbb6faf0_c5e63ee9-66e6-4a4d-a833-e93f738c775d.webp?v=1714704102","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0bd73f74fd285a572442146288c8c98daf5feccf_5b037449-b3ad-4523-a9bd-4fea0fb6b951.webp?v=1714704105"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdfd580966458c15c7a0634c0c5ab7b36f743af9_7d6f98c6-486b-4bc0-b620-0f98116868e9.webp?v=1714704082","options":["color"],"media":[{"alt":null,"id":23875115024483,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdfd580966458c15c7a0634c0c5ab7b36f743af9_7d6f98c6-486b-4bc0-b620-0f98116868e9.webp?v=1714704082"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fdfd580966458c15c7a0634c0c5ab7b36f743af9_7d6f98c6-486b-4bc0-b620-0f98116868e9.webp?v=1714704082","width":2000},{"alt":null,"id":23875115876451,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7247c2f160628e349befc125ff4d2f83c13be78_060c40e0-3bb5-4425-b42f-8e9d856e9ada.webp?v=1714704084"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7247c2f160628e349befc125ff4d2f83c13be78_060c40e0-3bb5-4425-b42f-8e9d856e9ada.webp?v=1714704084","width":2000},{"alt":null,"id":23875116531811,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a83e53dc679d934917732275b842abedfb69d8a0_f1f92d47-cc6f-4be8-8d6c-ec669e9e47d9.webp?v=1714704087"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a83e53dc679d934917732275b842abedfb69d8a0_f1f92d47-cc6f-4be8-8d6c-ec669e9e47d9.webp?v=1714704087","width":2000},{"alt":null,"id":23875117252707,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f99c320e62399a02e4ee251e8307ed25b2ed1c8_a3125a4b-d4bc-4017-893d-882e1408dcf6.webp?v=1714704090"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5f99c320e62399a02e4ee251e8307ed25b2ed1c8_a3125a4b-d4bc-4017-893d-882e1408dcf6.webp?v=1714704090","width":2000},{"alt":null,"id":23875117842531,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e8bef5de4930e95e1b826e79f8d362879a48fc7_efb50517-9b08-4f87-a3d7-afaf5d04023f.webp?v=1714704092"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9e8bef5de4930e95e1b826e79f8d362879a48fc7_efb50517-9b08-4f87-a3d7-afaf5d04023f.webp?v=1714704092","width":2000},{"alt":null,"id":23875119710307,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dc717a237c52c58a9c2b1853bf2381c86c35cce0_500cf064-2da3-45b6-8335-edb530c565b8.webp?v=1714704095"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dc717a237c52c58a9c2b1853bf2381c86c35cce0_500cf064-2da3-45b6-8335-edb530c565b8.webp?v=1714704095","width":2000},{"alt":null,"id":23875120398435,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9033e13837f137b041fad95600c57ec4d3664c2_1fcd3bcc-9fac-4dc0-a050-7132ba3fd9f5.webp?v=1714704097"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a9033e13837f137b041fad95600c57ec4d3664c2_1fcd3bcc-9fac-4dc0-a050-7132ba3fd9f5.webp?v=1714704097","width":2000},{"alt":null,"id":23875121053795,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100","width":2000},{"alt":null,"id":23875121676387,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6690b8720e47d23d445d21d580f28490bbb6faf0_c5e63ee9-66e6-4a4d-a833-e93f738c775d.webp?v=1714704102"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6690b8720e47d23d445d21d580f28490bbb6faf0_c5e63ee9-66e6-4a4d-a833-e93f738c775d.webp?v=1714704102","width":2000},{"alt":null,"id":23875122364515,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0bd73f74fd285a572442146288c8c98daf5feccf_5b037449-b3ad-4523-a9bd-4fea0fb6b951.webp?v=1714704105"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0bd73f74fd285a572442146288c8c98daf5feccf_5b037449-b3ad-4523-a9bd-4fea0fb6b951.webp?v=1714704105","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41877625536611,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-AF13","requires_shipping":true,"taxable":true,"featured_image":{"id":31470218018915,"product_id":7407685632099,"position":8,"created_at":"2024-05-03T10:41:40+08:00","updated_at":"2024-05-03T10:41:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100","variant_ids":[41877625536611]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - Look - 大自然的傑作(優勝美地國家公園) - 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":"NPB0126124-AF13","featured_media":{"alt":null,"id":23875121053795,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41877625536611,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-AF13","requires_shipping":true,"taxable":true,"featured_image":{"id":31470218018915,"product_id":7407685632099,"position":8,"created_at":"2024-05-03T10:41:40+08:00","updated_at":"2024-05-03T10:41:40+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100","variant_ids":[41877625536611]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - Look - 大自然的傑作(優勝美地國家公園) - 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":"NPB0126124-AF13","featured_media":{"alt":null,"id":23875121053795,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/590883b29538cd2abbd5ac3ae47f3c4365eb2c95_6ae50534-7c0d-4bd6-886e-beacf0a09f43.webp?v=1714704100"}},"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: "停產" }