Commit e989a1523787d2a702c87a448e9c64f116f657a5

Authored by fengtao
1 parent 386440a9

fix:修改菜单管理 树组件回显问题

... ... @@ -10,11 +10,11 @@ export function listToTree(lists: getMenuListResultModel): getMenuListResultMode
10 10
11 11 // console.log(goods.children?.length);
12 12 if (goods.children?.length) {
13   - goods.children.forEach((goodChildren) => {
14   - goodChildren['menuName'] = t(goodChildren.meta.title); // 为goodChildren添加属性menuName
15   - });
  13 + listToTree(goods.children);
  14 + // goods.children.forEach((goodChildren) => {
  15 + // goodChildren['menuName'] = t(goodChildren.meta.title); // 为goodChildren添加属性menuName
  16 + // });
16 17 }
17 18 });
18   -
19 19 return lists;
20 20 }
... ...
... ... @@ -73,7 +73,7 @@
73 73 menuId = Reflect.get(data.record, 'id');
74 74 }
75 75 //加载菜单
76   - let treeData = await getMenuList();
  76 + let treeData = await getMenuList(1);
77 77 treeData = listToTree(treeData);
78 78 updateSchema({
79 79 field: 'parentId',
... ...