mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
Do redirect before implicit button (#6574)
* Do redirect before implicit * Add unit to implicit and silent * Keep the value as it was before
This commit is contained in:
@@ -156,12 +156,10 @@ export class LoginComponent implements OnInit, OnDestroy {
|
||||
|
||||
if (this.authService.isOauth()) {
|
||||
const oauth: OauthConfigModel = this.appConfig.get<OauthConfigModel>(AppConfigValues.OAUTHCONFIG, null);
|
||||
if (oauth && oauth.implicitFlow) {
|
||||
this.implicitFlow = true;
|
||||
}
|
||||
|
||||
if (oauth && oauth.silentLogin) {
|
||||
this.alfrescoApiService.getInstance().oauth2Auth.implicitLogin();
|
||||
this.redirectToImplicitLogin();
|
||||
} else if (oauth && oauth.implicitFlow) {
|
||||
this.implicitFlow = true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -191,6 +189,10 @@ export class LoginComponent implements OnInit, OnDestroy {
|
||||
this.onSubmit(this.form.value);
|
||||
}
|
||||
|
||||
redirectToImplicitLogin() {
|
||||
this.alfrescoApiService.getInstance().oauth2Auth.implicitLogin();
|
||||
}
|
||||
|
||||
/**
|
||||
* Method called on submit form
|
||||
* @param values
|
||||
|
Reference in New Issue
Block a user