From 2798b6472d34f1bfbb8388c65b6c09cd8807fc8e Mon Sep 17 00:00:00 2001 From: Derek Holloway Date: Tue, 29 Jul 2025 18:03:52 -0700 Subject: [PATCH] Setup login page for public use --- src/Client/src/app/pages/account/login/login.component.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Client/src/app/pages/account/login/login.component.ts b/src/Client/src/app/pages/account/login/login.component.ts index 751f5ed..d387b3d 100644 --- a/src/Client/src/app/pages/account/login/login.component.ts +++ b/src/Client/src/app/pages/account/login/login.component.ts @@ -43,13 +43,14 @@ export class LoginComponent { } this.errorMsgs.push("Waiting for response from server"); - this.auth.Login(this.UserName, this.Password, this.StayLoggedIn).subscribe({ + this.http.post( "https://auth.mistox.com/api/auth/login", { "UserName": this.UserName, "Password": this.Password, "StayLoggedIn": this.StayLoggedIn }, { responseType: 'text' } ).subscribe({ next: data => { - this.router.navigate([this.returnURL]); + this.errorMsgs = [ "Login Token: " + data ]; + window.location.href = this.returnURL + "?LoginToken=" + data; }, error: err => { this.errorMsgs = [ err.error ]; } - }) + }); } } \ No newline at end of file