From 2ec7924e86e70224c422ff9b247f888f99045a9e Mon Sep 17 00:00:00 2001 From: Daniel Ponte Date: Wed, 6 Nov 2024 20:51:21 -0500 Subject: [PATCH] Fix login form --- client/admin/src/app/app.component.html | 24 ++++++++++++++++++++++ client/admin/src/app/login/auth.service.ts | 2 +- 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/client/admin/src/app/app.component.html b/client/admin/src/app/app.component.html index 7e3a0a0..b95b36f 100644 --- a/client/admin/src/app/app.component.html +++ b/client/admin/src/app/app.component.html @@ -194,6 +194,21 @@ } +@else { +
+ +
+} @@ -285,8 +300,17 @@ +@if (auth.loggedIn) {
+} +@else { +
+
+ +
+
+} diff --git a/client/admin/src/app/login/auth.service.ts b/client/admin/src/app/login/auth.service.ts index f637668..ecb05f7 100644 --- a/client/admin/src/app/login/auth.service.ts +++ b/client/admin/src/app/login/auth.service.ts @@ -27,7 +27,7 @@ export class AuthService { login(username: string, password: string): Observable> { return this.http .post( - '/login', + '/api/login', { username: username, password: password }, { observe: 'response' }, )