fix issue with table filter listening for wrong checkboxes
This commit is contained in:
parent
2a311917b3
commit
e10f725303
@ -128,28 +128,28 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function setupTableFilter() {
|
function setupTableFilter() {
|
||||||
var filterForm = element.querySelector(ASYNC_TABLE_FILTER_FORM_SELECTOR);
|
var tableFilterForm = element.querySelector(ASYNC_TABLE_FILTER_FORM_SELECTOR);
|
||||||
|
|
||||||
if (filterForm) {
|
if (tableFilterForm) {
|
||||||
gatherTableFilterInputs();
|
gatherTableFilterInputs(tableFilterForm);
|
||||||
addTableFilterEventListeners();
|
addTableFilterEventListeners();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function gatherTableFilterInputs() {
|
function gatherTableFilterInputs(tableFilterForm) {
|
||||||
Array.from(element.querySelectorAll('input[type="search"]')).forEach(function(input) {
|
Array.from(tableFilterForm.querySelectorAll('input[type="search"]')).forEach(function(input) {
|
||||||
tableFilterInputs.search.push(input);
|
tableFilterInputs.search.push(input);
|
||||||
});
|
});
|
||||||
|
|
||||||
Array.from(element.querySelectorAll('input[type="text"]')).forEach(function(input) {
|
Array.from(tableFilterForm.querySelectorAll('input[type="text"]')).forEach(function(input) {
|
||||||
tableFilterInputs.input.push(input);
|
tableFilterInputs.input.push(input);
|
||||||
});
|
});
|
||||||
|
|
||||||
Array.from(element.querySelectorAll('input:not([type="text"]):not([type="search"])')).forEach(function(input) {
|
Array.from(tableFilterForm.querySelectorAll('input:not([type="text"]):not([type="search"])')).forEach(function(input) {
|
||||||
tableFilterInputs.change.push(input);
|
tableFilterInputs.change.push(input);
|
||||||
});
|
});
|
||||||
|
|
||||||
Array.from(element.querySelectorAll('select')).forEach(function(input) {
|
Array.from(tableFilterForm.querySelectorAll('select')).forEach(function(input) {
|
||||||
tableFilterInputs.select.push(input);
|
tableFilterInputs.select.push(input);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user