Domanda

Is there any simple way to get the object, used to render given row in CellTable, by index of the row?

I am using AsyncDataProvider, and don't want to remember lists of data objects, returned from the server. Also I am using MultiSelectionModel, so several items could be selected there and I need to track out which one was clicked last.

I know the index of last clicked row, so I need to get the object, corresponding to the row, somehow.

È stato utile?

Soluzione

getVisibleItem? possibly combined with getPageStart if you're using paging and you only know the absolute index.

For your use-case, maybe you could use a customized selection model whose setSelected tracks the last change.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top