$product = {"id":7416369447011,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 The Powerpuff Girls - 愛心圖案","handle":"iphone-8-mod-nx-printable-sr09","description":null,"published_at":"2024-06-11T16:57:11+08:00","created_at":"2024-05-06T14:43:41+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-The Powerpuff Girls","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-the-power-puff-girls","device-iPhone 8","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-the-power-puff-girls","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":41918993301603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-SR09","requires_shipping":true,"taxable":true,"featured_image":{"id":31491959554147,"product_id":7416369447011,"position":4,"created_at":"2024-05-06T14:43:51+08:00","updated_at":"2024-05-06T14:43:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831","variant_ids":[41918993301603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 The Powerpuff Girls - 愛心圖案 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0105424-SR09","featured_media":{"alt":null,"id":23897372819555,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bad28e53da8b657e2534f32f3a7eeca001ceb60_e97c7fe6-104a-4ab2-a336-cd249089d919.webp?v=1714977823","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9fefa4a6d524128bf97ba3677c3b1d4441ffe2d_e8bb698a-12cf-441d-940e-369e426af3b6.webp?v=1714977826","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/adab8aa2438533cc35f87f106040e1ae77b8dea0_1ebc09d4-ed25-4a74-8ce3-187c8ffc2bac.webp?v=1714977828","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f6d4991675afbf09c819f58759a31023a32fd656_6ba7a37b-77c0-4c36-82f2-1907fde10584.webp?v=1714977833","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b6f36f0358570a98d181ceca887b986293bd1fb_5976ad43-102b-42cf-8c6b-fac2592e4f02.webp?v=1714977835","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dee5a5ef958bc9f5d7a78ea2ea2c45921ad4cff_702826f2-290c-4c6d-a6a0-4ac717c95938.webp?v=1714977838","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9df95a61ffa1480346dfa09470a3d55de2340b8_b80a1fbb-94f0-432f-b642-7c9452ed6212.webp?v=1714977840","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/48ba3457a672d4521b6b7d2dcb043d2a83e1b571_f78365b4-c399-4f45-b0e2-75b40c27476c.webp?v=1714977845"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bad28e53da8b657e2534f32f3a7eeca001ceb60_e97c7fe6-104a-4ab2-a336-cd249089d919.webp?v=1714977823","options":["color"],"media":[{"alt":null,"id":23897371377763,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bad28e53da8b657e2534f32f3a7eeca001ceb60_e97c7fe6-104a-4ab2-a336-cd249089d919.webp?v=1714977823"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bad28e53da8b657e2534f32f3a7eeca001ceb60_e97c7fe6-104a-4ab2-a336-cd249089d919.webp?v=1714977823","width":2000},{"alt":null,"id":23897371902051,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9fefa4a6d524128bf97ba3677c3b1d4441ffe2d_e8bb698a-12cf-441d-940e-369e426af3b6.webp?v=1714977826"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/e9fefa4a6d524128bf97ba3677c3b1d4441ffe2d_e8bb698a-12cf-441d-940e-369e426af3b6.webp?v=1714977826","width":2000},{"alt":null,"id":23897372262499,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/adab8aa2438533cc35f87f106040e1ae77b8dea0_1ebc09d4-ed25-4a74-8ce3-187c8ffc2bac.webp?v=1714977828"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/adab8aa2438533cc35f87f106040e1ae77b8dea0_1ebc09d4-ed25-4a74-8ce3-187c8ffc2bac.webp?v=1714977828","width":2000},{"alt":null,"id":23897372819555,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831","width":2000},{"alt":null,"id":23897373212771,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f6d4991675afbf09c819f58759a31023a32fd656_6ba7a37b-77c0-4c36-82f2-1907fde10584.webp?v=1714977833"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f6d4991675afbf09c819f58759a31023a32fd656_6ba7a37b-77c0-4c36-82f2-1907fde10584.webp?v=1714977833","width":2000},{"alt":null,"id":23897373769827,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b6f36f0358570a98d181ceca887b986293bd1fb_5976ad43-102b-42cf-8c6b-fac2592e4f02.webp?v=1714977835"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2b6f36f0358570a98d181ceca887b986293bd1fb_5976ad43-102b-42cf-8c6b-fac2592e4f02.webp?v=1714977835","width":2000},{"alt":null,"id":23897374457955,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dee5a5ef958bc9f5d7a78ea2ea2c45921ad4cff_702826f2-290c-4c6d-a6a0-4ac717c95938.webp?v=1714977838"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/1dee5a5ef958bc9f5d7a78ea2ea2c45921ad4cff_702826f2-290c-4c6d-a6a0-4ac717c95938.webp?v=1714977838","width":2000},{"alt":null,"id":23897375080547,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9df95a61ffa1480346dfa09470a3d55de2340b8_b80a1fbb-94f0-432f-b642-7c9452ed6212.webp?v=1714977840"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d9df95a61ffa1480346dfa09470a3d55de2340b8_b80a1fbb-94f0-432f-b642-7c9452ed6212.webp?v=1714977840","width":2000},{"alt":null,"id":23897376358499,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/48ba3457a672d4521b6b7d2dcb043d2a83e1b571_f78365b4-c399-4f45-b0e2-75b40c27476c.webp?v=1714977845"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/48ba3457a672d4521b6b7d2dcb043d2a83e1b571_f78365b4-c399-4f45-b0e2-75b40c27476c.webp?v=1714977845","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41918993301603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-SR09","requires_shipping":true,"taxable":true,"featured_image":{"id":31491959554147,"product_id":7416369447011,"position":4,"created_at":"2024-05-06T14:43:51+08:00","updated_at":"2024-05-06T14:43:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831","variant_ids":[41918993301603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 The Powerpuff Girls - 愛心圖案 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0105424-SR09","featured_media":{"alt":null,"id":23897372819555,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41918993301603,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-SR09","requires_shipping":true,"taxable":true,"featured_image":{"id":31491959554147,"product_id":7416369447011,"position":4,"created_at":"2024-05-06T14:43:51+08:00","updated_at":"2024-05-06T14:43:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831","variant_ids":[41918993301603]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 The Powerpuff Girls - 愛心圖案 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":90000,"weight":980,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"NPB0105424-SR09","featured_media":{"alt":null,"id":23897372819555,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/73f6a83b8275fa0de3042ce9209be69bd7e25081_652ef5bf-1199-481f-a17f-9321eec2bed0.webp?v=1714977831"}},"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: "停產" }