Lines 978-989
function _dt_add_filters(table_node, table_dt, filters_options = {}) {
Link Here
|
978 |
let th = $(table_node).find( |
978 |
let th = $(table_node).find( |
979 |
"thead tr:eq(1) th:eq(%s)".format(visible_i) |
979 |
"thead tr:eq(1) th:eq(%s)".format(visible_i) |
980 |
); |
980 |
); |
981 |
var is_searchable = columns[i].bSearchable; |
981 |
var is_searchable = table_dt.settings()[0].aoColumns[i].bSearchable; |
982 |
$(th) |
982 |
$(this) |
983 |
.removeClass("sorting") |
983 |
.removeClass("sorting") |
984 |
.removeClass("sorting_asc") |
984 |
.removeClass("sorting_asc") |
985 |
.removeClass("sorting_desc"); |
985 |
.removeClass("sorting_desc"); |
986 |
if (is_searchable) { |
986 |
$(this).data("th-id", i); |
|
|
987 |
if (is_searchable || $(this).data("filter") || filters_options[i]) { |
987 |
let input_type = "input"; |
988 |
let input_type = "input"; |
988 |
let existing_search = column.search(); |
989 |
let existing_search = column.search(); |
989 |
if ($(th).data("filter") || filters_options.hasOwnProperty(i)) { |
990 |
if ($(th).data("filter") || filters_options.hasOwnProperty(i)) { |
990 |
- |
|
|