$product = {"id":7414987817059,"title":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 迪士尼-星際大戰 Star Wars - JEDI ORDER徽章2-潮流系列","handle":"iphone-12-mini-mod-nx-magsafe-printable-pb47","description":null,"published_at":"2024-06-11T17:54:56+08:00","created_at":"2024-05-05T20:01:32+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX MagSafe專區迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone 12 mini","merge","mod-nx-magsafe-printable","new-modnx-sku","reseller-modnx-magsafe-star-wars","Top50","type-Mod NX Printable MagSafe Printable"],"price":110000,"price_min":110000,"price_max":110000,"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":41910668361827,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-PB47","requires_shipping":true,"taxable":true,"featured_image":{"id":31487861260387,"product_id":7414987817059,"position":8,"created_at":"2024-05-05T20:01:51+08:00","updated_at":"2024-05-05T20:01:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511","variant_ids":[41910668361827]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 迪士尼-星際大戰 Star Wars - JEDI ORDER徽章2-潮流系列 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-PB47","featured_media":{"alt":null,"id":23893205287011,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76e5904ed2148c33e7110b5ec7152c1c4be614cc_dcd8e268-ace5-43a9-8cfc-1324bd7d4726.webp?v=1714910495","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d51586194b77524f2ac0e5757f5c009df8384250_21ad41eb-2418-4784-a308-4b1b34a5cd44.webp?v=1714910497","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44357ee5bd961e270a738d57366fbccef6336f55_02bae0b0-eb41-4388-9579-ecb1c2878cce.webp?v=1714910500","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c0db9facec73aad41a19da98d47003ece8942913_dfaddbfc-376f-4b5c-8b8a-efec891a7b7c.webp?v=1714910502","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a98322988927db156c23d9322e11df60f3b4e111_3cb004c7-07ce-4a4a-956e-7ed2e66bd264.webp?v=1714910505","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c43acf28b8a4f9e45def3d4eb846dc579cccd2c8_2ddcb72d-004b-4e66-92ad-68c8ab339b39.webp?v=1714910507","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/54a8b3d8eac686973e70b4a479399d862143fb8d_489af022-0e6b-4c51-8a4f-ac4e282a630b.webp?v=1714910509","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c296c08b9ce59da18e9b9c3cd9ac77b8dc40582a_2cac0339-bf17-40bb-a6de-508620825e3d.webp?v=1714910514","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/375a3b3f9be022d51752bdf6c093f984d90b5815_69807a18-daf8-4bd3-bd95-b0200578e2af.webp?v=1714910516","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/365cf786b8df69f021b3bc94919586d35a15ce36_bddba59e-ebc8-4b32-9a05-d13165f8b492.webp?v=1714910518"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76e5904ed2148c33e7110b5ec7152c1c4be614cc_dcd8e268-ace5-43a9-8cfc-1324bd7d4726.webp?v=1714910495","options":["color"],"media":[{"alt":null,"id":23893200535651,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76e5904ed2148c33e7110b5ec7152c1c4be614cc_dcd8e268-ace5-43a9-8cfc-1324bd7d4726.webp?v=1714910495"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/76e5904ed2148c33e7110b5ec7152c1c4be614cc_dcd8e268-ace5-43a9-8cfc-1324bd7d4726.webp?v=1714910495","width":2000},{"alt":null,"id":23893201453155,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d51586194b77524f2ac0e5757f5c009df8384250_21ad41eb-2418-4784-a308-4b1b34a5cd44.webp?v=1714910497"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d51586194b77524f2ac0e5757f5c009df8384250_21ad41eb-2418-4784-a308-4b1b34a5cd44.webp?v=1714910497","width":2000},{"alt":null,"id":23893202010211,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44357ee5bd961e270a738d57366fbccef6336f55_02bae0b0-eb41-4388-9579-ecb1c2878cce.webp?v=1714910500"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/44357ee5bd961e270a738d57366fbccef6336f55_02bae0b0-eb41-4388-9579-ecb1c2878cce.webp?v=1714910500","width":2000},{"alt":null,"id":23893203058787,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c0db9facec73aad41a19da98d47003ece8942913_dfaddbfc-376f-4b5c-8b8a-efec891a7b7c.webp?v=1714910502"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c0db9facec73aad41a19da98d47003ece8942913_dfaddbfc-376f-4b5c-8b8a-efec891a7b7c.webp?v=1714910502","width":2000},{"alt":null,"id":23893203583075,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a98322988927db156c23d9322e11df60f3b4e111_3cb004c7-07ce-4a4a-956e-7ed2e66bd264.webp?v=1714910505"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a98322988927db156c23d9322e11df60f3b4e111_3cb004c7-07ce-4a4a-956e-7ed2e66bd264.webp?v=1714910505","width":2000},{"alt":null,"id":23893204074595,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c43acf28b8a4f9e45def3d4eb846dc579cccd2c8_2ddcb72d-004b-4e66-92ad-68c8ab339b39.webp?v=1714910507"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c43acf28b8a4f9e45def3d4eb846dc579cccd2c8_2ddcb72d-004b-4e66-92ad-68c8ab339b39.webp?v=1714910507","width":2000},{"alt":null,"id":23893204533347,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/54a8b3d8eac686973e70b4a479399d862143fb8d_489af022-0e6b-4c51-8a4f-ac4e282a630b.webp?v=1714910509"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/54a8b3d8eac686973e70b4a479399d862143fb8d_489af022-0e6b-4c51-8a4f-ac4e282a630b.webp?v=1714910509","width":2000},{"alt":null,"id":23893205287011,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511","width":2000},{"alt":null,"id":23893205712995,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c296c08b9ce59da18e9b9c3cd9ac77b8dc40582a_2cac0339-bf17-40bb-a6de-508620825e3d.webp?v=1714910514"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c296c08b9ce59da18e9b9c3cd9ac77b8dc40582a_2cac0339-bf17-40bb-a6de-508620825e3d.webp?v=1714910514","width":2000},{"alt":null,"id":23893206138979,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/375a3b3f9be022d51752bdf6c093f984d90b5815_69807a18-daf8-4bd3-bd95-b0200578e2af.webp?v=1714910516"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/375a3b3f9be022d51752bdf6c093f984d90b5815_69807a18-daf8-4bd3-bd95-b0200578e2af.webp?v=1714910516","width":2000},{"alt":null,"id":23893206630499,"position":11,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/365cf786b8df69f021b3bc94919586d35a15ce36_bddba59e-ebc8-4b32-9a05-d13165f8b492.webp?v=1714910518"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/365cf786b8df69f021b3bc94919586d35a15ce36_bddba59e-ebc8-4b32-9a05-d13165f8b492.webp?v=1714910518","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41910668361827,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-PB47","requires_shipping":true,"taxable":true,"featured_image":{"id":31487861260387,"product_id":7414987817059,"position":8,"created_at":"2024-05-05T20:01:51+08:00","updated_at":"2024-05-05T20:01:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511","variant_ids":[41910668361827]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 迪士尼-星際大戰 Star Wars - JEDI ORDER徽章2-潮流系列 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-PB47","featured_media":{"alt":null,"id":23893205287011,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41910668361827,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"MPB0118424-PB47","requires_shipping":true,"taxable":true,"featured_image":{"id":31487861260387,"product_id":7414987817059,"position":8,"created_at":"2024-05-05T20:01:51+08:00","updated_at":"2024-05-05T20:01:51+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511","variant_ids":[41910668361827]},"available":true,"name":"犀牛盾Mod NX (MagSafe 兼容)手機殼 - iPhone 12 mini - 迪士尼-星際大戰 Star Wars - JEDI ORDER徽章2-潮流系列 - Mod NX-黑色邊框","public_title":"Mod NX-黑色邊框","options":["Mod NX-黑色邊框"],"price":110000,"weight":1500,"compare_at_price":null,"inventory_quantity":2500,"inventory_management":null,"inventory_policy":"deny","barcode":"MPB0118424-PB47","featured_media":{"alt":null,"id":23893205287011,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/b7cd2f21b1be934064ed3e96f01b3313af4c19b9_108f3666-7462-4c9a-a955-558c09d140eb.webp?v=1714910511"}},"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: "停產" }