Getting selected rows on current page only

Getting selected rows on current page only

chanuliachanulia Posts: 5Questions: 2Answers: 1

I am trying to get the rows selected in current page only, but

table.rows( { page: 'current'},{ selected: true } ).data().pluck(0).toArray();
gives me all current rows

and
table.rows( { selected: true }, {page: 'current'} ).data().pluck(0).toArray();
gives me all selected rows

What am I missing?

Thanks!
Anna

This question has an accepted answers - jump to answer

Answers

  • kthorngrenkthorngren Posts: 20,309Questions: 26Answers: 4,770
    Answer ✓

    I think it needs to be one object not two, like this:
    table.rows( { page: 'current', selected: true } ).data().pluck(0).toArray();

    Kevin

  • chanuliachanulia Posts: 5Questions: 2Answers: 1

    Yes! Thank you so much, Kevin!

    Anna

This discussion has been closed.