From 1034be84166cf0606719da058ea0ec3b88809744 Mon Sep 17 00:00:00 2001 From: Jens Ulferts Date: Mon, 2 Feb 2015 15:34:55 +0100 Subject: [PATCH] fix javascript dom selectors --- .../reporting_engine/reporting/filters.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/assets/javascripts/reporting_engine/reporting/filters.js b/lib/assets/javascripts/reporting_engine/reporting/filters.js index 6360ea72c0..464a677cc0 100644 --- a/lib/assets/javascripts/reporting_engine/reporting/filters.js +++ b/lib/assets/javascripts/reporting_engine/reporting/filters.js @@ -239,16 +239,16 @@ Reporting.Filters = { }, value_changed: function (field) { - var val, tr; + var val, filter; val = $(field + '_arg_1_val'); - tr = $('filter_' + field); + filter = $('filter_' + field); if (!val) { return; } if (val.value === '<>') { - tr.addClassName('inactive-filter'); + filter.addClassName('inactive-filter'); } else { - tr.removeClassName('inactive-filter'); + filter.removeClassName('inactive-filter'); } }, @@ -294,8 +294,8 @@ Reporting.Filters = { }, visible_filters: function () { - return $("filter_table").select("tr").select(function (tr) { - return tr.visible() === true; + return $("filter_table").select(".advanced-filters--filter").select(function (filter) { + return filter.visible() === true; }).collect(function (filter) { return filter.getAttribute("data-filter-name"); });