Issue in reordering rows

Issue in reordering rows

osamajavedosamajaved Posts: 12Questions: 6Answers: 0

Hi
I am using reorder functionality through drag and drop of a row.
Normally, it is working fine, but when i have multiple line and i delete a row

t.on('click', 'tbody tr .btnDelete', function () {
t.row($(this).parents('tr'))
.remove()
.draw(true);
$.each($('#invoiceLines tr td:first-child'), function (index, val) {
$(this).html(index + 1);
});
});

after deleting, if i try to reorder the row again.... the sequence goes like
2
2
3
4
it does not start with 1.

Looking forward to your reply. Thanks

Answers

This discussion has been closed.