$product = {"id":7408522362979,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Weiweiboy - 讓世界再可愛一點","handle":"iphone-12-pro-max-mod-nx-printable-eo02","description":null,"published_at":"2024-06-11T16:39:36+08:00","created_at":"2024-05-03T15:43:07+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Weiweiboy","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-weiweiboy","device-iPhone 12 pro max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-weiweiboy","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":41886442422371,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-EO02","requires_shipping":true,"taxable":true,"featured_image":{"id":31472492052579,"product_id":7408522362979,"position":2,"created_at":"2024-05-03T15:43:12+08:00","updated_at":"2024-05-03T15:43:12+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192","variant_ids":[41886442422371]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Weiweiboy - 讓世界再可愛一點 - 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":"NPB0118724-EO02","featured_media":{"alt":null,"id":23877409308771,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb7f834308cda80fe946015c4b0699c219952da5_7dadf247-87da-4d1c-8d6b-37803a853863.webp?v=1714722190","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dec35beae5ebafb2c6df4043d5b9fcf4eb47c384_23392aa4-f677-4c78-8293-9fcd554c9935.webp?v=1714722195","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d950692e9cf3658dbf841985efd3c066805bad_203a5d90-17cb-4c4c-a2f7-c78873f81a41.webp?v=1714722197","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec9c89458e93ef78bb7d8b45e512a2ca68a0f32e_6a290b88-a471-43a0-af96-2805ce46f45e.webp?v=1714722200","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e10ac013d1e3d326024330490f201e43dfcd6446_e1b50a60-2272-4935-859b-e868850c38f8.webp?v=1714722202","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1761a466c177e40afb4669cb552b0addbceebeb0_d22c43af-42f2-4244-8ada-805e9a1d7117.webp?v=1714722204","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb285e6ba461cea5254d47970a974db1ba421104_8d6acd2c-8dbc-47b5-b861-fe909e9b789b.webp?v=1714722207","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71c8e93b628a4fd21ad6d655be91b937de983f64_901c8dd0-cbb8-44fd-aa26-609252e7ec4b.webp?v=1714722209","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c8ea337ee8d8820cbfcf7dc5f8deceaa23c6ba9_b73362e3-6e43-4944-b58e-f566184336c2.webp?v=1714722212"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb7f834308cda80fe946015c4b0699c219952da5_7dadf247-87da-4d1c-8d6b-37803a853863.webp?v=1714722190","options":["color"],"media":[{"alt":null,"id":23877408850019,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb7f834308cda80fe946015c4b0699c219952da5_7dadf247-87da-4d1c-8d6b-37803a853863.webp?v=1714722190"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb7f834308cda80fe946015c4b0699c219952da5_7dadf247-87da-4d1c-8d6b-37803a853863.webp?v=1714722190","width":2000},{"alt":null,"id":23877409308771,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192","width":2000},{"alt":null,"id":23877409800291,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dec35beae5ebafb2c6df4043d5b9fcf4eb47c384_23392aa4-f677-4c78-8293-9fcd554c9935.webp?v=1714722195"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dec35beae5ebafb2c6df4043d5b9fcf4eb47c384_23392aa4-f677-4c78-8293-9fcd554c9935.webp?v=1714722195","width":2000},{"alt":null,"id":23877410259043,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d950692e9cf3658dbf841985efd3c066805bad_203a5d90-17cb-4c4c-a2f7-c78873f81a41.webp?v=1714722197"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46d950692e9cf3658dbf841985efd3c066805bad_203a5d90-17cb-4c4c-a2f7-c78873f81a41.webp?v=1714722197","width":2000},{"alt":null,"id":23877410783331,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec9c89458e93ef78bb7d8b45e512a2ca68a0f32e_6a290b88-a471-43a0-af96-2805ce46f45e.webp?v=1714722200"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/ec9c89458e93ef78bb7d8b45e512a2ca68a0f32e_6a290b88-a471-43a0-af96-2805ce46f45e.webp?v=1714722200","width":2000},{"alt":null,"id":23877411340387,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e10ac013d1e3d326024330490f201e43dfcd6446_e1b50a60-2272-4935-859b-e868850c38f8.webp?v=1714722202"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e10ac013d1e3d326024330490f201e43dfcd6446_e1b50a60-2272-4935-859b-e868850c38f8.webp?v=1714722202","width":2000},{"alt":null,"id":23877411831907,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1761a466c177e40afb4669cb552b0addbceebeb0_d22c43af-42f2-4244-8ada-805e9a1d7117.webp?v=1714722204"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1761a466c177e40afb4669cb552b0addbceebeb0_d22c43af-42f2-4244-8ada-805e9a1d7117.webp?v=1714722204","width":2000},{"alt":null,"id":23877412290659,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb285e6ba461cea5254d47970a974db1ba421104_8d6acd2c-8dbc-47b5-b861-fe909e9b789b.webp?v=1714722207"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/bb285e6ba461cea5254d47970a974db1ba421104_8d6acd2c-8dbc-47b5-b861-fe909e9b789b.webp?v=1714722207","width":2000},{"alt":null,"id":23877412847715,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71c8e93b628a4fd21ad6d655be91b937de983f64_901c8dd0-cbb8-44fd-aa26-609252e7ec4b.webp?v=1714722209"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/71c8e93b628a4fd21ad6d655be91b937de983f64_901c8dd0-cbb8-44fd-aa26-609252e7ec4b.webp?v=1714722209","width":2000},{"alt":null,"id":23877413404771,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c8ea337ee8d8820cbfcf7dc5f8deceaa23c6ba9_b73362e3-6e43-4944-b58e-f566184336c2.webp?v=1714722212"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c8ea337ee8d8820cbfcf7dc5f8deceaa23c6ba9_b73362e3-6e43-4944-b58e-f566184336c2.webp?v=1714722212","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41886442422371,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-EO02","requires_shipping":true,"taxable":true,"featured_image":{"id":31472492052579,"product_id":7408522362979,"position":2,"created_at":"2024-05-03T15:43:12+08:00","updated_at":"2024-05-03T15:43:12+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192","variant_ids":[41886442422371]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Weiweiboy - 讓世界再可愛一點 - 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":"NPB0118724-EO02","featured_media":{"alt":null,"id":23877409308771,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41886442422371,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-EO02","requires_shipping":true,"taxable":true,"featured_image":{"id":31472492052579,"product_id":7408522362979,"position":2,"created_at":"2024-05-03T15:43:12+08:00","updated_at":"2024-05-03T15:43:12+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192","variant_ids":[41886442422371]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - Weiweiboy - 讓世界再可愛一點 - 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":"NPB0118724-EO02","featured_media":{"alt":null,"id":23877409308771,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/4583296a582b8db7fb237dc7e3e1bd737dba6bcd_e0ffa4a9-a724-447a-99ee-3ced6b115183.webp?v=1714722192"}},"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: "停產" }