//官方推荐
this.getModuleGrid().getRootNode().cascadeBy(function () {
this.set("checked", false);
if (ids.indexOf(this.data["Id"].toString()) > -1) {
this.set("checked", true);
}
});
//通过Children方式
GetChilds: function (idArray, node) {
ts = this;
childnodes = node.childNodes;
Ext.each(childnodes, function () {
var nd = this;
idArray.push(nd.getId());
if (nd.hasChildNodes()) {
ts.GetChilds(idArray, nd);
}
});
}
//根据ID获取Node
var node=treepanel.getNodeById(node_id);
// treepanel.expandPath(node.getPath())
treepanel.getSelectionModel().select(node)