$product = {"id":7407670722659,"title":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - Weiweiboy - 可愛大王喜樂無常","handle":"iphone-14-plus-mod-nx-printable-eo03","description":null,"published_at":"2024-06-11T16:21:47+08:00","created_at":"2024-05-03T10:39:47+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 14 Plus","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":41877446328419,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-EO03","requires_shipping":true,"taxable":true,"featured_image":{"id":31470187380835,"product_id":7407670722659,"position":2,"created_at":"2024-05-03T10:39:53+08:00","updated_at":"2024-05-03T10:39:53+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993","variant_ids":[41877446328419]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 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":"NPB0126124-EO03","featured_media":{"alt":null,"id":23875090415715,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b307eaf25633a6ea27541d596d9d8b01a3824ef_fe0b5ebc-c89f-4c0f-a5c5-fc44c608e915.webp?v=1714703990","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb84c84b5add5d9ffc3b6d27dae4bfa5c4bda7cb_7556be01-b476-4b60-8e41-7c93e87f8501.webp?v=1714703996","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75926281d29fb869978d25ba3b259ee3362d677e_c179f761-56d2-47e0-8327-20db6b65edc7.webp?v=1714703999","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/97b2d69ffe74b2698f90c277c27b952a70d5cc7b_4bc40d19-658b-4886-8a57-4d8360006f68.webp?v=1714704001","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb1db497ffa87f5594daa038c20c8ecd994c945b_f7807a7e-3e94-4879-810b-1994219e1c31.webp?v=1714704004","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aadacd83bbed4a713c42317b915b0c9432aa6cef_71f2d7ff-5b14-41ec-9fa7-361cd45daa2e.webp?v=1714704006","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f84d60bd39cb1c880fb5a6d1d2eefeb233cb7d6_7456ff7e-f879-4284-9a4a-d54a42816844.webp?v=1714704009","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/38d181675fd38021ad7d91d6c8cc8852079274e5_fd031456-0f48-4aaa-8a8a-1604583584be.webp?v=1714704012","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5298009ef9de6b6a1815fc56370c8a10b6e06fa2_cdf62526-ea58-49c4-b969-93208ab10e44.webp?v=1714704014"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b307eaf25633a6ea27541d596d9d8b01a3824ef_fe0b5ebc-c89f-4c0f-a5c5-fc44c608e915.webp?v=1714703990","options":["color"],"media":[{"alt":null,"id":23875089596515,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b307eaf25633a6ea27541d596d9d8b01a3824ef_fe0b5ebc-c89f-4c0f-a5c5-fc44c608e915.webp?v=1714703990"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1b307eaf25633a6ea27541d596d9d8b01a3824ef_fe0b5ebc-c89f-4c0f-a5c5-fc44c608e915.webp?v=1714703990","width":2000},{"alt":null,"id":23875090415715,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993","width":2000},{"alt":null,"id":23875091202147,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb84c84b5add5d9ffc3b6d27dae4bfa5c4bda7cb_7556be01-b476-4b60-8e41-7c93e87f8501.webp?v=1714703996"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb84c84b5add5d9ffc3b6d27dae4bfa5c4bda7cb_7556be01-b476-4b60-8e41-7c93e87f8501.webp?v=1714703996","width":2000},{"alt":null,"id":23875092054115,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75926281d29fb869978d25ba3b259ee3362d677e_c179f761-56d2-47e0-8327-20db6b65edc7.webp?v=1714703999"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/75926281d29fb869978d25ba3b259ee3362d677e_c179f761-56d2-47e0-8327-20db6b65edc7.webp?v=1714703999","width":2000},{"alt":null,"id":23875093495907,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/97b2d69ffe74b2698f90c277c27b952a70d5cc7b_4bc40d19-658b-4886-8a57-4d8360006f68.webp?v=1714704001"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/97b2d69ffe74b2698f90c277c27b952a70d5cc7b_4bc40d19-658b-4886-8a57-4d8360006f68.webp?v=1714704001","width":2000},{"alt":null,"id":23875094151267,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb1db497ffa87f5594daa038c20c8ecd994c945b_f7807a7e-3e94-4879-810b-1994219e1c31.webp?v=1714704004"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fb1db497ffa87f5594daa038c20c8ecd994c945b_f7807a7e-3e94-4879-810b-1994219e1c31.webp?v=1714704004","width":2000},{"alt":null,"id":23875095134307,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aadacd83bbed4a713c42317b915b0c9432aa6cef_71f2d7ff-5b14-41ec-9fa7-361cd45daa2e.webp?v=1714704006"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/aadacd83bbed4a713c42317b915b0c9432aa6cef_71f2d7ff-5b14-41ec-9fa7-361cd45daa2e.webp?v=1714704006","width":2000},{"alt":null,"id":23875095887971,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f84d60bd39cb1c880fb5a6d1d2eefeb233cb7d6_7456ff7e-f879-4284-9a4a-d54a42816844.webp?v=1714704009"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f84d60bd39cb1c880fb5a6d1d2eefeb233cb7d6_7456ff7e-f879-4284-9a4a-d54a42816844.webp?v=1714704009","width":2000},{"alt":null,"id":23875096543331,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/38d181675fd38021ad7d91d6c8cc8852079274e5_fd031456-0f48-4aaa-8a8a-1604583584be.webp?v=1714704012"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/38d181675fd38021ad7d91d6c8cc8852079274e5_fd031456-0f48-4aaa-8a8a-1604583584be.webp?v=1714704012","width":2000},{"alt":null,"id":23875097395299,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5298009ef9de6b6a1815fc56370c8a10b6e06fa2_cdf62526-ea58-49c4-b969-93208ab10e44.webp?v=1714704014"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5298009ef9de6b6a1815fc56370c8a10b6e06fa2_cdf62526-ea58-49c4-b969-93208ab10e44.webp?v=1714704014","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41877446328419,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-EO03","requires_shipping":true,"taxable":true,"featured_image":{"id":31470187380835,"product_id":7407670722659,"position":2,"created_at":"2024-05-03T10:39:53+08:00","updated_at":"2024-05-03T10:39:53+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993","variant_ids":[41877446328419]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 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":"NPB0126124-EO03","featured_media":{"alt":null,"id":23875090415715,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41877446328419,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0126124-EO03","requires_shipping":true,"taxable":true,"featured_image":{"id":31470187380835,"product_id":7407670722659,"position":2,"created_at":"2024-05-03T10:39:53+08:00","updated_at":"2024-05-03T10:39:53+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993","variant_ids":[41877446328419]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 14 Plus - 【聯名設計款】 - 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":"NPB0126124-EO03","featured_media":{"alt":null,"id":23875090415715,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/033c62aa892a9dd0d37b0b89eb46c416783d1c24_6ee453b5-388f-43ee-a8d0-0642197608f4.webp?v=1714703993"}},"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: "停產" }