$product = {"id":7416391467107,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Look - 大自然的傑作(黃石國家公園)","handle":"iphone-8-mod-nx-printable-af12","description":null,"published_at":"2024-06-11T16:57:47+08:00","created_at":"2024-05-06T14:47:46+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 8","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":41919236767843,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-AF12","requires_shipping":true,"taxable":true,"featured_image":{"id":31492015063139,"product_id":7416391467107,"position":7,"created_at":"2024-05-06T14:48:03+08:00","updated_at":"2024-05-06T14:48:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083","variant_ids":[41919236767843]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 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":"NPB0105424-AF12","featured_media":{"alt":null,"id":23897428885603,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/40741d986971aa4029ef5083d0c27b8769b78620_bbe344ba-7dea-4a50-bb06-db9529f23cad.webp?v=1714978068","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/745181a78aa58acf2c5d5e3ace6670590651c618_520e21a6-edbb-464a-8759-2e82c95dfa80.webp?v=1714978071","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/073bd50bdd5b1822b3059ff0f9ade89e8e1aa69a_757efeff-1c07-424a-9211-112309a50707.webp?v=1714978073","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd2286379e07fcb1411b44cc8d7d343e8ffb3418_c03c8294-aa14-429d-a6ba-3cbc0377d476.webp?v=1714978076","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2535818b911cedaf131557888fb50597f9a9b849_c165d048-c6ba-455f-93a3-3688a9e81fc3.webp?v=1714978078","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f3f4109c3666f8f6e7fe73ebb8e047b932fdeaf_339e060e-2a5c-45af-8d56-9fd26c82da34.webp?v=1714978081","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335c6f7c0069a3caeb1a0e0f843477d3e4cb6585_35a37c61-c238-4a20-91e0-b95e2e6e73e9.webp?v=1714978085","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d6652a3a190832f4103a296583e37e26c365c33a_99ead680-7d21-4fd4-b7e8-901bb6923a91.webp?v=1714978088","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e945d2fcd0238c115bd16d4dbb2d6e7a55e4a488_c647009c-63c5-48fa-8cea-d782d63b28a6.webp?v=1714978090"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/40741d986971aa4029ef5083d0c27b8769b78620_bbe344ba-7dea-4a50-bb06-db9529f23cad.webp?v=1714978068","options":["color"],"media":[{"alt":null,"id":23897425576035,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/40741d986971aa4029ef5083d0c27b8769b78620_bbe344ba-7dea-4a50-bb06-db9529f23cad.webp?v=1714978068"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/40741d986971aa4029ef5083d0c27b8769b78620_bbe344ba-7dea-4a50-bb06-db9529f23cad.webp?v=1714978068","width":2000},{"alt":null,"id":23897426296931,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/745181a78aa58acf2c5d5e3ace6670590651c618_520e21a6-edbb-464a-8759-2e82c95dfa80.webp?v=1714978071"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/745181a78aa58acf2c5d5e3ace6670590651c618_520e21a6-edbb-464a-8759-2e82c95dfa80.webp?v=1714978071","width":2000},{"alt":null,"id":23897426657379,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/073bd50bdd5b1822b3059ff0f9ade89e8e1aa69a_757efeff-1c07-424a-9211-112309a50707.webp?v=1714978073"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/073bd50bdd5b1822b3059ff0f9ade89e8e1aa69a_757efeff-1c07-424a-9211-112309a50707.webp?v=1714978073","width":2000},{"alt":null,"id":23897427443811,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd2286379e07fcb1411b44cc8d7d343e8ffb3418_c03c8294-aa14-429d-a6ba-3cbc0377d476.webp?v=1714978076"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cd2286379e07fcb1411b44cc8d7d343e8ffb3418_c03c8294-aa14-429d-a6ba-3cbc0377d476.webp?v=1714978076","width":2000},{"alt":null,"id":23897427902563,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2535818b911cedaf131557888fb50597f9a9b849_c165d048-c6ba-455f-93a3-3688a9e81fc3.webp?v=1714978078"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2535818b911cedaf131557888fb50597f9a9b849_c165d048-c6ba-455f-93a3-3688a9e81fc3.webp?v=1714978078","width":2000},{"alt":null,"id":23897428459619,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f3f4109c3666f8f6e7fe73ebb8e047b932fdeaf_339e060e-2a5c-45af-8d56-9fd26c82da34.webp?v=1714978081"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2f3f4109c3666f8f6e7fe73ebb8e047b932fdeaf_339e060e-2a5c-45af-8d56-9fd26c82da34.webp?v=1714978081","width":2000},{"alt":null,"id":23897428885603,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083","width":2000},{"alt":null,"id":23897429508195,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335c6f7c0069a3caeb1a0e0f843477d3e4cb6585_35a37c61-c238-4a20-91e0-b95e2e6e73e9.webp?v=1714978085"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/335c6f7c0069a3caeb1a0e0f843477d3e4cb6585_35a37c61-c238-4a20-91e0-b95e2e6e73e9.webp?v=1714978085","width":2000},{"alt":null,"id":23897429966947,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d6652a3a190832f4103a296583e37e26c365c33a_99ead680-7d21-4fd4-b7e8-901bb6923a91.webp?v=1714978088"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d6652a3a190832f4103a296583e37e26c365c33a_99ead680-7d21-4fd4-b7e8-901bb6923a91.webp?v=1714978088","width":2000},{"alt":null,"id":23897430392931,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e945d2fcd0238c115bd16d4dbb2d6e7a55e4a488_c647009c-63c5-48fa-8cea-d782d63b28a6.webp?v=1714978090"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e945d2fcd0238c115bd16d4dbb2d6e7a55e4a488_c647009c-63c5-48fa-8cea-d782d63b28a6.webp?v=1714978090","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41919236767843,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-AF12","requires_shipping":true,"taxable":true,"featured_image":{"id":31492015063139,"product_id":7416391467107,"position":7,"created_at":"2024-05-06T14:48:03+08:00","updated_at":"2024-05-06T14:48:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083","variant_ids":[41919236767843]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 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":"NPB0105424-AF12","featured_media":{"alt":null,"id":23897428885603,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41919236767843,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-AF12","requires_shipping":true,"taxable":true,"featured_image":{"id":31492015063139,"product_id":7416391467107,"position":7,"created_at":"2024-05-06T14:48:03+08:00","updated_at":"2024-05-06T14:48:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083","variant_ids":[41919236767843]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - 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":"NPB0105424-AF12","featured_media":{"alt":null,"id":23897428885603,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8ba945dc295d5db082bd112f37fbc747adeaf8b0_8d5d1e81-29ee-4905-82b7-7b4f39603672.webp?v=1714978083"}},"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: "停產" }