From 602a79b10ac366094a9c6728ddcf302fae8ea10a Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Fri, 24 Feb 2023 15:47:41 +0100 Subject: [PATCH] Bug 33066: Fix dt - no need to reselect MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Bug 33066: (follow-up) Fix dt - no need to reselect Patron search result table was not displayed correctly Uncaught TypeError: this.on is not a function Signed-off-by: Pedro Amorim Signed-off-by: Agustín Moyano Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 75eaa1f5c58d224b48c332fd8eac31108eb9f375) Signed-off-by: Martin Renvoize --- koha-tmpl/intranet-tmpl/prog/js/datatables.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/datatables.js b/koha-tmpl/intranet-tmpl/prog/js/datatables.js index 81a900e084..689fc4307c 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/datatables.js +++ b/koha-tmpl/intranet-tmpl/prog/js/datatables.js @@ -58,7 +58,7 @@ var dataTablesDefaults = { // When the DataTables search function is triggered, // enable or disable the "Clear filter" button based on // the presence of a search string - $("#" + tableId ).on( 'search.dt', function ( e, settings ) { + $(this).on( 'search.dt', function ( e, settings ) { toggledClearFilter(settings.oPreviousSearch.sSearch, tableId); }); } -- 2.39.2