jquery - DataTable sorting: make one column stay fixed -
i'm using jquery datatables plugin. sorting works fine, there way make 1 column stay same no matter sorting applied?
for example, first column simple order numbers: 1, 2, 3, 4, 5... , when sort date, or else, first column stays in same order: 1, 2, 3..?
is there way this? so, not trying disable sorting first column, make first column stay same when sorting applied columns.
you can using orderfixed option defines ordering applied table.
for example, sort first column in ascending order:
$('#example').datatable( { "orderfixed": [ 0, 'asc' ] } );
Comments
Post a Comment