Browse Source

[修改]修改显示隐藏消防要素tree传入数组

develop
邵佳豪 4 years ago
parent
commit
b0e7c560b9
  1. 16
      src/app/ui/collection-tools/collection-tools.component.ts

16
src/app/ui/collection-tools/collection-tools.component.ts

@ -673,6 +673,22 @@ export class CollectionToolsComponent implements OnInit {
this.dataSource.data = [...this.dataSource.data]
this.treeControl.expandAll()
let iconVisibleArr:any = []
if(node.isTemplate){//如果是模板,则开始向下找
node.children.forEach(item => {
if(item.isTemplate){//如果子节点依旧是模板,则继续开始向下找
item.children.forEach(i => {
iconVisibleArr.push(i.id)
})
}else{
iconVisibleArr.push(item.id)
}
})
}else{
iconVisibleArr.push(node.id)
}
this.canvas.setIconVisible(iconVisibleArr,!node.isLook)
}
//封装 刷新 tree 数据

Loading…
Cancel
Save