@no_one345 wrote:
i m working on a diagram using tree mapper as base of my diagram
https://gojs.net/latest/samples/treeMapper.html
i need to know is there a way to make the trees in both groups to be opened to level 2 by default i cant seem to achieve that
i tried thisfunction defaulTreeLvl(e) { //alert("here"+e) myDiagram.startTransaction("reexpand"); var level = e; myDiagram.findTreeRoots().each(function(g) { //console.log(g.child); g.collapseTree(level); //expandGroups(g, 0, level); }) myDiagram.commitTransaction("reexpand"); }
but the findtreeroots give me the groups (leftside, rightside) instead of the item 0and the other one
Posts: 2
Participants: 2