$product = {"id":7416386420835,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Care Bears - 粉紫樂園","handle":"iphone-8-mod-nx-printable-yb13","description":null,"published_at":"2024-06-11T16:57:39+08:00","created_at":"2024-05-06T14:46:51+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-Care Bears","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-carebears","device-iPhone 8","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-carebears","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":41919178113123,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB13","requires_shipping":true,"taxable":true,"featured_image":{"id":31492001464419,"product_id":7416386420835,"position":5,"created_at":"2024-05-06T14:47:03+08:00","updated_at":"2024-05-06T14:47:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023","variant_ids":[41919178113123]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Care Bears - 粉紫樂園 - 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":"NPB0105424-YB13","featured_media":{"alt":null,"id":23897415286883,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81a703a77df1957b39f7e8965e57bdadef28fd40_7d8e9634-abb0-4663-b8ea-128fe0b3d28f.webp?v=1714978014","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/74c90511a9ee85211c668f5b9ba2acc5ed55cb2c_8e7d39a9-473f-402d-9714-08b26bd555b8.webp?v=1714978016","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25b0878c102bc1c51f145b9c7cb6e8f2f68b6eb2_78a838ce-2f28-41b6-a54d-5fa861162de0.webp?v=1714978018","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a33f975236478dec441cb966c7302eac6c47763_2dbf58d2-8b81-4248-a764-c4571b2a30bd.webp?v=1714978021","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7c7013a790e6106ccb1d9838523613a2a005661_ef7cb369-9d1e-43e0-bbfc-064c5443e45d.webp?v=1714978026","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d503ecc1002af32c1d6737bddf8f359e85bce2d_8a70e949-2ba1-4b4d-bf32-3ac890205feb.webp?v=1714978028","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33499b4882d72d79c3440bbef21860ea1c74181d_8e2f709c-2d92-4bdd-a093-5c4bdcfb5a63.webp?v=1714978030","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/499cef70d972476f9c970566a6928f49f7edbd53_8fdf0c6c-4214-4ca7-9bbf-f64f8edf7fa0.webp?v=1714978032","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a4d98e77d01f9930afb5a5ef18215b6bb9ac70e8_809b8ca7-1840-4f50-81d4-c490060cb212.webp?v=1714978035"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81a703a77df1957b39f7e8965e57bdadef28fd40_7d8e9634-abb0-4663-b8ea-128fe0b3d28f.webp?v=1714978014","options":["color"],"media":[{"alt":null,"id":23897413320803,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81a703a77df1957b39f7e8965e57bdadef28fd40_7d8e9634-abb0-4663-b8ea-128fe0b3d28f.webp?v=1714978014"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/81a703a77df1957b39f7e8965e57bdadef28fd40_7d8e9634-abb0-4663-b8ea-128fe0b3d28f.webp?v=1714978014","width":2000},{"alt":null,"id":23897413714019,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/74c90511a9ee85211c668f5b9ba2acc5ed55cb2c_8e7d39a9-473f-402d-9714-08b26bd555b8.webp?v=1714978016"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/74c90511a9ee85211c668f5b9ba2acc5ed55cb2c_8e7d39a9-473f-402d-9714-08b26bd555b8.webp?v=1714978016","width":2000},{"alt":null,"id":23897414303843,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25b0878c102bc1c51f145b9c7cb6e8f2f68b6eb2_78a838ce-2f28-41b6-a54d-5fa861162de0.webp?v=1714978018"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/25b0878c102bc1c51f145b9c7cb6e8f2f68b6eb2_78a838ce-2f28-41b6-a54d-5fa861162de0.webp?v=1714978018","width":2000},{"alt":null,"id":23897414795363,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a33f975236478dec441cb966c7302eac6c47763_2dbf58d2-8b81-4248-a764-c4571b2a30bd.webp?v=1714978021"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a33f975236478dec441cb966c7302eac6c47763_2dbf58d2-8b81-4248-a764-c4571b2a30bd.webp?v=1714978021","width":2000},{"alt":null,"id":23897415286883,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023","width":2000},{"alt":null,"id":23897416040547,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7c7013a790e6106ccb1d9838523613a2a005661_ef7cb369-9d1e-43e0-bbfc-064c5443e45d.webp?v=1714978026"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d7c7013a790e6106ccb1d9838523613a2a005661_ef7cb369-9d1e-43e0-bbfc-064c5443e45d.webp?v=1714978026","width":2000},{"alt":null,"id":23897416794211,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d503ecc1002af32c1d6737bddf8f359e85bce2d_8a70e949-2ba1-4b4d-bf32-3ac890205feb.webp?v=1714978028"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/3d503ecc1002af32c1d6737bddf8f359e85bce2d_8a70e949-2ba1-4b4d-bf32-3ac890205feb.webp?v=1714978028","width":2000},{"alt":null,"id":23897417416803,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33499b4882d72d79c3440bbef21860ea1c74181d_8e2f709c-2d92-4bdd-a093-5c4bdcfb5a63.webp?v=1714978030"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/33499b4882d72d79c3440bbef21860ea1c74181d_8e2f709c-2d92-4bdd-a093-5c4bdcfb5a63.webp?v=1714978030","width":2000},{"alt":null,"id":23897417875555,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/499cef70d972476f9c970566a6928f49f7edbd53_8fdf0c6c-4214-4ca7-9bbf-f64f8edf7fa0.webp?v=1714978032"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/499cef70d972476f9c970566a6928f49f7edbd53_8fdf0c6c-4214-4ca7-9bbf-f64f8edf7fa0.webp?v=1714978032","width":2000},{"alt":null,"id":23897418563683,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a4d98e77d01f9930afb5a5ef18215b6bb9ac70e8_809b8ca7-1840-4f50-81d4-c490060cb212.webp?v=1714978035"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a4d98e77d01f9930afb5a5ef18215b6bb9ac70e8_809b8ca7-1840-4f50-81d4-c490060cb212.webp?v=1714978035","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41919178113123,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB13","requires_shipping":true,"taxable":true,"featured_image":{"id":31492001464419,"product_id":7416386420835,"position":5,"created_at":"2024-05-06T14:47:03+08:00","updated_at":"2024-05-06T14:47:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023","variant_ids":[41919178113123]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Care Bears - 粉紫樂園 - 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":"NPB0105424-YB13","featured_media":{"alt":null,"id":23897415286883,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41919178113123,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB13","requires_shipping":true,"taxable":true,"featured_image":{"id":31492001464419,"product_id":7416386420835,"position":5,"created_at":"2024-05-06T14:47:03+08:00","updated_at":"2024-05-06T14:47:03+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023","variant_ids":[41919178113123]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Care Bears - 粉紫樂園 - 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":"NPB0105424-YB13","featured_media":{"alt":null,"id":23897415286883,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c45dd4c42861a991b521abf7d68f60beebfd7efd_0daf8e36-a40b-47ff-bcdc-841193cc607c.webp?v=1714978023"}},"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: "停產" }