@@ -, +, @@ --- koha-tmpl/intranet-tmpl/prog/js/datatables.js | 13 ++++-- .../js/vue/components/ERM/AgreementsList.vue | 41 ++++++++++--------- .../prog/js/vue/components/KohaTable.vue | 6 ++- 3 files changed, 35 insertions(+), 25 deletions(-) --- a/koha-tmpl/intranet-tmpl/prog/js/datatables.js +++ a/koha-tmpl/intranet-tmpl/prog/js/datatables.js @@ -822,7 +822,7 @@ function _dt_on_visibility(add_filters, table_node, table_dt){ } } -function _dt_add_filters(table_node, table_dt) { +function _dt_add_filters(table_node, table_dt, filters_options = {}) { $(table_node).find('thead tr').clone().appendTo( $(table_node).find('thead') ); $(table_node).find('thead tr:eq(1) th').each( function (i) { @@ -831,14 +831,19 @@ function _dt_add_filters(table_node, table_dt) { $(this).data('th-id', i); if ( is_searchable ) { let input_type = 'input'; - if ( $(this).data('filter') ) { + if ( $(this).data('filter') || filters_options.hasOwnProperty(i)) { input_type = 'select' let filter_type = $(this).data('filter'); - var existing_search = table_dt.column(i).search(); + let existing_search = table_dt.column(i).search(); let select = $('