Insert new row at top with no ordering set?
Insert new row at top with no ordering set?
lukasbloom
Posts: 1Questions: 1Answers: 0
The ordering is enabled, but there is no default order... the rows are shown in the order they are read by DataTables:
var DataTable = $(".js-table").DataTable({
ordering: true,
order: []
});
I'm using this to insert a new row:
DataTable.row.add(new_row).draw();
The record is inserted at the bottom of the table. Is there a way to insert it at the top of the table?
This discussion has been closed.
Answers
Hi @lukasbloom ,
You could try the Absolute sorting plugin - that may do the trick for you,
Cheers,
Colin