[ Dataview ] getSelectedItem returns undefined.

Hello,

https://webix.com/snippet/4b4bf40b

In that snippet Dataviews ‘getSelectedItem()’ returns undefined and also ‘getSelectedId()’ returns wrong id. It returns the ID from previously selected Item.

I don’t think it supposed to be so.

onItemClick fires before the selection is applied to the clicked item, so it is the expected result. Please use onAfterSelect instead.

Also, you can check the order of all events and avoid common issues using the debug version of the library.

@Listopad , thanks thanks thanks.