节点不一致导致加载失败问题
This commit is contained in:
parent
8ae400cef4
commit
0de1d9f28d
@ -83,7 +83,11 @@
|
|||||||
var layerIndex;
|
var layerIndex;
|
||||||
top.restAjax.get(top.restAjax.path('api/role/menu/list/{roleId}', [roleId]), {}, null, function(code, data) {
|
top.restAjax.get(top.restAjax.path('api/role/menu/list/{roleId}', [roleId]), {}, null, function(code, data) {
|
||||||
for(var i = 0, item; item = data[i++];) {
|
for(var i = 0, item; item = data[i++];) {
|
||||||
zTree.checkNode(zTree.getNodeByParam('menuId', item.menuId, null), true, false);
|
var node = zTree.getNodeByParam('menuId', item.menuId, null);
|
||||||
|
if(!node) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
zTree.checkNode(node, true, false);
|
||||||
}
|
}
|
||||||
}, function(code, data) {
|
}, function(code, data) {
|
||||||
top.dialog.msg(data.msg);
|
top.dialog.msg(data.msg);
|
||||||
|
Loading…
Reference in New Issue
Block a user