jquery-datatables-checkboxes icon indicating copy to clipboard operation
jquery-datatables-checkboxes copied to clipboard

Update number of selected rows after rows().remove()

Open Thibault34 opened this issue 8 years ago • 2 comments

Hello, When I use table.rows('.myClass').remove(), the number of select row is not updated.

I must be used : table.rows('.myClass').deselect().remove().draw();

The problem isn't in default datatable checkbox selection : http://live.datatables.net/seqejati/4/edit

Can you help me please ?

Thibault34 avatar Feb 17 '17 09:02 Thibault34

Good catch! However the example you mentioned uses different way to show checkboxes.

For now you need deselect() as shown below. See this example for code and demonstration.

table.rows('.myClass').deselect().remove().draw();

I will see if I could find a way to catch row removal event and update internal data accordingly.

mpryvkin avatar Feb 23 '17 13:02 mpryvkin

Thank you

Thibault34 avatar Feb 23 '17 14:02 Thibault34