Fix login form
This commit is contained in:
parent
558a57e797
commit
2ec7924e86
2 changed files with 25 additions and 1 deletions
|
@ -194,6 +194,21 @@
|
|||
</nav>
|
||||
</header>
|
||||
}
|
||||
@else {
|
||||
<div class="relative flex flex-col h-full max-h-full">
|
||||
<div class="px-6 pt-4">
|
||||
<!-- Logo -->
|
||||
<a
|
||||
class="stillboxLogo flex-none rounded-xl text-xl inline-block font-semibold focus:outline-none focus:opacity-80"
|
||||
href="#"
|
||||
aria-label="Stillbox"
|
||||
>
|
||||
Stillbox
|
||||
</a>
|
||||
<!-- End Logo -->
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
<!-- ========== END HEADER ========== -->
|
||||
|
||||
<!-- Sidebar -->
|
||||
|
@ -285,8 +300,17 @@
|
|||
<!-- End Sidebar -->
|
||||
|
||||
<!-- Content -->
|
||||
@if (auth.loggedIn) {
|
||||
<div class="w-full lg:ps-64">
|
||||
<div class="p-4 sm:p-6 space-y-4 sm:space-y-6">
|
||||
<router-outlet />
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
@else {
|
||||
<div class="w-full">
|
||||
<div class="p-4 sm:p-6 space-y-4 sm:space-y-6">
|
||||
<router-outlet />
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
|
|
|
@ -27,7 +27,7 @@ export class AuthService {
|
|||
login(username: string, password: string): Observable<HttpResponse<Jwt>> {
|
||||
return this.http
|
||||
.post<Jwt>(
|
||||
'/login',
|
||||
'/api/login',
|
||||
{ username: username, password: password },
|
||||
{ observe: 'response' },
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue