- 文件夹节点+1,下面的会发这末多次响应 ,响应太多了,并且还要向数据库查询文件夹节点+1次
$('#t').tree({
url : 'aAction!Tree.action',
lines : true,
checked : true,
onLoadSuccess : function(node,data){
var t=$(this);
if(data){
$(data).each(function(index,d){
if(this.state=='expandAll'){
t.tree('expandAll');
}
});
}
}
});
- 如果你不想这末繁琐的话,可以在后台写 ,返回带children属性的 json