Merge branch 'master' of http://10.81.13.221:6990/Web/next-ucap-messenger
This commit is contained in:
commit
069d39aa8f
|
@ -5,7 +5,8 @@ import {
|
|||
ChangeDetectorRef,
|
||||
ViewChild,
|
||||
Output,
|
||||
EventEmitter
|
||||
EventEmitter,
|
||||
AfterViewInit
|
||||
} from '@angular/core';
|
||||
import { DeptInfo } from '@ucap-webmessenger/protocol-query';
|
||||
import { MatTreeNestedDataSource, MatTree } from '@angular/material';
|
||||
|
@ -45,7 +46,7 @@ export class OraganizationNode {
|
|||
templateUrl: './tree.component.html',
|
||||
styleUrls: ['./tree.component.scss']
|
||||
})
|
||||
export class TreeComponent implements OnInit {
|
||||
export class TreeComponent implements OnInit, AfterViewInit {
|
||||
@Output()
|
||||
selected = new EventEmitter<DeptInfo>();
|
||||
|
||||
|
@ -82,6 +83,7 @@ export class TreeComponent implements OnInit {
|
|||
});
|
||||
|
||||
this.dataSource.data = rootNodeList;
|
||||
this.treeControl.expand(this.dataSource.data[0]);
|
||||
}
|
||||
|
||||
@ViewChild('orgranizationTree', { static: true })
|
||||
|
@ -104,6 +106,8 @@ export class TreeComponent implements OnInit {
|
|||
|
||||
ngOnInit() {}
|
||||
|
||||
ngAfterViewInit(): void {}
|
||||
|
||||
getChildren = (node: OraganizationNode) => node.children;
|
||||
|
||||
hasChildren = (index: number, node: OraganizationNode) =>
|
||||
|
|
Loading…
Reference in New Issue
Block a user