How to persist DataTable selected items after data is updated/refreshed

  • I have a Data Table that allows single item selection. The Data Table data is automatically updated every 5 seconds through websockets events. If I have an item selected, every time the Data Table data is updated, that item gets deselected, and I would like to persist the item selection after the data is updated.

    Is there a way to accomplish this? I was thinking in two different approachs, but I have no idea how to do it, at least not from the documentation:

    • access directly the Data Table selected item
    • handle an event fired when an item is selected

    In both cases the main idea would be to save the selection in a store, an restore the selection when the Data Table items update is done.

    Stackoverflow link

  • As far as I can see, they’re already working in this enenhancement for the Quasar-Framework v0.14 🙂

  • Hi, i have the same need. Preselect rows from an array.

    I dont see this feature in .14.1 in docs
    @rstoenescu , can i do that?

Log in to reply