$product = {"id":7416083513443,"title":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 路克\u0026莉亞公主-電影海報","handle":"iphone-xs-max-mod-nx-printable-pb102","description":null,"published_at":"2024-06-11T16:52:17+08:00","created_at":"2024-05-06T12:54:49+08:00","vendor":"RHINOSHIELD Taiwan B2B","type":"設計師MOD NX專區-迪士尼-星際大戰 Star Wars","tags":["20%","25%","30%","35%","40%","45%","50%","b2b","brand-Apple","designer","designer-starwars","device-iPhone XS Max","merge","mod-nx-printable","new-modnx-sku","reseller-modnx-star-wars","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":41917261414499,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB102","requires_shipping":true,"taxable":true,"featured_image":{"id":31491173777507,"product_id":7416083513443,"position":2,"created_at":"2024-05-06T12:54:54+08:00","updated_at":"2024-05-06T12:54:54+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294","variant_ids":[41917261414499]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 路克\u0026莉亞公主-電影海報 - 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":"NPB0108624-PB102","featured_media":{"alt":null,"id":23896581472355,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c3a97b48a49e1a31c3c86c34abfa354931fb3a4_d612b9d2-d3ba-4fb9-a119-f49159dc3168.webp?v=1714971292","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3fed9963e2d8380e7c19658aff9c40bd32cccfe_efadeee0-545b-40a6-963d-9189203df796.webp?v=1714971297","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e99c4b22a6b0b7fe5195850078480247144f1b3_aaf7d732-f1f7-488d-b643-89e2c9f2244f.webp?v=1714971299","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/733fbfe18ee66f9203ec35f8d51bd4f222b18981_1e107b4b-06fd-4a38-9432-9eb588a2d21c.webp?v=1714971301","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0401cb662f770d3f4974401b467c8b4cee8a2701_031eb441-5eeb-4525-8f88-69c7b7916591.webp?v=1714971304","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/05c7edcea103f1ee9d9f01a8a7553027b0699f6c_6ddd62f0-df6b-4e4a-9fef-b54adb7568f1.webp?v=1714971306","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f48cc58761ef2fa1edc304b3a5a61e24f749573_04af7407-fa97-4fb5-91a8-5d9c6c4aef91.webp?v=1714971309","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a095aa72c509af168898819fcada4ab5a1d27d6_f655da43-4a39-4287-a2ed-2307c4aa2687.webp?v=1714971311","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4c52e3db7dcfcb0fad77fbbbeefe59cb1bc3a88_9593adf3-8220-4e28-bc9d-b64b5d245f70.webp?v=1714971313"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c3a97b48a49e1a31c3c86c34abfa354931fb3a4_d612b9d2-d3ba-4fb9-a119-f49159dc3168.webp?v=1714971292","options":["color"],"media":[{"alt":null,"id":23896580751459,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c3a97b48a49e1a31c3c86c34abfa354931fb3a4_d612b9d2-d3ba-4fb9-a119-f49159dc3168.webp?v=1714971292"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/7c3a97b48a49e1a31c3c86c34abfa354931fb3a4_d612b9d2-d3ba-4fb9-a119-f49159dc3168.webp?v=1714971292","width":2000},{"alt":null,"id":23896581472355,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294","width":2000},{"alt":null,"id":23896582062179,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3fed9963e2d8380e7c19658aff9c40bd32cccfe_efadeee0-545b-40a6-963d-9189203df796.webp?v=1714971297"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/a3fed9963e2d8380e7c19658aff9c40bd32cccfe_efadeee0-545b-40a6-963d-9189203df796.webp?v=1714971297","width":2000},{"alt":null,"id":23896582520931,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e99c4b22a6b0b7fe5195850078480247144f1b3_aaf7d732-f1f7-488d-b643-89e2c9f2244f.webp?v=1714971299"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e99c4b22a6b0b7fe5195850078480247144f1b3_aaf7d732-f1f7-488d-b643-89e2c9f2244f.webp?v=1714971299","width":2000},{"alt":null,"id":23896583077987,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/733fbfe18ee66f9203ec35f8d51bd4f222b18981_1e107b4b-06fd-4a38-9432-9eb588a2d21c.webp?v=1714971301"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/733fbfe18ee66f9203ec35f8d51bd4f222b18981_1e107b4b-06fd-4a38-9432-9eb588a2d21c.webp?v=1714971301","width":2000},{"alt":null,"id":23896583536739,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0401cb662f770d3f4974401b467c8b4cee8a2701_031eb441-5eeb-4525-8f88-69c7b7916591.webp?v=1714971304"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/0401cb662f770d3f4974401b467c8b4cee8a2701_031eb441-5eeb-4525-8f88-69c7b7916591.webp?v=1714971304","width":2000},{"alt":null,"id":23896583864419,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/05c7edcea103f1ee9d9f01a8a7553027b0699f6c_6ddd62f0-df6b-4e4a-9fef-b54adb7568f1.webp?v=1714971306"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/05c7edcea103f1ee9d9f01a8a7553027b0699f6c_6ddd62f0-df6b-4e4a-9fef-b54adb7568f1.webp?v=1714971306","width":2000},{"alt":null,"id":23896584519779,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f48cc58761ef2fa1edc304b3a5a61e24f749573_04af7407-fa97-4fb5-91a8-5d9c6c4aef91.webp?v=1714971309"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/9f48cc58761ef2fa1edc304b3a5a61e24f749573_04af7407-fa97-4fb5-91a8-5d9c6c4aef91.webp?v=1714971309","width":2000},{"alt":null,"id":23896584945763,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a095aa72c509af168898819fcada4ab5a1d27d6_f655da43-4a39-4287-a2ed-2307c4aa2687.webp?v=1714971311"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/5a095aa72c509af168898819fcada4ab5a1d27d6_f655da43-4a39-4287-a2ed-2307c4aa2687.webp?v=1714971311","width":2000},{"alt":null,"id":23896585240675,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4c52e3db7dcfcb0fad77fbbbeefe59cb1bc3a88_9593adf3-8220-4e28-bc9d-b64b5d245f70.webp?v=1714971313"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d4c52e3db7dcfcb0fad77fbbbeefe59cb1bc3a88_9593adf3-8220-4e28-bc9d-b64b5d245f70.webp?v=1714971313","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41917261414499,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB102","requires_shipping":true,"taxable":true,"featured_image":{"id":31491173777507,"product_id":7416083513443,"position":2,"created_at":"2024-05-06T12:54:54+08:00","updated_at":"2024-05-06T12:54:54+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294","variant_ids":[41917261414499]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 路克\u0026莉亞公主-電影海報 - 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":"NPB0108624-PB102","featured_media":{"alt":null,"id":23896581472355,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41917261414499,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0108624-PB102","requires_shipping":true,"taxable":true,"featured_image":{"id":31491173777507,"product_id":7416083513443,"position":2,"created_at":"2024-05-06T12:54:54+08:00","updated_at":"2024-05-06T12:54:54+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294","variant_ids":[41917261414499]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone XS Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 路克\u0026莉亞公主-電影海報 - 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":"NPB0108624-PB102","featured_media":{"alt":null,"id":23896581472355,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/2354a88786059becebb7d3d9a21c7be4a387709b_35c3a4e6-fa76-4427-bb29-b15a8ead7bb8.webp?v=1714971294"}},"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: "停產" }