mirror of
https://github.com/DataTables/DataTables.git
synced 2024-11-29 11:24:10 +01:00
Dev fix: Sorting a filtered table was broken
- Because of the decoupling of the filtering and sorting, the filtering was missing that the indexes of the displayed data will have changed after a sort. So need to do a full filter when just sorted
This commit is contained in:
parent
8debb87477
commit
bef8374eed
@ -1 +1 @@
|
||||
277cf29e4569deac5b9692cf26f29baa1fe5e463
|
||||
8583fb37f99549488c7d149a917459b1073aec01
|
||||
|
6
media/js/jquery.dataTables.js
vendored
6
media/js/jquery.dataTables.js
vendored
@ -2398,8 +2398,10 @@
|
||||
if ( invalidated ||
|
||||
force ||
|
||||
prevSearch.length > input.length ||
|
||||
input.indexOf(prevSearch) !== 0 )
|
||||
{
|
||||
input.indexOf(prevSearch) !== 0 ||
|
||||
settings.bSorted // On resort, the display master needs to be
|
||||
// re-filtered since indexes will have changed
|
||||
) {
|
||||
settings.aiDisplay = displayMaster.slice();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user