$product = {"id":7416329928803,"title":"犀牛盾Mod NX手機殼 - iPhone 7\/8\/SE2\/SE3 - 【聯名設計款】 - Care Bears - 夜空星語","handle":"iphone-8-mod-nx-printable-yb12","description":null,"published_at":"2024-06-11T16:56:04+08:00","created_at":"2024-05-06T14:35:40+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":41918564925539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31491856662627,"product_id":7416329928803,"position":1,"created_at":"2024-05-06T14:35:42+08:00","updated_at":"2024-05-06T14:35:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","variant_ids":[41918564925539]},"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-YB12","featured_media":{"alt":null,"id":23897269502051,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/841167d4ee3fa3382d1ceb3e5062a2348849a2e4_e882b526-0bac-43b0-91a6-bf68b607bb36.webp?v=1714977345","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2e04b7a9ff5f4b876805e7dc6fd3b23705f980d3_a5f6e7e3-a4e7-49fd-8ed3-e1c9eecb6fce.webp?v=1714977347","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b28d62a56fa842c97c0516a8a144b167ebd8619e_61d635be-cf09-43e9-9630-5cfe44c42c97.webp?v=1714977349","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/56e275016979f5a9f562b7633819a5896d1f4959_7d8967b0-055d-49ee-b66c-f54f6af28b32.webp?v=1714977352","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/059a8a921405a8ce7439922e13f91f66b3ca3063_19008641-6939-4b67-8df4-be8982246954.webp?v=1714977354","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/251525edf7d0f1cfb9eac0ea89b4f8b0b016f5a9_70860228-174c-4035-af00-3ad67af94cb4.webp?v=1714977357","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bab0828087b43b82d884fdb40409255d2ef03c6_38ae258b-3eee-4224-b923-c88704896579.webp?v=1714977359","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59bbb79f905af9448de6e16a26665b1377adba37_cb692a2c-d2c9-4eba-9677-e7a0fdea21da.webp?v=1714977362","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7597414c29bb7ad39e4dd727ddef0ccf92ebe2b9_8d2c1b30-a401-4a48-9307-400560bf8f15.webp?v=1714977365"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","options":["color"],"media":[{"alt":null,"id":23897269502051,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","width":2000},{"alt":null,"id":23897269764195,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/841167d4ee3fa3382d1ceb3e5062a2348849a2e4_e882b526-0bac-43b0-91a6-bf68b607bb36.webp?v=1714977345"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/841167d4ee3fa3382d1ceb3e5062a2348849a2e4_e882b526-0bac-43b0-91a6-bf68b607bb36.webp?v=1714977345","width":2000},{"alt":null,"id":23897270354019,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2e04b7a9ff5f4b876805e7dc6fd3b23705f980d3_a5f6e7e3-a4e7-49fd-8ed3-e1c9eecb6fce.webp?v=1714977347"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2e04b7a9ff5f4b876805e7dc6fd3b23705f980d3_a5f6e7e3-a4e7-49fd-8ed3-e1c9eecb6fce.webp?v=1714977347","width":2000},{"alt":null,"id":23897270616163,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b28d62a56fa842c97c0516a8a144b167ebd8619e_61d635be-cf09-43e9-9630-5cfe44c42c97.webp?v=1714977349"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b28d62a56fa842c97c0516a8a144b167ebd8619e_61d635be-cf09-43e9-9630-5cfe44c42c97.webp?v=1714977349","width":2000},{"alt":null,"id":23897271238755,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/56e275016979f5a9f562b7633819a5896d1f4959_7d8967b0-055d-49ee-b66c-f54f6af28b32.webp?v=1714977352"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/56e275016979f5a9f562b7633819a5896d1f4959_7d8967b0-055d-49ee-b66c-f54f6af28b32.webp?v=1714977352","width":2000},{"alt":null,"id":23897271697507,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/059a8a921405a8ce7439922e13f91f66b3ca3063_19008641-6939-4b67-8df4-be8982246954.webp?v=1714977354"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/059a8a921405a8ce7439922e13f91f66b3ca3063_19008641-6939-4b67-8df4-be8982246954.webp?v=1714977354","width":2000},{"alt":null,"id":23897272189027,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/251525edf7d0f1cfb9eac0ea89b4f8b0b016f5a9_70860228-174c-4035-af00-3ad67af94cb4.webp?v=1714977357"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/251525edf7d0f1cfb9eac0ea89b4f8b0b016f5a9_70860228-174c-4035-af00-3ad67af94cb4.webp?v=1714977357","width":2000},{"alt":null,"id":23897272582243,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bab0828087b43b82d884fdb40409255d2ef03c6_38ae258b-3eee-4224-b923-c88704896579.webp?v=1714977359"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2bab0828087b43b82d884fdb40409255d2ef03c6_38ae258b-3eee-4224-b923-c88704896579.webp?v=1714977359","width":2000},{"alt":null,"id":23897273401443,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59bbb79f905af9448de6e16a26665b1377adba37_cb692a2c-d2c9-4eba-9677-e7a0fdea21da.webp?v=1714977362"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/59bbb79f905af9448de6e16a26665b1377adba37_cb692a2c-d2c9-4eba-9677-e7a0fdea21da.webp?v=1714977362","width":2000},{"alt":null,"id":23897273696355,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7597414c29bb7ad39e4dd727ddef0ccf92ebe2b9_8d2c1b30-a401-4a48-9307-400560bf8f15.webp?v=1714977365"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7597414c29bb7ad39e4dd727ddef0ccf92ebe2b9_8d2c1b30-a401-4a48-9307-400560bf8f15.webp?v=1714977365","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41918564925539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31491856662627,"product_id":7416329928803,"position":1,"created_at":"2024-05-06T14:35:42+08:00","updated_at":"2024-05-06T14:35:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","variant_ids":[41918564925539]},"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-YB12","featured_media":{"alt":null,"id":23897269502051,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41918564925539,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0105424-YB12","requires_shipping":true,"taxable":true,"featured_image":{"id":31491856662627,"product_id":7416329928803,"position":1,"created_at":"2024-05-06T14:35:42+08:00","updated_at":"2024-05-06T14:35:42+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342","variant_ids":[41918564925539]},"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-YB12","featured_media":{"alt":null,"id":23897269502051,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/521f512eaad3954bf1096f198ed0cf5318d00f43_def6f37e-5314-4215-9301-ca3e0f3cb6d1.webp?v=1714977342"}},"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: "停產" }