Return to default order
Return to default order
Assume aaSorting is [].
Each sortable header start in an unordered state, and has two others, ascending and descending.
However once you pick one, the choices are now ascending and descending, but unordered is no longer available.
Any simple way to do this? It is a datables issue or a jquery-ui one? Or should think on adding a button for this (which would kill ALL orders)?
Thanks,
Gerardo
Each sortable header start in an unordered state, and has two others, ascending and descending.
However once you pick one, the choices are now ascending and descending, but unordered is no longer available.
Any simple way to do this? It is a datables issue or a jquery-ui one? Or should think on adding a button for this (which would kill ALL orders)?
Thanks,
Gerardo
This discussion has been closed.
Replies
There is an API function which can be used to zero out the sorting order and restore it to the default: http://datatables.net/plug-ins/api#fnSortNeutral . You could attach this to a button if you wished.
I suppose it might be an idea in future to provide this as a configurable option in DataTables, click 1 gives ASC, click 2 gives DESC, click 3 gives original sort order... Added to the list.
Regards,
Allan
Gerardo