mirror of
https://github.com/zitadel/zitadel.git
synced 2025-02-28 20:27:23 +00:00
fix(console): show loginname suffix correctly (#4649)
fix: suffix in user-create
This commit is contained in:
parent
b3d2892e4c
commit
5c807a0660
@ -30,7 +30,7 @@
|
|||||||
required
|
required
|
||||||
[ngStyle]="{ 'padding-right': suffixPadding ? suffixPadding : '10px' }"
|
[ngStyle]="{ 'padding-right': suffixPadding ? suffixPadding : '10px' }"
|
||||||
/>
|
/>
|
||||||
<span #suffix *ngIf="envSuffixLabel" cnslSuffix>{{ envSuffixLabel }}</span>
|
<span #suffix *ngIf="envSuffix" cnslSuffix>{{ envSuffix }}</span>
|
||||||
|
|
||||||
<span cnslError *ngIf="userName?.invalid && userName?.errors?.required">
|
<span cnslError *ngIf="userName?.invalid && userName?.errors?.required">
|
||||||
{{ 'USER.VALIDATION.REQUIRED' | translate }}
|
{{ 'USER.VALIDATION.REQUIRED' | translate }}
|
||||||
|
@ -46,8 +46,6 @@ export class UserCreateComponent implements OnDestroy {
|
|||||||
public languages: string[] = ['de', 'en', 'it', 'fr'];
|
public languages: string[] = ['de', 'en', 'it', 'fr'];
|
||||||
public userForm!: UntypedFormGroup;
|
public userForm!: UntypedFormGroup;
|
||||||
public pwdForm!: UntypedFormGroup;
|
public pwdForm!: UntypedFormGroup;
|
||||||
|
|
||||||
public envSuffixLabel: string = '';
|
|
||||||
private destroyed$: Subject<void> = new Subject();
|
private destroyed$: Subject<void> = new Subject();
|
||||||
|
|
||||||
public userLoginMustBeDomain: boolean = false;
|
public userLoginMustBeDomain: boolean = false;
|
||||||
@ -84,14 +82,12 @@ export class UserCreateComponent implements OnDestroy {
|
|||||||
}
|
}
|
||||||
this.initForm();
|
this.initForm();
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.envSuffixLabel = this.envSuffix();
|
|
||||||
this.changeDetRef.detectChanges();
|
this.changeDetRef.detectChanges();
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
this.initForm();
|
this.initForm();
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.envSuffixLabel = this.envSuffix();
|
|
||||||
this.changeDetRef.detectChanges();
|
this.changeDetRef.detectChanges();
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -249,7 +245,8 @@ export class UserCreateComponent implements OnDestroy {
|
|||||||
public get confirmPassword(): AbstractControl | null {
|
public get confirmPassword(): AbstractControl | null {
|
||||||
return this.pwdForm.get('confirmPassword');
|
return this.pwdForm.get('confirmPassword');
|
||||||
}
|
}
|
||||||
private envSuffix(): string {
|
|
||||||
|
public get envSuffix(): string {
|
||||||
if (this.userLoginMustBeDomain && this.primaryDomain?.domainName) {
|
if (this.userLoginMustBeDomain && this.primaryDomain?.domainName) {
|
||||||
return `@${this.primaryDomain.domainName}`;
|
return `@${this.primaryDomain.domainName}`;
|
||||||
} else {
|
} else {
|
||||||
|
@ -868,7 +868,7 @@
|
|||||||
"GENERAL": "Generale",
|
"GENERAL": "Generale",
|
||||||
"LOGIN": "Comportamento login e sicurezza",
|
"LOGIN": "Comportamento login e sicurezza",
|
||||||
"LOCKOUT": "Meccanismi di bloccaggio",
|
"LOCKOUT": "Meccanismi di bloccaggio",
|
||||||
"COMPLEXITY": "complessità della password",
|
"COMPLEXITY": "Complessità della password",
|
||||||
"NOTIFICATIONS": "Notifiche",
|
"NOTIFICATIONS": "Notifiche",
|
||||||
"NOTIFICATIONS_DESC": "Impostazioni SMTP e SMS",
|
"NOTIFICATIONS_DESC": "Impostazioni SMTP e SMS",
|
||||||
"MESSAGETEXTS": "Testi di notifica",
|
"MESSAGETEXTS": "Testi di notifica",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user