From 1fa4743a846e2adefe447c5aa63c2453546e0f28 Mon Sep 17 00:00:00 2001 From: Menno van der Werff Date: Wed, 3 Jan 2018 14:54:19 +0100 Subject: [PATCH] Fix individual filtering in combination with horizontal scrolling by using the Datatable instance and not a predefined ID as selector. --- Resources/views/datatable/search.js.twig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Resources/views/datatable/search.js.twig b/Resources/views/datatable/search.js.twig index 427c8fa5..18e4be1a 100644 --- a/Resources/views/datatable/search.js.twig +++ b/Resources/views/datatable/search.js.twig @@ -37,9 +37,9 @@ var search = $.fn.dataTable.util.throttle( options.searchDelay ); -$(selector).find("tr input.sg-datatables-individual-filtering").on("keyup change", search); +$(oTable.table().container()).find("tr input.sg-datatables-individual-filtering").on("keyup change", search); -$(selector).find("tr select.sg-datatables-individual-filtering").on("keyup change", function(event) { +$(oTable.table().container()).find("tr select.sg-datatables-individual-filtering").on("keyup change", function(event) { var searchValue = $(this).val(); searchValue = searchValue ? searchValue.toString() : ''; oTable