My config:
config = TreeviewConfig.create({
hasAllCheckBox: false,
hasFilter: true,
hasCollapseExpand: false,
decoupleChildFromParent: true,
maxHeight: 400
});
I am using the inbuilt filter to find specific items in tree structure. But when I am selecting (selecting the checkbox) an item from the filtered tree structure, the checked property for that particular treeviewitem is not setting to true in the treeviewItem collection. How can resolve this issue?
Let's assume you have a
Treeview item list
named as treeList and you have a set of items you want to check in an array named checkList.All you have to do is to iterate through the array list of specific IDs that is to be checked in the tree and use the
TreeviewHelper.findItemInList
andchecked
properties to set those items checked.For further reference, you can check this.