Hi!
I need your help because I cannot understand my tree behaviour.
I have a parent linking, load on demand tree.
What I want is to display the opener icon on folders (whatever their number of children) but not on leaves. I thought the treeGRid.setAlwaysShowOpener() method will do the job but it is not the case: every node (folders and leaves) have the opener icon.
What should I do to implement the beahviour I wish?
Here is a sample of my code :
(I did not pu my full code because it is very long. May some other methods or handlers interact with the opener icon?)
I need your help because I cannot understand my tree behaviour.
I have a parent linking, load on demand tree.
What I want is to display the opener icon on folders (whatever their number of children) but not on leaves. I thought the treeGRid.setAlwaysShowOpener() method will do the job but it is not the case: every node (folders and leaves) have the opener icon.
What should I do to implement the beahviour I wish?
Here is a sample of my code :
Code:
ResultTree tree = new ResultTree(); tree.setModelType(TreeModelType.PARENT); tree.setIdField("id"); tree.setParentIdField("parentId"); tree.setIsFolderProperty("hasChildren"); [...] treeGrid = new TreeGrid(); treeGrid.setDataProperties(tree); treeGrid.setDataSource(dataSource); treeGrid.setAutoFetchData(true); [...] treeGrid.setAlwaysShowOpener(true); [...]
Comment