Datatables: sort only the current pagination of the table

I am using datatables . And by default, with the pagination function, when sorting a single column, it redraws the entire table and puts you on the first page paginated. Is there an easy way to tell the data that I want to sort and redraw only the current pagination? And if there is no way to override the default sort function? Addition: I am a static usin data table without any ajax functions.

0
source share
1 answer

I saw some ideas on the Internet, but the only thing that worked for me was commenting out reset to 0 in the _fnFilterComplete function

/* Redraw the table */ /*oSettings._iDisplayStart = 0 Andrew nuked this 8/5/2013 ;*/ _fnCalculateEnd( oSettings ); _fnDraw( oSettings ); 
+1
source

Source: https://habr.com/ru/post/979484/


All Articles