Bug 11205: fix DataTables filter issue when more than one table is on a page
This patch fixes a bug where if there are more than one table on the same page that uses the DataTables column filter, applying a filter on one table applied it to both. Test plan: 1/ Go on serials/serials-search.pl?searched=1 2/ Filter on a column (e.g., title) on the open subscriptions table. 3/ Switch to the closed subscriptions table. Observe that that the table is *also* filtered by the criteria set for the open subscriptions table. 4/ Apply the patch and reload the page. 5/ This time, applying a filter on one time should not affect the other table. Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
parent
a1d4af3d73
commit
6e7d8ece1f
|
|
@ -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' ) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue