1jQuery(function ($) { 2 $(document).bind('click', function (e) { 3 if (!$(e.target).parents().hasClass("woof_select_radio_check")) { 4 $(".woof_select_radio_check dd ul").hide(200); 5 $(".woof_select_radio_check_opened").removeClass('woof_select_radio_check_opened'); 6 } 7 }); 8}); 9 10 11function woof_init_select_radio_check() { 12 jQuery(".woof_select_radio_check dt a.woof_select_radio_check_opener").on('click', function () { 13 var _this = this; 14 jQuery.each(jQuery(".woof_select_radio_check_opener"), function (i, sel) { 15 if (sel !== _this) { 16 jQuery(this).parents('.woof_select_radio_check').find("dd ul").hide(); 17 jQuery(this).parents('.woof_select_radio_check').find('.woof_select_radio_check_opened').removeClass('woof_select_radio_check_opened'); 18 } 19 }); 20 21 22 //+++ 23 jQuery(this).parents('.woof_select_radio_check').find("dd ul").slideToggle(200); 24 if (jQuery(this).parent().hasClass('woof_select_radio_check_opened')) { 25 jQuery(this).parent().removeClass('woof_select_radio_check_opened'); 26 } else { 27 jQuery(this).parent().addClass('woof_select_radio_check_opened'); 28 } 29 }); 30 31 //+++ 32 33 if (Object.keys(woof_current_values).length > 0) { 34 jQuery.each(woof_current_values, function (index, value) { 35 36 if (!jQuery('.woof_hida_' + index).length) { 37 return; 38 } 39 40 value = value.toString().trim(); 41 if (value.search(',')) { 42 value = value.split(','); 43 } 44 //+++ 45 var txt_results = new Array(); 46 var v_results = new Array(); 47 jQuery.each(value, function (i, v) { 48 var txt = v; 49 var is_in_custom = false; 50 if (Object.keys(woof_lang_custom).length > 0) { 51 jQuery.each(woof_lang_custom, function (i, tt) { 52 if (i == index) { 53 is_in_custom = true; 54 txt = tt; 55 } 56 }); 57 } 58 59 if (!is_in_custom) { 60 try { 61 txt = jQuery("input[data-anchor='woof_n_" + index + '_' + v + "']").val(); 62 } catch (e) { 63 console.log(e); 64 } 65 66 if (typeof txt === 'undefined') 67 { 68 txt = v; 69 } 70 } 71 72 txt_results.push(txt); 73 v_results.push(v); 74 75 }); 76 77 if (txt_results.length) { 78 jQuery('.woof_hida_' + index).addClass('woof_hida_small'); 79 jQuery('.woof_hida_' + index).html('<div class="woof_products_top_panel2"></div>'); 80 var panel = jQuery('.woof_hida_' + index).find('.woof_products_top_panel2'); 81 panel.show(); 82 panel.html('<ul></ul>'); 83 jQuery.each(txt_results, function (i, txt) { 84 panel.find('ul').append( 85 jQuery('<li>').append( 86 jQuery('<a>').attr('href', v_results[i]).attr('data-tax', index).append( 87 jQuery('<span>').attr('class', 'woof_remove_ppi').append(txt) 88 ))); 89 }); 90 91 //jQuery('.woof_hida_' + index).html(txt_results.join(',')); 92 } else { 93 jQuery('.woof_hida_' + index).removeClass('woof_hida_small'); 94 jQuery('.woof_hida_' + index).html(jQuery('.woof_hida_' + index).data('title')); 95 } 96 97 }); 98 99 //woof_draw_products_top_panel(); 100 } 101 102 //*** 103 104 jQuery.each(jQuery('.woof_mutliSelect'), function (i, txt) { 105 if (parseInt(jQuery(this).data('height'), 10) > 0) { 106 jQuery(this).find('ul.woof_list:first-child').eq(0).css('max-height', jQuery(this).data('height')); 107 } else { 108 jQuery(this).find('ul.woof_list:first-child').eq(0).css('max-height', 100); 109 } 110 }); 111 112 113}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.