$product = {"id":7369184936035,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Snoopy 史努比 - 開心小花","handle":"iphone-8-mod-nx-printable-pl65","description":null,"published_at":"2024-06-11T16:14:02+08:00","created_at":"2024-04-23T15:40:06+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Snoopy 史努比","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-snoopy","device-iPhone 8","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-snoopy","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":41793391362147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PL65","requires_shipping":true,"taxable":true,"featured_image":{"id":31387012268131,"product_id":7369184936035,"position":9,"created_at":"2024-04-23T15:40:29+08:00","updated_at":"2024-04-23T15:40:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029","variant_ids":[41793391362147]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Snoopy 史努比 - 開心小花 - 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":"NPB0105424-PL65","featured_media":{"alt":null,"id":23789250773091,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3caaa15c843547c2656eeb5598d3270cfb43dfe_1e190c70-76d2-4704-854c-2ccd0a813dcb.webp?v=1713858008","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac95b05a8186a0346255dd558dc07fbf2fd1e02a_e86e005e-ba7d-4b35-b017-573164e4f128.webp?v=1713858011","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51d2f9d7c5db5a4a92ddee79a4bafabff3d56e2a_50982b98-5983-4854-9612-456aae7ba2a3.webp?v=1713858013","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c360c6e73d26e367981e05237e6e75d15d41fe46_4e64deeb-3e01-44bf-ab77-201e4113ba09.webp?v=1713858016","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/07bbbc7ad921cd70e1036729beec8c7fcd6409c6_e87d0ed3-c407-4b5d-826f-99eca721c12e.webp?v=1713858019","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cf0ef35cab855a036c08f1006a95dda34db0bec9_b78eb5ac-f94f-4850-905f-6caeaf2dec43.webp?v=1713858021","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1d43f486e127e269be62187cedfd198e824fadfd_6d35b3a9-004b-4af6-a869-29d8528627ca.webp?v=1713858023","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a1af2480de87dc58704ce27dc678bf5d3b6fbf9_f6ec89ca-f2fd-4f7b-a220-f0a1d3d991f8.webp?v=1713858026","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b8b7d40a02389bb6dcde0c3ab65e20afc21a8e9_03071001-8219-46e8-85fd-941279b0caa7.webp?v=1713858031"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3caaa15c843547c2656eeb5598d3270cfb43dfe_1e190c70-76d2-4704-854c-2ccd0a813dcb.webp?v=1713858008","options":["color"],"media":[{"alt":null,"id":23789245857891,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3caaa15c843547c2656eeb5598d3270cfb43dfe_1e190c70-76d2-4704-854c-2ccd0a813dcb.webp?v=1713858008"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b3caaa15c843547c2656eeb5598d3270cfb43dfe_1e190c70-76d2-4704-854c-2ccd0a813dcb.webp?v=1713858008","width":2000},{"alt":null,"id":23789246644323,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac95b05a8186a0346255dd558dc07fbf2fd1e02a_e86e005e-ba7d-4b35-b017-573164e4f128.webp?v=1713858011"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ac95b05a8186a0346255dd558dc07fbf2fd1e02a_e86e005e-ba7d-4b35-b017-573164e4f128.webp?v=1713858011","width":2000},{"alt":null,"id":23789247135843,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51d2f9d7c5db5a4a92ddee79a4bafabff3d56e2a_50982b98-5983-4854-9612-456aae7ba2a3.webp?v=1713858013"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/51d2f9d7c5db5a4a92ddee79a4bafabff3d56e2a_50982b98-5983-4854-9612-456aae7ba2a3.webp?v=1713858013","width":2000},{"alt":null,"id":23789247791203,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c360c6e73d26e367981e05237e6e75d15d41fe46_4e64deeb-3e01-44bf-ab77-201e4113ba09.webp?v=1713858016"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c360c6e73d26e367981e05237e6e75d15d41fe46_4e64deeb-3e01-44bf-ab77-201e4113ba09.webp?v=1713858016","width":2000},{"alt":null,"id":23789248348259,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/07bbbc7ad921cd70e1036729beec8c7fcd6409c6_e87d0ed3-c407-4b5d-826f-99eca721c12e.webp?v=1713858019"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/07bbbc7ad921cd70e1036729beec8c7fcd6409c6_e87d0ed3-c407-4b5d-826f-99eca721c12e.webp?v=1713858019","width":2000},{"alt":null,"id":23789249003619,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cf0ef35cab855a036c08f1006a95dda34db0bec9_b78eb5ac-f94f-4850-905f-6caeaf2dec43.webp?v=1713858021"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/cf0ef35cab855a036c08f1006a95dda34db0bec9_b78eb5ac-f94f-4850-905f-6caeaf2dec43.webp?v=1713858021","width":2000},{"alt":null,"id":23789249462371,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1d43f486e127e269be62187cedfd198e824fadfd_6d35b3a9-004b-4af6-a869-29d8528627ca.webp?v=1713858023"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1d43f486e127e269be62187cedfd198e824fadfd_6d35b3a9-004b-4af6-a869-29d8528627ca.webp?v=1713858023","width":2000},{"alt":null,"id":23789250216035,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a1af2480de87dc58704ce27dc678bf5d3b6fbf9_f6ec89ca-f2fd-4f7b-a220-f0a1d3d991f8.webp?v=1713858026"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2a1af2480de87dc58704ce27dc678bf5d3b6fbf9_f6ec89ca-f2fd-4f7b-a220-f0a1d3d991f8.webp?v=1713858026","width":2000},{"alt":null,"id":23789250773091,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029","width":2000},{"alt":null,"id":23789251657827,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b8b7d40a02389bb6dcde0c3ab65e20afc21a8e9_03071001-8219-46e8-85fd-941279b0caa7.webp?v=1713858031"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b8b7d40a02389bb6dcde0c3ab65e20afc21a8e9_03071001-8219-46e8-85fd-941279b0caa7.webp?v=1713858031","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41793391362147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PL65","requires_shipping":true,"taxable":true,"featured_image":{"id":31387012268131,"product_id":7369184936035,"position":9,"created_at":"2024-04-23T15:40:29+08:00","updated_at":"2024-04-23T15:40:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029","variant_ids":[41793391362147]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Snoopy 史努比 - 開心小花 - 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":"NPB0105424-PL65","featured_media":{"alt":null,"id":23789250773091,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41793391362147,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-PL65","requires_shipping":true,"taxable":true,"featured_image":{"id":31387012268131,"product_id":7369184936035,"position":9,"created_at":"2024-04-23T15:40:29+08:00","updated_at":"2024-04-23T15:40:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029","variant_ids":[41793391362147]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Snoopy 史努比 - 開心小花 - 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":"NPB0105424-PL65","featured_media":{"alt":null,"id":23789250773091,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d135b20372e53e83835f66d27eed52601ac65854_d757cb59-6fce-4284-bf35-9595a348590d.webp?v=1713858029"}},"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: "停產" }