$product = {"id":7411369443427,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 【獨家設計款】 - 窯花","handle":"iphone-14-plus-mod-nx-magsafe-printable-gd14","description":null,"published_at":"2024-06-11T17:43:06+08:00","created_at":"2024-05-05T00:16:21+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"MOD NX MagSafe 客製化","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","device-iPhone 14 Plus","discountable-item","member","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller","reseller-modnx-magsafe-chi-po-lin-series","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":41898021847139,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-GD14","requires_shipping":true,"taxable":true,"featured_image":{"id":31480250335331,"product_id":7411369443427,"position":3,"created_at":"2024-05-05T00:16:30+08:00","updated_at":"2024-05-05T00:16:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390","variant_ids":[41898021847139]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 【獨家設計款】 - 窯花 - 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-GD14","featured_media":{"alt":null,"id":23885501562979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/174131ccc3e54f5d42b8f0cee0020744d5092687_c7a439db-e44d-4bc2-a5d4-1f7a4d4bf151.webp?v=1714839384","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aad16629ed658c0751cac7accd7e6b8720deb5e_c9010075-fa14-4fbc-a230-a0df8ecfc34e.webp?v=1714839387","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59cc8565d8aa09c00e322251b338e6a208743500_1cacfb80-7b69-4910-8fba-b38c69e785d6.webp?v=1714839392","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6026175be10b63c1a1605b6f1fc933af2d332191_b3d0b8c1-3845-46eb-b86c-45992fdc4bf8.webp?v=1714839394","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21930180bf9af485bfc3a1c77bc1e767755fc660_8a7b895c-14bb-4bf3-a47d-8e324a72880a.webp?v=1714839397","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe183478f815279660705c119df538ea0216cf53_91e74153-44a5-4352-a59c-3c9ffb604b66.webp?v=1714839399","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84d540e4fdde77883ccbcf4e40fadfeae4007ea8_7ba2b54d-867e-4230-b1e9-e9a2daf41ebc.webp?v=1714839401","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a9da4c0160d7297ca61207ca2218c6428c3823a_7efc6f75-9f33-49ad-a72f-4dd10de301f3.webp?v=1714839404","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/802349bbcdd0a1b6b9a51a45cfd556d60f067762_5a74cd57-fb55-4156-8c14-00544c262045.webp?v=1714839406"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/174131ccc3e54f5d42b8f0cee0020744d5092687_c7a439db-e44d-4bc2-a5d4-1f7a4d4bf151.webp?v=1714839384","options":["color"],"media":[{"alt":null,"id":23885500285027,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/174131ccc3e54f5d42b8f0cee0020744d5092687_c7a439db-e44d-4bc2-a5d4-1f7a4d4bf151.webp?v=1714839384"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/174131ccc3e54f5d42b8f0cee0020744d5092687_c7a439db-e44d-4bc2-a5d4-1f7a4d4bf151.webp?v=1714839384","width":2000},{"alt":null,"id":23885500907619,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aad16629ed658c0751cac7accd7e6b8720deb5e_c9010075-fa14-4fbc-a230-a0df8ecfc34e.webp?v=1714839387"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0aad16629ed658c0751cac7accd7e6b8720deb5e_c9010075-fa14-4fbc-a230-a0df8ecfc34e.webp?v=1714839387","width":2000},{"alt":null,"id":23885501562979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390","width":2000},{"alt":null,"id":23885502087267,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59cc8565d8aa09c00e322251b338e6a208743500_1cacfb80-7b69-4910-8fba-b38c69e785d6.webp?v=1714839392"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59cc8565d8aa09c00e322251b338e6a208743500_1cacfb80-7b69-4910-8fba-b38c69e785d6.webp?v=1714839392","width":2000},{"alt":null,"id":23885502644323,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6026175be10b63c1a1605b6f1fc933af2d332191_b3d0b8c1-3845-46eb-b86c-45992fdc4bf8.webp?v=1714839394"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/6026175be10b63c1a1605b6f1fc933af2d332191_b3d0b8c1-3845-46eb-b86c-45992fdc4bf8.webp?v=1714839394","width":2000},{"alt":null,"id":23885503234147,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21930180bf9af485bfc3a1c77bc1e767755fc660_8a7b895c-14bb-4bf3-a47d-8e324a72880a.webp?v=1714839397"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/21930180bf9af485bfc3a1c77bc1e767755fc660_8a7b895c-14bb-4bf3-a47d-8e324a72880a.webp?v=1714839397","width":2000},{"alt":null,"id":23885503791203,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe183478f815279660705c119df538ea0216cf53_91e74153-44a5-4352-a59c-3c9ffb604b66.webp?v=1714839399"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fe183478f815279660705c119df538ea0216cf53_91e74153-44a5-4352-a59c-3c9ffb604b66.webp?v=1714839399","width":2000},{"alt":null,"id":23885504315491,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84d540e4fdde77883ccbcf4e40fadfeae4007ea8_7ba2b54d-867e-4230-b1e9-e9a2daf41ebc.webp?v=1714839401"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/84d540e4fdde77883ccbcf4e40fadfeae4007ea8_7ba2b54d-867e-4230-b1e9-e9a2daf41ebc.webp?v=1714839401","width":2000},{"alt":null,"id":23885504872547,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a9da4c0160d7297ca61207ca2218c6428c3823a_7efc6f75-9f33-49ad-a72f-4dd10de301f3.webp?v=1714839404"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8a9da4c0160d7297ca61207ca2218c6428c3823a_7efc6f75-9f33-49ad-a72f-4dd10de301f3.webp?v=1714839404","width":2000},{"alt":null,"id":23885505462371,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/802349bbcdd0a1b6b9a51a45cfd556d60f067762_5a74cd57-fb55-4156-8c14-00544c262045.webp?v=1714839406"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/802349bbcdd0a1b6b9a51a45cfd556d60f067762_5a74cd57-fb55-4156-8c14-00544c262045.webp?v=1714839406","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41898021847139,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-GD14","requires_shipping":true,"taxable":true,"featured_image":{"id":31480250335331,"product_id":7411369443427,"position":3,"created_at":"2024-05-05T00:16:30+08:00","updated_at":"2024-05-05T00:16:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390","variant_ids":[41898021847139]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 【獨家設計款】 - 窯花 - 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-GD14","featured_media":{"alt":null,"id":23885501562979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41898021847139,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0126124-GD14","requires_shipping":true,"taxable":true,"featured_image":{"id":31480250335331,"product_id":7411369443427,"position":3,"created_at":"2024-05-05T00:16:30+08:00","updated_at":"2024-05-05T00:16:30+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390","variant_ids":[41898021847139]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 14 Plus - 【獨家設計款】 - 窯花 - 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-GD14","featured_media":{"alt":null,"id":23885501562979,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f3270fbdadc0aace963ae3ec60047ebdd585c945_dae83fa1-1cf2-4680-ad6b-74e17ef5338a.webp?v=1714839390"}},"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: "停產" }