Kendo TreeList: expanded should stay expanded for user experience

805 Views Asked by At

I have a Kendo TreeList and can edit each item. After editing, I do

treeList.dataSource.read();

This causes every item to collapse (because the default .expand is false).

But I want that everything (items expanded by the user, items not expanded) stays the same, just the edited item/row should change in the view.

1

There are 1 best solutions below

0
On BEST ANSWER

This solved my issue :

https://www.telerik.com/forums/restoring-treelist-expanded-state-after-refresh

I had to save the expanded state and restore it every time I call treeList.dataSource.read().

Therefore, I used an onDataBinding method to save and an onDataBound method to restore.