$product = {"id":7408456269923,"title":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-線稿風格","handle":"iphone-12-pro-max-mod-nx-printable-pb53","description":null,"published_at":"2024-06-11T16:37:43+08:00","created_at":"2024-05-03T15:30:09+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 12 pro 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":41885677355107,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB53","requires_shipping":true,"taxable":true,"featured_image":{"id":31472328409187,"product_id":7408456269923,"position":9,"created_at":"2024-05-03T15:30:29+08:00","updated_at":"2024-05-03T15:30:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429","variant_ids":[41885677355107]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-線稿風格 - 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":"NPB0118724-PB53","featured_media":{"alt":null,"id":23877244911715,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}],"images":["\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46fccf24cd8e417139ab0393c278a1fe2310a1a6_6bc4c103-f554-44f2-ab00-306cd07be800.webp?v=1714721411","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12397d48c00936a4572914e2acfe8bc17e38ba0a_d79a7c7d-3a1f-4254-8216-9398491ddb2a.webp?v=1714721413","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/22987e38b524e74e8ee659978b603b66222969d7_f234378e-e414-4b48-aec3-21c7e9943b50.webp?v=1714721415","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f66e46ee7a26b505a22a46e7ae998634e09b6116_e2bce1a4-9eb4-48c2-b51b-eced7505201b.webp?v=1714721418","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd50d84d0e344bbdd603db03788ddcd92b693567_082a148b-9202-4a32-a867-ad20ed71fcae.webp?v=1714721420","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e17e42a422ef490f918656b46c40e0d8b4dfd2c_3203995d-6cf8-478f-b60d-42948cb5413e.webp?v=1714721422","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fecde2b27363b29b49bf1ffeff6d7e9b9e4f4134_d2766bba-8958-4769-88f9-5cd1d2fbe80b.webp?v=1714721424","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d69ec49d28a7342ac984ecfe16eba89060710e09_b7e2e8db-fb6b-4bd3-a4dd-a2bbdc608cca.webp?v=1714721427","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429","\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/198c6c2791ad570118025d13164ca8411794e1f2_f3d6b1e8-9ed5-4d9c-97ba-8b2fd0601877.webp?v=1714721432"],"featured_image":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46fccf24cd8e417139ab0393c278a1fe2310a1a6_6bc4c103-f554-44f2-ab00-306cd07be800.webp?v=1714721411","options":["color"],"media":[{"alt":null,"id":23877241077859,"position":1,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46fccf24cd8e417139ab0393c278a1fe2310a1a6_6bc4c103-f554-44f2-ab00-306cd07be800.webp?v=1714721411"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/46fccf24cd8e417139ab0393c278a1fe2310a1a6_6bc4c103-f554-44f2-ab00-306cd07be800.webp?v=1714721411","width":2000},{"alt":null,"id":23877241667683,"position":2,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12397d48c00936a4572914e2acfe8bc17e38ba0a_d79a7c7d-3a1f-4254-8216-9398491ddb2a.webp?v=1714721413"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/12397d48c00936a4572914e2acfe8bc17e38ba0a_d79a7c7d-3a1f-4254-8216-9398491ddb2a.webp?v=1714721413","width":2000},{"alt":null,"id":23877242093667,"position":3,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/22987e38b524e74e8ee659978b603b66222969d7_f234378e-e414-4b48-aec3-21c7e9943b50.webp?v=1714721415"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/22987e38b524e74e8ee659978b603b66222969d7_f234378e-e414-4b48-aec3-21c7e9943b50.webp?v=1714721415","width":2000},{"alt":null,"id":23877242519651,"position":4,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f66e46ee7a26b505a22a46e7ae998634e09b6116_e2bce1a4-9eb4-48c2-b51b-eced7505201b.webp?v=1714721418"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/f66e46ee7a26b505a22a46e7ae998634e09b6116_e2bce1a4-9eb4-48c2-b51b-eced7505201b.webp?v=1714721418","width":2000},{"alt":null,"id":23877242945635,"position":5,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd50d84d0e344bbdd603db03788ddcd92b693567_082a148b-9202-4a32-a867-ad20ed71fcae.webp?v=1714721420"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/dd50d84d0e344bbdd603db03788ddcd92b693567_082a148b-9202-4a32-a867-ad20ed71fcae.webp?v=1714721420","width":2000},{"alt":null,"id":23877243371619,"position":6,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e17e42a422ef490f918656b46c40e0d8b4dfd2c_3203995d-6cf8-478f-b60d-42948cb5413e.webp?v=1714721422"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/8e17e42a422ef490f918656b46c40e0d8b4dfd2c_3203995d-6cf8-478f-b60d-42948cb5413e.webp?v=1714721422","width":2000},{"alt":null,"id":23877243830371,"position":7,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fecde2b27363b29b49bf1ffeff6d7e9b9e4f4134_d2766bba-8958-4769-88f9-5cd1d2fbe80b.webp?v=1714721424"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/fecde2b27363b29b49bf1ffeff6d7e9b9e4f4134_d2766bba-8958-4769-88f9-5cd1d2fbe80b.webp?v=1714721424","width":2000},{"alt":null,"id":23877244321891,"position":8,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d69ec49d28a7342ac984ecfe16eba89060710e09_b7e2e8db-fb6b-4bd3-a4dd-a2bbdc608cca.webp?v=1714721427"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/d69ec49d28a7342ac984ecfe16eba89060710e09_b7e2e8db-fb6b-4bd3-a4dd-a2bbdc608cca.webp?v=1714721427","width":2000},{"alt":null,"id":23877244911715,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429","width":2000},{"alt":null,"id":23877245436003,"position":10,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/198c6c2791ad570118025d13164ca8411794e1f2_f3d6b1e8-9ed5-4d9c-97ba-8b2fd0601877.webp?v=1714721432"},"aspect_ratio":1.0,"height":2000,"media_type":"image","src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/198c6c2791ad570118025d13164ca8411794e1f2_f3d6b1e8-9ed5-4d9c-97ba-8b2fd0601877.webp?v=1714721432","width":2000}],"requires_selling_plan":false,"selling_plan_groups":[],"content":null}; $isMerge = null; $variants = [{"id":41885677355107,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB53","requires_shipping":true,"taxable":true,"featured_image":{"id":31472328409187,"product_id":7408456269923,"position":9,"created_at":"2024-05-03T15:30:29+08:00","updated_at":"2024-05-03T15:30:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429","variant_ids":[41885677355107]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-線稿風格 - 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":"NPB0118724-PB53","featured_media":{"alt":null,"id":23877244911715,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429"}},"requires_selling_plan":false,"selling_plan_allocations":[],"quantity_rule":{"min":1,"max":null,"increment":1}}]; $defaultVariant = {"id":41885677355107,"title":"Mod NX-黑色邊框","option1":"Mod NX-黑色邊框","option2":null,"option3":null,"sku":"NPB0118724-PB53","requires_shipping":true,"taxable":true,"featured_image":{"id":31472328409187,"product_id":7408456269923,"position":9,"created_at":"2024-05-03T15:30:29+08:00","updated_at":"2024-05-03T15:30:29+08:00","alt":null,"width":2000,"height":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429","variant_ids":[41885677355107]},"available":true,"name":"犀牛盾Mod NX手機殼 - iPhone 12 Pro Max - 【聯名設計款】 - 迪士尼-星際大戰 Star Wars - 風暴兵-線稿風格 - 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":"NPB0118724-PB53","featured_media":{"alt":null,"id":23877244911715,"position":9,"preview_image":{"aspect_ratio":1.0,"height":2000,"width":2000,"src":"\/\/b2b.rhinoshield.tw\/cdn\/shop\/files\/c57342aebe73c86d32e9d2afa2d1f53a4ea20a28_8be1063d-a992-438b-af47-94a841b3178f.webp?v=1714721429"}},"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: "停產" }