From 922a71d07d270c6c29c506d40eed6c276ba43dd9 Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Wed, 22 Feb 2023 13:55:06 -0500 Subject: [PATCH] LP2006513 Angular login redirect repair The routeTo parameter must contain an eg2-based path (/staff/splash) and not a full path (/eg2/staff/splash) or URL. Signed-off-by: Bill Erickson Signed-off-by: Jane Sandberg --- Open-ILS/src/eg2/src/app/staff/resolver.service.ts | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Open-ILS/src/eg2/src/app/staff/resolver.service.ts b/Open-ILS/src/eg2/src/app/staff/resolver.service.ts index 225b931..69825a6 100644 --- a/Open-ILS/src/eg2/src/app/staff/resolver.service.ts +++ b/Open-ILS/src/eg2/src/app/staff/resolver.service.ts @@ -121,8 +121,8 @@ export class StaffResolver implements Resolve> { // valid auth token. Send the caller back to the login page. handleInvalidToken(state: RouterStateSnapshot): void { console.debug('StaffResolver: authtoken is not valid'); - const url = this.ngLocation.prepareExternalUrl(state.url); - this.router.navigate([LOGIN_PATH], {queryParams: {routeTo: url}}); + // state.url is the eg2 path, not a full URL. + this.router.navigate([LOGIN_PATH], {queryParams: {routeTo: state.url}}); this.observer.error('invalid or no auth token'); } -- 1.7.2.5