dev env setup

This commit is contained in:
tw-blue
2025-12-06 21:27:29 +01:00
parent 987a380758
commit bc9f0f9f3b
38 changed files with 5953 additions and 733 deletions
@@ -1 +1,14 @@
<p>home works!</p>
<h1>Startseite</h1>
<ul>
<!--TODO fix theming/colors-->
<button matButton="outlined" class="warn-button" [routerLink]="['/test']">
Entwichlungsinformationen
</button>
<button matButton="filled" color="primary" [routerLink]="['/list']">Mitglieder</button>
<button matButton="filled" color="warn" [routerLink]="['/manageUsers']">
Benutzer Verwalten
</button>
<button matButton="filled" color="primary" [routerLink]="['/exam']">
Prüfungsanmeldung
</button>
</ul>
@@ -1,8 +1,10 @@
import { Component } from '@angular/core';
import { MatButtonModule } from '@angular/material/button';
import { RouterModule } from '@angular/router';
@Component({
selector: 'app-home',
imports: [],
imports: [RouterModule, MatButtonModule],
templateUrl: './home.html',
styleUrl: './home.scss',
})
@@ -1,4 +1,5 @@
import { Component, inject } from '@angular/core';
import { Router } from '@angular/router';
import { Authentication } from '../../services/authentication';
@Component({
@@ -9,7 +10,13 @@ import { Authentication } from '../../services/authentication';
})
export class Login {
private readonly authentication = inject(Authentication);
private readonly router = inject(Router);
public constructor() {
this.authentication.login();
if(this.authentication.loggedIn()){
this.router.navigate(['/home']);
}else{
this.authentication.login();
}
}
}