Shopify.quickshopOptionsMap6202830782637 = {}; Shopify.quickshopUpdateOptionsInSelector6202830782637 = function(selectorIndex) { switch (selectorIndex) { case 0: var key = 'root'; var selector = jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(0)'); break; case 1: var key = jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(0)').val(); var selector = jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(1)'); break; case 2: var key = jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(0)').val(); key += ' / ' + jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(1)').val(); var selector = jQuery('#product-form-quick-6202830782637 .single-option-selector:eq(2)'); } var initialValue = selector.val(); selector.empty(); var availableOptions = Shopify.quickshopOptionsMap6202830782637[key]; if (availableOptions && availableOptions.length) { for (var i = 0; i < availableOptions.length; i++) { var option = availableOptions[i]; var newOption = jQuery('').val(option).html(option); selector.append(newOption); } jQuery('#product-form-quick-6202830782637 .swatch[data-option-index="' + selectorIndex + '"] .swatch-element').each(function() { if (jQuery.inArray(jQuery(this).attr('data-value'), availableOptions) !== -1) { jQuery(this).removeClass('soldout').show().find(':radio').removeAttr('disabled', 'disabled').removeAttr('checked'); } else { jQuery(this).addClass('soldout').hide().find(':radio').removeAttr('checked').attr('disabled', 'disabled'); } }); if (jQuery.inArray(initialValue, availableOptions) !== -1) { selector.val(initialValue); } selector.trigger('change'); } }; Shopify.quickshopLinkOptionSelectors6202830782637 = function(product) { // Building our mapping object. for (var i = 0; i < product.variants.length; i++) { var variant = product.variants[i]; //if (variant.available) { // Gathering values for the 1st drop-down. Shopify.quickshopOptionsMap6202830782637['root'] = Shopify.quickshopOptionsMap6202830782637['root'] || []; Shopify.quickshopOptionsMap6202830782637['root'].push(variant.option1); Shopify.quickshopOptionsMap6202830782637['root'] = Shopify.uniq(Shopify.quickshopOptionsMap6202830782637['root']); // Gathering values for the 2nd drop-down. if (product.options.length > 1) { var key = variant.option1; Shopify.quickshopOptionsMap6202830782637[key] = Shopify.quickshopOptionsMap6202830782637[key] || []; Shopify.quickshopOptionsMap6202830782637[key].push(variant.option2); Shopify.quickshopOptionsMap6202830782637[key] = Shopify.uniq(Shopify.quickshopOptionsMap6202830782637[key]); } // Gathering values for the 3rd drop-down. if (product.options.length === 3) { var key = variant.option1 + ' / ' + variant.option2; Shopify.quickshopOptionsMap6202830782637[key] = Shopify.quickshopOptionsMap6202830782637[key] || []; Shopify.quickshopOptionsMap6202830782637[key].push(variant.option3); Shopify.quickshopOptionsMap6202830782637[key] = Shopify.uniq(Shopify.quickshopOptionsMap6202830782637[key]); } //} } // Update options right away. Shopify.quickshopUpdateOptionsInSelector6202830782637(0); if (product.options.length > 1) Shopify.quickshopUpdateOptionsInSelector6202830782637(1); if (product.options.length === 3) Shopify.quickshopUpdateOptionsInSelector6202830782637(2); // When there is an update in the first dropdown. jQuery("#product-form-quick-6202830782637 .single-option-selector:eq(0)").change(function() { Shopify.quickshopUpdateOptionsInSelector6202830782637(1); if (product.options.length === 3) Shopify.quickshopUpdateOptionsInSelector6202830782637(2); return true; }); // When there is an update in the second dropdown. jQuery("#product-form-quick-6202830782637 .single-option-selector:eq(1)").change(function() { if (product.options.length === 3) Shopify.quickshopUpdateOptionsInSelector6202830782637(2); return true; }); }; productsObj.id6202830782637 = {"id":6202830782637,"title":"Denergy® Sticker Tattoo Cartridges Handpoke Aluminum alloy","handle":"discover-device-tattoo-aluminum-cartridge-needle-hankpoke-tool-tattoo-grip-tube","description":"\u003cdiv style=\"text-align: left;\"\u003e\u003cimg style=\"float: none;\" alt=\"\" src=\"https:\/\/cdn.shopify.com\/s\/files\/1\/0148\/5556\/9462\/files\/poke_banner1.jpg?v=1662182342\"\u003e\u003c\/div\u003e\n\u003cul\u003e\n\u003cli\u003eItem Name: Cartridge Hand Poke Tool\u003c\/li\u003e\n\u003cli\u003eMaterial:Aluminum\u003c\/li\u003e\n\u003cli\u003eCraft:CNC \u0026amp; Anodize\u003c\/li\u003e\n\u003cli\u003eNet weight:53grams \/ 1.77Oz\u003c\/li\u003e\n\u003cli\u003eFit Needle: Cheyenne,FK,Bishop Da Vinci,Discover Device\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cbr\u003e\u003cstrong\u003eFeatures\u003c\/strong\u003e\u003cbr\u003e\n\u003cul\u003e\n\u003cli\u003eCNC craft.\u003c\/li\u003e\n\u003cli\u003eColor Anodized.\u003c\/li\u003e\n\u003cli\u003eAutoclavable.\u003c\/li\u003e\n\u003cli\u003ePoked with full range needle cartridges.\u003c\/li\u003e\n\u003cli\u003eFits with main brands of needle cartridges.\u003c\/li\u003e\n\u003c\/ul\u003e","published_at":"2021-01-14T16:14:17+08:00","created_at":"2021-01-14T16:14:15+08:00","vendor":"Denergy","type":"Tattoo Hand Poke Tool","tags":[],"price":4300,"price_min":4300,"price_max":4300,"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":37995976556717,"title":"Black","option1":"Black","option2":null,"option3":null,"sku":"2554-BK","requires_shipping":true,"taxable":false,"featured_image":{"id":23413808988333,"product_id":6202830782637,"position":8,"created_at":"2021-01-14T16:14:17+08:00","updated_at":"2022-09-03T15:42:04+08:00","alt":null,"width":1000,"height":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/5_3929ab45-a297-4e6e-92c3-44972ba8c714.jpg?v=1662190924","variant_ids":[37995976556717]},"available":true,"name":"Denergy® Sticker Tattoo Cartridges Handpoke Aluminum alloy - Black","public_title":"Black","options":["Black"],"price":4300,"weight":50,"compare_at_price":null,"inventory_management":"shopify","barcode":"784633866522","featured_media":{"alt":null,"id":15584575062189,"position":8,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/5_3929ab45-a297-4e6e-92c3-44972ba8c714.jpg?v=1662190924"}},"requires_selling_plan":false,"selling_plan_allocations":[]},{"id":37995976589485,"title":"Red","option1":"Red","option2":null,"option3":null,"sku":"2554-RD","requires_shipping":true,"taxable":false,"featured_image":{"id":36248299110573,"product_id":6202830782637,"position":10,"created_at":"2024-12-23T14:22:55+08:00","updated_at":"2024-12-24T05:58:38+08:00","alt":null,"width":1500,"height":1500,"src":"\/\/discoverdevice.com\/cdn\/shop\/files\/10266.jpg?v=1734991118","variant_ids":[37995976589485]},"available":true,"name":"Denergy® Sticker Tattoo Cartridges Handpoke Aluminum alloy - Red","public_title":"Red","options":["Red"],"price":4300,"weight":50,"compare_at_price":null,"inventory_management":"shopify","barcode":"","featured_media":{"alt":null,"id":28374571188397,"position":10,"preview_image":{"aspect_ratio":1.0,"height":1500,"width":1500,"src":"\/\/discoverdevice.com\/cdn\/shop\/files\/10266.jpg?v=1734991118"}},"requires_selling_plan":false,"selling_plan_allocations":[]}],"images":["\/\/discoverdevice.com\/cdn\/shop\/products\/1022.jpg?v=1662190843","\/\/discoverdevice.com\/cdn\/shop\/products\/2_853d9ed9-e776-4f6b-ad8b-48fe64266732.jpg?v=1662190797","\/\/discoverdevice.com\/cdn\/shop\/products\/tattoo-needle-cartridge-2-0609-denergy_1.jpg?v=1662190962","\/\/discoverdevice.com\/cdn\/shop\/products\/Dicover-Cartridge-Poketool.jpg?v=1662190968","\/\/discoverdevice.com\/cdn\/shop\/products\/3_f28657b1-86b4-474e-b62d-8a8437c86ef9.jpg?v=1662190924","\/\/discoverdevice.com\/cdn\/shop\/products\/7_7900c57d-089a-4419-bb31-9439da9ecd80.jpg?v=1662190924","\/\/discoverdevice.com\/cdn\/shop\/products\/4_39dddc03-8489-4155-b23e-37eed32d9999.jpg?v=1662190924","\/\/discoverdevice.com\/cdn\/shop\/products\/5_3929ab45-a297-4e6e-92c3-44972ba8c714.jpg?v=1662190924","\/\/discoverdevice.com\/cdn\/shop\/products\/6_90117fbe-be50-480b-b5c7-4d8c09a99b23.jpg?v=1662190924","\/\/discoverdevice.com\/cdn\/shop\/files\/10266.jpg?v=1734991118"],"featured_image":"\/\/discoverdevice.com\/cdn\/shop\/products\/1022.jpg?v=1662190843","options":["Color"],"media":[{"alt":null,"id":24499036061869,"position":1,"preview_image":{"aspect_ratio":1.0,"height":1500,"width":1500,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/1022.jpg?v=1662190843"},"aspect_ratio":1.0,"height":1500,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/1022.jpg?v=1662190843","width":1500},{"alt":null,"id":15584574963885,"position":2,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/2_853d9ed9-e776-4f6b-ad8b-48fe64266732.jpg?v=1662190797"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/2_853d9ed9-e776-4f6b-ad8b-48fe64266732.jpg?v=1662190797","width":1000},{"alt":null,"id":24499037208749,"position":3,"preview_image":{"aspect_ratio":1.0,"height":1024,"width":1024,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/tattoo-needle-cartridge-2-0609-denergy_1.jpg?v=1662190962"},"aspect_ratio":1.0,"height":1024,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/tattoo-needle-cartridge-2-0609-denergy_1.jpg?v=1662190962","width":1024},{"alt":null,"id":24499036324013,"position":4,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/Dicover-Cartridge-Poketool.jpg?v=1662190968"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/Dicover-Cartridge-Poketool.jpg?v=1662190968","width":1000},{"alt":null,"id":15584574996653,"position":5,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/3_f28657b1-86b4-474e-b62d-8a8437c86ef9.jpg?v=1662190924"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/3_f28657b1-86b4-474e-b62d-8a8437c86ef9.jpg?v=1662190924","width":1000},{"alt":null,"id":15584575127725,"position":6,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/7_7900c57d-089a-4419-bb31-9439da9ecd80.jpg?v=1662190924"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/7_7900c57d-089a-4419-bb31-9439da9ecd80.jpg?v=1662190924","width":1000},{"alt":null,"id":15584575029421,"position":7,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/4_39dddc03-8489-4155-b23e-37eed32d9999.jpg?v=1662190924"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/4_39dddc03-8489-4155-b23e-37eed32d9999.jpg?v=1662190924","width":1000},{"alt":null,"id":15584575062189,"position":8,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/5_3929ab45-a297-4e6e-92c3-44972ba8c714.jpg?v=1662190924"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/5_3929ab45-a297-4e6e-92c3-44972ba8c714.jpg?v=1662190924","width":1000},{"alt":null,"id":15584575094957,"position":9,"preview_image":{"aspect_ratio":1.0,"height":1000,"width":1000,"src":"\/\/discoverdevice.com\/cdn\/shop\/products\/6_90117fbe-be50-480b-b5c7-4d8c09a99b23.jpg?v=1662190924"},"aspect_ratio":1.0,"height":1000,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/products\/6_90117fbe-be50-480b-b5c7-4d8c09a99b23.jpg?v=1662190924","width":1000},{"alt":null,"id":28374571188397,"position":10,"preview_image":{"aspect_ratio":1.0,"height":1500,"width":1500,"src":"\/\/discoverdevice.com\/cdn\/shop\/files\/10266.jpg?v=1734991118"},"aspect_ratio":1.0,"height":1500,"media_type":"image","src":"\/\/discoverdevice.com\/cdn\/shop\/files\/10266.jpg?v=1734991118","width":1500}],"requires_selling_plan":false,"selling_plan_groups":[],"content":"\u003cdiv style=\"text-align: left;\"\u003e\u003cimg style=\"float: none;\" alt=\"\" src=\"https:\/\/cdn.shopify.com\/s\/files\/1\/0148\/5556\/9462\/files\/poke_banner1.jpg?v=1662182342\"\u003e\u003c\/div\u003e\n\u003cul\u003e\n\u003cli\u003eItem Name: Cartridge Hand Poke Tool\u003c\/li\u003e\n\u003cli\u003eMaterial:Aluminum\u003c\/li\u003e\n\u003cli\u003eCraft:CNC \u0026amp; Anodize\u003c\/li\u003e\n\u003cli\u003eNet weight:53grams \/ 1.77Oz\u003c\/li\u003e\n\u003cli\u003eFit Needle: Cheyenne,FK,Bishop Da Vinci,Discover Device\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cbr\u003e\u003cstrong\u003eFeatures\u003c\/strong\u003e\u003cbr\u003e\n\u003cul\u003e\n\u003cli\u003eCNC craft.\u003c\/li\u003e\n\u003cli\u003eColor Anodized.\u003c\/li\u003e\n\u003cli\u003eAutoclavable.\u003c\/li\u003e\n\u003cli\u003ePoked with full range needle cartridges.\u003c\/li\u003e\n\u003cli\u003eFits with main brands of needle cartridges.\u003c\/li\u003e\n\u003c\/ul\u003e"}; selectCallback = function(variant, selector) { if (variant) { if (variant.available) { if (variant.compare_at_price > variant.price) { $(".price-box .price").html('' + Shopify.formatMoney(variant.compare_at_price, money_format) + "" + ' ' + Shopify.formatMoney(variant.price, money_format) + "") } else { $(".price-box .price").html('' + Shopify.formatMoney(variant.price, money_format) + ""); } woodmart_settings.enableCurrency && currenciesCallbackSpecial(".price-box span.money"),$(".single_add_to_cart_button").removeClass("disabled").removeAttr("disabled").html(window.inventory_text.add_to_cart); }else{ $("#product-form-quick-6202830782637 .single_add_to_cart_button").html(window.inventory_text.sold_out).addClass("disabled").attr("disabled", "disabled"); } if(swatch_color_type == '1' || swatch_color_type == '2'){ var form = $('#' + selector.domIdPrefix).closest('form'); for (var i=0,length=variant.options.length; i= 1) { //multiple variants for (var i = 0; i < product.variants.length; i++) { var variant = product.variants[i]; var option = ''; layout.find('form.product-form > select').append(option); } new Shopify.OptionSelectors("product-selectors-6202830782637", { product: product, onVariantSelected: selectCallback, enableHistoryState: true }); var filePath = asset_url.substring(0, asset_url.lastIndexOf('/')); var assetUrl = asset_url.substring(0, asset_url.lastIndexOf('/')); var options = ""; for (var i = 0; i < product.options.length; i++) { options += '
'; options += '
' + product.options[i] + ':
'; options += '
'; var is_color = false; var is_circle = 'circle'; if (/Color|Colour/i.test(product.options[i])) { is_color = true; } if (swatch_color_type == '2') { is_color = false; is_circle = ''; } var optionValues = new Array(); for (var j = 0; j < product.variants.length; j++) { var variant = product.variants[j]; var value = variant.options[i]; if(variant.featured_image && woodmart_settings.product_data.product_swatch_setting == '2'){ var img = variant.featured_image.src.lastIndexOf("."); var vimg = variant.featured_image.src.slice(0, img) + "_50x50_crop_center" + variant.featured_image.src.slice(img); } var valueHandle = convertToSlug(value); var forText = 'swatch-6202830782637-' + i + '-' + valueHandle; if (optionValues.indexOf(value) < 0) { options += '
'; if (is_color) { options += '
' + value + '
'; } options += ''; if (is_color) { if(vimg && woodmart_settings.product_data.product_swatch_setting == '2'){ options += ''; }else{ options += ''; } } else { options += ''; } options += '
'; if (variant.available) { $('#product-form-quick-6202830782637 .swatch[data-option-index="' + i + '"] .' + valueHandle).removeClass('soldout').addClass('available').find(':radio').removeAttr('disabled'); } optionValues.push(value); } } options += '
'; options += '
'; } if(swatch_color_type == '1' || swatch_color_type == '2'){ layout.find('form.product-form .product-options > select').after(options); layout.find('.swatch :radio').change(function() { var optionIndex = $(this).closest('.swatch').attr('data-option-index'); var optionValue = $(this).val(); $(this) .closest('form') .find('.single-option-selector') .eq(optionIndex) .val(optionValue) .trigger('change'); }); } if (product.available) { Shopify.quickshopOptionsMap6202830782637 = {}; Shopify.quickshopLinkOptionSelectors6202830782637(product); } } else { //single variant layout.find('form.product-form .product-options > select').remove(); var variant_field = ''; layout.find('form.product-form').append(variant_field); } });