mirror of
https://gitee.com/JavaLionLi/plus-ui.git
synced 2025-08-29 08:53:55 +00:00
Compare commits
2 Commits
ae5dd09ba2
...
ad7058b739
Author | SHA1 | Date | |
---|---|---|---|
![]() |
ad7058b739 | ||
![]() |
0dd5044bbe |
@@ -44,6 +44,7 @@
|
||||
:default-expand-all="false"
|
||||
lazy
|
||||
:load="getChildrenList"
|
||||
:expand-change="expandMenuHandle"
|
||||
>
|
||||
<el-table-column prop="menuName" label="菜单名称" :show-overflow-tooltip="true" width="160"></el-table-column>
|
||||
<el-table-column prop="icon" label="图标" align="center" width="100">
|
||||
@@ -353,6 +354,13 @@ const getChildrenList = async (row: any, treeNode: unknown, resolve: (data: any[
|
||||
resolve(children);
|
||||
};
|
||||
|
||||
/** 收起菜单时从menuExpandMap中删除对应菜单id数据 */
|
||||
const expandMenuHandle = async (row: any, expanded: boolean) => {
|
||||
if (!expanded) {
|
||||
menuExpandMap.value[row.menuId] = undefined;
|
||||
}
|
||||
};
|
||||
|
||||
/** 刷新展开的菜单数据 */
|
||||
const refreshLoadTree = (parentId: string | number) => {
|
||||
if (menuExpandMap.value[parentId]) {
|
||||
|
Reference in New Issue
Block a user