301-角色管理-配置法规库树结构权限和配置法规库数据权限,默认展开形式调整。
This commit is contained in:
@@ -171,7 +171,7 @@
|
||||
:data="treeData3"
|
||||
:props="defaultProps3"
|
||||
:default-checked-keys="nodeList2"
|
||||
default-expand-all
|
||||
:default-expanded-keys="defaultExpandedKeys"
|
||||
highlight-current
|
||||
:expand-on-click-node="false"
|
||||
:show-checkbox="true"
|
||||
@@ -202,7 +202,7 @@
|
||||
:data="treeData4"
|
||||
:props="defaultProps3"
|
||||
:default-checked-keys="nodeList4"
|
||||
default-expand-all
|
||||
:default-expanded-keys="defaultExpandedKeys"
|
||||
highlight-current
|
||||
:expand-on-click-node="false"
|
||||
:show-checkbox="true"
|
||||
@@ -468,7 +468,8 @@ export default {
|
||||
children: 'children',
|
||||
label: 'menuName'
|
||||
},
|
||||
nodeList: []
|
||||
nodeList: [],
|
||||
defaultExpandedKeys:[]//默认展开的key
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -685,6 +686,8 @@ export default {
|
||||
this.treeData4 = this.sortByKey(list1,"displaySeq")
|
||||
}
|
||||
|
||||
// 默认展开的key
|
||||
this.defaultExpandedKeys = list1.map(item=>item.id)
|
||||
|
||||
},
|
||||
sortByKey(ary, key) {
|
||||
|
||||
Reference in New Issue
Block a user