fix(console): set user language (#4028)

fix: cnsl user language

Co-authored-by: Livio Spring <[email protected]>
This commit is contained in:
Max Peintner
2022-07-26 07:30:54 +00:00
committed by GitHub
co-authored by Livio Spring
parent 9347a196c0
commit e8a01abcdb
4 changed files with 129 additions and 88 deletions
@@ -43,7 +43,7 @@ function passwordConfirmValidator(c: AbstractControl): any {
export class UserCreateComponent implements OnDestroy {
public user: AddHumanUserRequest.AsObject = new AddHumanUserRequest().toObject();
public genders: Gender[] = [Gender.GENDER_FEMALE, Gender.GENDER_MALE, Gender.GENDER_UNSPECIFIED];
public languages: string[] = ['de', 'en'];
public languages: string[] = ['de', 'en', 'it', 'fr'];
public userForm!: UntypedFormGroup;
public pwdForm!: UntypedFormGroup;
@@ -94,6 +94,10 @@ export class UserCreateComponent implements OnDestroy {
this.envSuffixLabel = this.envSuffix();
this.changeDetRef.detectChanges();
});
this.mgmtService.getSupportedLanguages().then((lang) => {
this.languages = lang.languagesList;
});
}
public close(): void {