c# - Reload treeview and open in one place - Dynatree -


i'm trying recharge treeview using dynatree , expand in same place left off, can not. i'm carrying whole, making query in mvc using oracle , returning shortlist dynatree keys defined.

my code:

$("#tree").dynatree({    selectmode: 3,    clickfoldermode: 3,    initajax: {    type: "post",    url: "/controller/gettree"  } }); 

to recharge record insert via ajax mvc, way upgrade give reload treeview, so:

$("#tree").dynatree("gettree").reload(); 

then try expand or getnodebykey use, still not work

$("#tree").dynatree("getroot").visit(function (node) {  node.expand(true);  }); 

thanks

there cookie persistence functionality or can tree.selectkey(val).expand(); val key of need expand.

you can use generateids:true; option when creating tree can access directly nodes if know id , can use jquery selector.


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -