mb-tree回显bug,优化搜索,菜单只有第一级的时候出现bug修复

This commit is contained in:
吕金泽
2022-04-10 10:48:49 +08:00
parent e17637c0b8
commit d8e5372054
8 changed files with 142 additions and 161 deletions
@@ -5,7 +5,7 @@
"groupId" : "67b2ce258e24491194b74992958c74aa",
"name" : "当前用户菜单",
"createTime" : null,
"updateTime" : 1648013721548,
"updateTime" : 1649558286068,
"lock" : "0",
"createBy" : null,
"updateBy" : null,
@@ -598,6 +598,14 @@ nodes.each((key, node) => {
var treeNodes = []
nodes.each((key, node) => {
if(node.pid == '0'){
if(node.component != 'Layout'){
node = {
isShow: 1,
component: 'Layout',
redirect: node.path,
children: [node]
}
}
treeNodes.push(node)
}
})