mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-1138] Start Task Form Assignee dropdown show null value inside (#2118)
* [ADF-1138] Start Task Form Assignee dropdown show null value inside * Changed Form Assignee dropdown show null value. * [ADF-1138] Start Task Form Assignee dropdown show null value inside * Refactored unit testcases.
This commit is contained in:
committed by
Eugenio Romano
parent
2e3b081bc4
commit
d5bdadde0d
@@ -119,4 +119,18 @@ export class StartTaskComponent implements OnInit {
|
||||
this.logService.error('Could not load users');
|
||||
});
|
||||
}
|
||||
|
||||
isUserNameEmpty(user: any) {
|
||||
return !user || (this.isEmpty(user.firstName) && this.isEmpty(user.lastName));
|
||||
}
|
||||
|
||||
private isEmpty(data: string) {
|
||||
return data === undefined || data === null || data.trim().length === 0;
|
||||
}
|
||||
|
||||
getDisplayUser(firstName: string, lastName: string, delimiter: string = '-'): string {
|
||||
firstName = (firstName !== null ? firstName : '');
|
||||
lastName = (lastName !== null ? lastName : '');
|
||||
return firstName + delimiter + lastName;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user