[ADF-3281] - fixed error when user try to involve people (#3538)

* [ADF-3281] moved current user retrieving in the constructor

* [ADF-3281] moved current user retrieving in the constructor #2
This commit is contained in:
Vito
2018-06-29 10:21:27 +01:00
committed by Eugenio Romano
parent a920c581df
commit d7faaf51b9
2 changed files with 9 additions and 6 deletions

View File

@@ -195,6 +195,9 @@ export class TaskDetailsComponent implements OnInit, OnChanges {
this.formRenderingService.setComponentTypeResolver('select-folder', () => AttachFolderWidgetComponent, true);
this.formRenderingService.setComponentTypeResolver('upload', () => AttachFileWidgetComponent, true);
this.peopleSearch = new Observable<UserProcessModel[]>(observer => this.peopleSearchObserver = observer).share();
this.authService.getBpmLoggedUser().subscribe((user: UserRepresentation) => {
this.currentLoggedUser = user;
});
}
ngOnInit() {
@@ -204,10 +207,6 @@ export class TaskDetailsComponent implements OnInit, OnChanges {
this.cardViewUpdateService.itemUpdated$.subscribe(this.updateTaskDetails.bind(this));
this.cardViewUpdateService.itemClicked$.subscribe(this.clickTaskDetails.bind(this));
this.authService.getBpmLoggedUser().subscribe((user: UserRepresentation) => {
this.currentLoggedUser = user;
});
}
ngOnChanges(changes: SimpleChanges): void {