This commit is contained in:
Edouard DUPIN 2022-06-06 14:57:24 +02:00
parent a4f6dd5756
commit 783ccf091a
3 changed files with 13 additions and 3 deletions

View File

@ -37,7 +37,14 @@ export class AppComponent implements OnInit {
self.autoConnectedDone = true;
});
this.userService.checkAutoConnect().finally(() => {
this.userService.checkAutoConnect().then(() => {
console.log(` ==>>>>> Autoconnect THEN !!!`);
self.autoConnectedDone = true;
}).catch(() => {
console.log(` ==>>>>> Autoconnect CATCH !!!`);
self.autoConnectedDone = true;
}).finally(() => {
console.log(` ==>>>>> Autoconnect FINALLY !!!`);
self.autoConnectedDone = true;
});
}

View File

@ -29,7 +29,7 @@ export class SsoScene implements OnInit {
ngOnInit() {
let self = this;
console.error("retreive data after SSO ng-init");
console.error("retreive data after SSO back");
const ssoData = this.route.snapshot.paramMap.get('data');
if (ssoData == null) {
this.ssoData = undefined;

View File

@ -84,7 +84,10 @@ export class UserService {
return new Promise<void>((resolve, reject) => {
// Need to use the windows global route to prevent the log in cycle ...
// And in the mlain application position, the route does not have curently root the page
if (window.location.pathname.startsWith("/sso/")) {
let pathName = window.location.pathname;
console.log("start Path-name: '" + pathName + "'");
if (pathName.startsWith("/sso/") || pathName.startsWith(environment.applName + "/sso/")) {
console.log(" ==> SSo section");
reject();
return;
}