Sorted by default date possible ?
hello, is there a solution for sorted by date (from most recent to oldest) by default? Thank you.
Find this line 3648 with content:
mainTable = $('#main-table').DataTable({"paging": false, "info": false, "columnDefs": [{"targets": _targets, "orderable": false}]
and add to the end:
, "order": [[ 4, "desc" ]]
so the resulting line is:
mainTable = $('#main-table').DataTable({"paging": false, "info": false, "columnDefs": [{"targets": _targets, "orderable": false}], "order": [[ 4, "desc" ]]
NOTE: If the checkbox column is not shown (readonly-user) - use: [[ 3, "desc" ]]
mainTable = $('#main-table').DataTable({"paging": false, "info": false, "columnDefs": [{"targets": _targets, "orderable": false}], "order": [[ 2, "desc" ]]
it's ok with it !