From d55a99eb4c2a87a017bda37bd51c81e32968dbdf Mon Sep 17 00:00:00 2001 From: Mottie Date: Mon, 4 Aug 2014 07:38:22 -0500 Subject: [PATCH] Filter: external select causing javascript error. Fixes #702 --- js/jquery.tablesorter.widgets.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/jquery.tablesorter.widgets.js b/js/jquery.tablesorter.widgets.js index e5ab03e4..e94470cd 100644 --- a/js/jquery.tablesorter.widgets.js +++ b/js/jquery.tablesorter.widgets.js @@ -1140,7 +1140,8 @@ ts.filter = { result = showRow; // if showRow is true, show that row // in case select filter option has a different value vs text "a - z|A through Z" - ffxn = c.$filters.eq(columnIndex).find('select option:selected').attr('data-function-name') || ''; + ffxn = wo.filter_columnFilters ? + c.$filters.add(c.$externalFilters).filter('[data-column="'+ columnIndex + '"]').find('select option:selected').attr('data-function-name') || '' : ''; // replace accents - see #357 filters[columnIndex] = c.sortLocaleCompare ? ts.replaceAccents(filters[columnIndex]) : filters[columnIndex];