From 046ff4515d588f9f3c486db4b03ff993ddc6b635 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 5 Nov 2013 18:07:56 +0100 Subject: [PATCH] [SIGNED-OFF] Bug 11205: The datatables filtering does not work when several tables exist If there are more than 1 table on the same page, the datatable filters don't work. Test plan: 1/ Go on serials/serials-search.pl?searched=1 2/ filter on a column for opened subscriptions => the closed subscriptions should not be filtered. Works! Signed-off-by: Brendan Gallagher --- koha-tmpl/intranet-tmpl/prog/en/js/datatables.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/datatables.js b/koha-tmpl/intranet-tmpl/prog/en/js/datatables.js index d4c161a..c2a2cf8 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/js/datatables.js +++ b/koha-tmpl/intranet-tmpl/prog/en/js/datatables.js @@ -115,7 +115,7 @@ jQuery.fn.dataTableExt.oApi.fnAddFilters = function ( oSettings, sClass, iDelay var table = this; this.fnSetFilteringDelay(iDelay); var filterTimerId = null; - $("input."+sClass).keyup(function(event) { + $(table).find("input."+sClass).keyup(function(event) { if (blacklist_keys.indexOf(event.keyCode) != -1) { return this; }else if ( event.keyCode == '13' ) { -- 1.7.10.4