郫都大屏

This commit is contained in:
yanran200730
2022-08-01 09:52:37 +08:00
parent e3b9eca251
commit d918bbe8b3

View File

@@ -114,9 +114,7 @@
if (res.code === 0) { if (res.code === 0) {
this.treeData = res.data.filter(e => !e.parentGirdId) this.treeData = res.data.filter(e => !e.parentGirdId)
const parentGirdId = this.treeData[0].id const parentGirdId = this.treeData[0].id
const arr = res.data.filter(v => {
return v.parentGirdId === parentGirdId || !v.parentGirdId
})
this.treeData.map(p => this.addChild(p, res.data.map(v => { this.treeData.map(p => this.addChild(p, res.data.map(v => {
if (v.id === parentGirdId) { if (v.id === parentGirdId) {
this.defaultExpandedKeys.push(v.id) this.defaultExpandedKeys.push(v.id)