mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
demo shell host setting component login redirect after setting
This commit is contained in:
@@ -19,6 +19,7 @@ import { Component, EventEmitter, Output, ViewEncapsulation, OnInit, Input } fro
|
||||
import { Validators, FormGroup, FormBuilder, AbstractControl, FormControl } from '@angular/forms';
|
||||
import { AppConfigService, AppConfigValues } from '../app-config/app-config.service';
|
||||
import { StorageService } from '../services/storage.service';
|
||||
import { AuthenticationService } from '../services/authentication.service';
|
||||
import { AlfrescoApiService } from '../services/alfresco-api.service';
|
||||
import { OauthConfigModel } from '../models/oauth-config.model';
|
||||
|
||||
@@ -66,6 +67,7 @@ export class HostSettingsComponent implements OnInit {
|
||||
|
||||
constructor(private formBuilder: FormBuilder,
|
||||
private storageService: StorageService,
|
||||
private authenticationService: AuthenticationService,
|
||||
private alfrescoApiService: AlfrescoApiService,
|
||||
private appConfig: AppConfigService) {
|
||||
}
|
||||
@@ -176,7 +178,11 @@ export class HostSettingsComponent implements OnInit {
|
||||
this.storageService.setItem(AppConfigValues.AUTHTYPE, values.authType);
|
||||
|
||||
this.alfrescoApiService.reset();
|
||||
this.success.emit(true);
|
||||
this.authenticationService.logout().subscribe(() => {
|
||||
this.success.emit(true);
|
||||
}, () => {
|
||||
this.success.emit(true);
|
||||
});
|
||||
}
|
||||
|
||||
private saveOAuthValues(values: any) {
|
||||
|
Reference in New Issue
Block a user