$product = {"id":7369220980835,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Snoopy 史努比 - 夏日活動","handle":"iphone-14-plus-mod-nx-magsafe-printable-pl61","description":null,"published_at":"2024-06-11T17:31:44+08:00","created_at":"2024-04-23T15:47:07+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Snoopy 史努比","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-snoopy","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-snoopy","Top50","type-Mod NX Printable MagSafe Printable"],"price":110000,"price_min":110000,"price_max":110000,"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":41793750564963,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31387105296483,"product_id":7369220980835,"position":7,"created_at":"2024-04-23T15:47:25+08:00","updated_at":"2024-04-23T15:47:25+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445","variant_ids":[41793750564963]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Snoopy 史努比 - 夏日活動 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PL61","featured_media":{"alt":null,"id":23789344063587,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/63ff6ca0b19caaaa33fc171cab1dc4dd2913d4f9_38d4100a-d9c7-4cf5-9f73-fa493a5b6afe.webp?v=1713858429","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc636391f02faf7ae4eff46e72ac5adc24098b6e_32ad2c64-7cf0-4f5b-bc02-784b975f922d.webp?v=1713858431","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/853f1e4856a31b7ee156a0b245e90d27ef5e6af7_2cb68ec2-ee55-4a05-9374-0aa4d9004261.webp?v=1713858434","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90a8781936b336a564d236f446333d47f1fd84b7_9c1ed20e-d2c7-4bcc-8c1c-903134268d2b.webp?v=1713858436","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/02c07a1623099b4bc99639b211bfe8c363ce4428_a63c0e17-60cd-4298-b0c4-6e2ab486f378.webp?v=1713858440","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3ed7bccd43df3e86780953476871281163115fb9_86f1163d-3f32-42fb-aacb-fdffa6bce8d9.webp?v=1713858442","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/049ff6ead4e9cd5b0f90f5612d278633184077e2_0967cdfb-678a-4408-8763-a52fb6e1bd0c.webp?v=1713858447","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581ec26567ef6a98ca2948a9261a3fcd55b7ad59_429a463f-dca9-441a-9ecb-a27f7aa7f64c.webp?v=1713858450","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/021df5f74eba3803caf5255cede97a5366a83c80_052baaa3-7740-4c6b-8686-cd5566817d8e.webp?v=1713858452"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/63ff6ca0b19caaaa33fc171cab1dc4dd2913d4f9_38d4100a-d9c7-4cf5-9f73-fa493a5b6afe.webp?v=1713858429","options":["color"],"media":[{"alt":null,"id":23789340164195,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/63ff6ca0b19caaaa33fc171cab1dc4dd2913d4f9_38d4100a-d9c7-4cf5-9f73-fa493a5b6afe.webp?v=1713858429"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/63ff6ca0b19caaaa33fc171cab1dc4dd2913d4f9_38d4100a-d9c7-4cf5-9f73-fa493a5b6afe.webp?v=1713858429","width":2000},{"alt":null,"id":23789340655715,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc636391f02faf7ae4eff46e72ac5adc24098b6e_32ad2c64-7cf0-4f5b-bc02-784b975f922d.webp?v=1713858431"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bc636391f02faf7ae4eff46e72ac5adc24098b6e_32ad2c64-7cf0-4f5b-bc02-784b975f922d.webp?v=1713858431","width":2000},{"alt":null,"id":23789341376611,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/853f1e4856a31b7ee156a0b245e90d27ef5e6af7_2cb68ec2-ee55-4a05-9374-0aa4d9004261.webp?v=1713858434"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/853f1e4856a31b7ee156a0b245e90d27ef5e6af7_2cb68ec2-ee55-4a05-9374-0aa4d9004261.webp?v=1713858434","width":2000},{"alt":null,"id":23789341966435,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90a8781936b336a564d236f446333d47f1fd84b7_9c1ed20e-d2c7-4bcc-8c1c-903134268d2b.webp?v=1713858436"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/90a8781936b336a564d236f446333d47f1fd84b7_9c1ed20e-d2c7-4bcc-8c1c-903134268d2b.webp?v=1713858436","width":2000},{"alt":null,"id":23789342720099,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/02c07a1623099b4bc99639b211bfe8c363ce4428_a63c0e17-60cd-4298-b0c4-6e2ab486f378.webp?v=1713858440"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/02c07a1623099b4bc99639b211bfe8c363ce4428_a63c0e17-60cd-4298-b0c4-6e2ab486f378.webp?v=1713858440","width":2000},{"alt":null,"id":23789343473763,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3ed7bccd43df3e86780953476871281163115fb9_86f1163d-3f32-42fb-aacb-fdffa6bce8d9.webp?v=1713858442"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3ed7bccd43df3e86780953476871281163115fb9_86f1163d-3f32-42fb-aacb-fdffa6bce8d9.webp?v=1713858442","width":2000},{"alt":null,"id":23789344063587,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445","width":2000},{"alt":null,"id":23789344620643,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/049ff6ead4e9cd5b0f90f5612d278633184077e2_0967cdfb-678a-4408-8763-a52fb6e1bd0c.webp?v=1713858447"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/049ff6ead4e9cd5b0f90f5612d278633184077e2_0967cdfb-678a-4408-8763-a52fb6e1bd0c.webp?v=1713858447","width":2000},{"alt":null,"id":23789345276003,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581ec26567ef6a98ca2948a9261a3fcd55b7ad59_429a463f-dca9-441a-9ecb-a27f7aa7f64c.webp?v=1713858450"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/581ec26567ef6a98ca2948a9261a3fcd55b7ad59_429a463f-dca9-441a-9ecb-a27f7aa7f64c.webp?v=1713858450","width":2000},{"alt":null,"id":23789345964131,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/021df5f74eba3803caf5255cede97a5366a83c80_052baaa3-7740-4c6b-8686-cd5566817d8e.webp?v=1713858452"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/021df5f74eba3803caf5255cede97a5366a83c80_052baaa3-7740-4c6b-8686-cd5566817d8e.webp?v=1713858452","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41793750564963,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31387105296483,"product_id":7369220980835,"position":7,"created_at":"2024-04-23T15:47:25+08:00","updated_at":"2024-04-23T15:47:25+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445","variant_ids":[41793750564963]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Snoopy 史努比 - 夏日活動 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PL61","featured_media":{"alt":null,"id":23789344063587,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41793750564963,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-PL61","requires_shipping":true,"taxable":true,"featured_image":{"id":31387105296483,"product_id":7369220980835,"position":7,"created_at":"2024-04-23T15:47:25+08:00","updated_at":"2024-04-23T15:47:25+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445","variant_ids":[41793750564963]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Snoopy 史努比 - 夏日活動 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-PL61","featured_media":{"alt":null,"id":23789344063587,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/50240537b277cb8095234a82ff91196056fcf384_1fafe15b-586e-4367-9afa-398500861ad4.webp?v=1713858445"}},"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: "停產" }