$product = {"id":7411245187171,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 願傷疤 有天開出花(泰國林地濫伐)","handle":"iphone-14-plus-mod-nx-magsafe-printable-af04","description":null,"published_at":"2024-06-11T17:39:46+08:00","created_at":"2024-05-04T23:52:40+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區Look","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-look","device-iPhone 14 Plus","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-look","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":41896458518627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31479946739811,"product_id":7411245187171,"position":5,"created_at":"2024-05-04T23:52:51+08:00","updated_at":"2024-05-04T23:52:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971","variant_ids":[41896458518627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 願傷疤 有天開出花(泰國林地濫伐) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF04","featured_media":{"alt":null,"id":23885197148259,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f989f54f032949c59e0f330fbc7f35a269e21727_0533683a-7862-4e28-a333-ebc1e27c56fd.webp?v=1714837962","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/88b0184c7297ee9479a3a443f5c2076bfd4a8152_59b0761d-541f-46ef-b80c-36e4bf9936d7.webp?v=1714837964","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89aa82622ff0a5880ae92d66e445b6fecc9a9a24_7de5b190-a03f-433e-bc31-1fadc7dea760.webp?v=1714837967","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d6b2910ec13010fcd8c6a84e299d17c4b3cdd8_4d0d9913-c8f9-4975-a0d6-97e75c21b5e4.webp?v=1714837969","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04562e0e33a534255a01011d6ab81398aaa83b9_7c404a32-95dc-4117-a8d7-ecd97e6ca482.webp?v=1714837974","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2704f899a33d68cd581d54b1bc65dd76435bbd_62dde471-bd34-42d9-a922-833a5d40f5cb.webp?v=1714837976","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f361fec0e8d88c0435a3192802e508b9ec1cd1f4_0635189d-78b7-4c05-be12-9fcc2555adb2.webp?v=1714837978","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5762d7c2ccae138645ee50cab0a0ab3829b61e81_53804870-941e-47b3-85bc-d35d4d7ffdbb.webp?v=1714837981","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d2bf0580174c456be2efb3117f0064f27d08a1_d67fbbc8-af72-4de7-b518-9b030a85f361.webp?v=1714837983"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f989f54f032949c59e0f330fbc7f35a269e21727_0533683a-7862-4e28-a333-ebc1e27c56fd.webp?v=1714837962","options":["color"],"media":[{"alt":null,"id":23885195083875,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f989f54f032949c59e0f330fbc7f35a269e21727_0533683a-7862-4e28-a333-ebc1e27c56fd.webp?v=1714837962"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f989f54f032949c59e0f330fbc7f35a269e21727_0533683a-7862-4e28-a333-ebc1e27c56fd.webp?v=1714837962","width":2000},{"alt":null,"id":23885195608163,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/88b0184c7297ee9479a3a443f5c2076bfd4a8152_59b0761d-541f-46ef-b80c-36e4bf9936d7.webp?v=1714837964"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/88b0184c7297ee9479a3a443f5c2076bfd4a8152_59b0761d-541f-46ef-b80c-36e4bf9936d7.webp?v=1714837964","width":2000},{"alt":null,"id":23885196034147,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89aa82622ff0a5880ae92d66e445b6fecc9a9a24_7de5b190-a03f-433e-bc31-1fadc7dea760.webp?v=1714837967"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/89aa82622ff0a5880ae92d66e445b6fecc9a9a24_7de5b190-a03f-433e-bc31-1fadc7dea760.webp?v=1714837967","width":2000},{"alt":null,"id":23885196591203,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d6b2910ec13010fcd8c6a84e299d17c4b3cdd8_4d0d9913-c8f9-4975-a0d6-97e75c21b5e4.webp?v=1714837969"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d6b2910ec13010fcd8c6a84e299d17c4b3cdd8_4d0d9913-c8f9-4975-a0d6-97e75c21b5e4.webp?v=1714837969","width":2000},{"alt":null,"id":23885197148259,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971","width":2000},{"alt":null,"id":23885197639779,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04562e0e33a534255a01011d6ab81398aaa83b9_7c404a32-95dc-4117-a8d7-ecd97e6ca482.webp?v=1714837974"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b04562e0e33a534255a01011d6ab81398aaa83b9_7c404a32-95dc-4117-a8d7-ecd97e6ca482.webp?v=1714837974","width":2000},{"alt":null,"id":23885198196835,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2704f899a33d68cd581d54b1bc65dd76435bbd_62dde471-bd34-42d9-a922-833a5d40f5cb.webp?v=1714837976"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3e2704f899a33d68cd581d54b1bc65dd76435bbd_62dde471-bd34-42d9-a922-833a5d40f5cb.webp?v=1714837976","width":2000},{"alt":null,"id":23885198688355,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f361fec0e8d88c0435a3192802e508b9ec1cd1f4_0635189d-78b7-4c05-be12-9fcc2555adb2.webp?v=1714837978"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f361fec0e8d88c0435a3192802e508b9ec1cd1f4_0635189d-78b7-4c05-be12-9fcc2555adb2.webp?v=1714837978","width":2000},{"alt":null,"id":23885199212643,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5762d7c2ccae138645ee50cab0a0ab3829b61e81_53804870-941e-47b3-85bc-d35d4d7ffdbb.webp?v=1714837981"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5762d7c2ccae138645ee50cab0a0ab3829b61e81_53804870-941e-47b3-85bc-d35d4d7ffdbb.webp?v=1714837981","width":2000},{"alt":null,"id":23885199769699,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d2bf0580174c456be2efb3117f0064f27d08a1_d67fbbc8-af72-4de7-b518-9b030a85f361.webp?v=1714837983"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a2d2bf0580174c456be2efb3117f0064f27d08a1_d67fbbc8-af72-4de7-b518-9b030a85f361.webp?v=1714837983","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41896458518627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31479946739811,"product_id":7411245187171,"position":5,"created_at":"2024-05-04T23:52:51+08:00","updated_at":"2024-05-04T23:52:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971","variant_ids":[41896458518627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 願傷疤 有天開出花(泰國林地濫伐) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF04","featured_media":{"alt":null,"id":23885197148259,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41896458518627,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-AF04","requires_shipping":true,"taxable":true,"featured_image":{"id":31479946739811,"product_id":7411245187171,"position":5,"created_at":"2024-05-04T23:52:51+08:00","updated_at":"2024-05-04T23:52:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971","variant_ids":[41896458518627]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - Look - 願傷疤 有天開出花(泰國林地濫伐) - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1380,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0126124-AF04","featured_media":{"alt":null,"id":23885197148259,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/31283bda19d3cc604647a4642c89cd299dfed7b9_db3ef285-5a29-400f-9805-33a3bb3e18b8.webp?v=1714837971"}},"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: "停產" }