Display the configured OIDC provider name on the login button
This commit is contained in:
committed by
Aditya Chandel
parent
d348728f74
commit
d7beb1ae80
@@ -30,7 +30,7 @@
|
|||||||
@if (oidcEnabled) {
|
@if (oidcEnabled) {
|
||||||
<div>
|
<div>
|
||||||
<p-divider></p-divider>
|
<p-divider></p-divider>
|
||||||
<p-button fluid severity="info" type="button" label="Login with OIDC" icon="pi pi-id-card" (click)="loginWithOidc()"></p-button>
|
<p-button fluid severity="info" type="button" label="Login with {{oidcName}}" icon="pi pi-id-card" (click)="loginWithOidc()"></p-button>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ export class LoginComponent implements OnInit {
|
|||||||
password = '';
|
password = '';
|
||||||
errorMessage = '';
|
errorMessage = '';
|
||||||
oidcEnabled = false;
|
oidcEnabled = false;
|
||||||
|
oidcName = 'OIDC';
|
||||||
|
|
||||||
private authService = inject(AuthService);
|
private authService = inject(AuthService);
|
||||||
private oAuthService = inject(OAuthService);
|
private oAuthService = inject(OAuthService);
|
||||||
@@ -51,7 +52,8 @@ export class LoginComponent implements OnInit {
|
|||||||
take(1)
|
take(1)
|
||||||
)
|
)
|
||||||
.subscribe(settings => {
|
.subscribe(settings => {
|
||||||
this.oidcEnabled = settings?.oidcEnabled;
|
this.oidcEnabled = settings!.oidcEnabled;
|
||||||
|
this.oidcName = settings!.oidcProviderDetails?.providerName || 'OIDC';
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user