Skip to content

Commit

Permalink
Merge branch 'devel' into DEV-160-ProjectNavigation
Browse files Browse the repository at this point in the history
  • Loading branch information
szymonpoltorak authored Mar 19, 2024
2 parents 3789d36 + 21606fc commit 6f46a54
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions corn-frontend/src/app/core/enum/RouterPaths.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ export enum RouterPaths {
HOME_DIRECT_PATH = "/home",

BOARDS_PATH = "boards",

PROJECT_LIST_PATH = "projects",
PROJECT_LIST_DIRECT_PATH = "/projects",

UNKNOWN_PATH = "**"
}
4 changes: 2 additions & 2 deletions corn-frontend/src/app/pages/home/home.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { Feature } from "@core/interfaces/home/feature.interface";
import { KeycloakService } from 'keycloak-angular';
import { CommonModule, NgOptimizedImage } from '@angular/common';
import { Router } from '@angular/router';
import { RouterPaths } from "@core/enum/RouterPaths";

@Component({
selector: 'app-home',
Expand Down Expand Up @@ -35,8 +36,7 @@ export class HomeComponent implements OnInit {

ngOnInit() {
if (this.keycloak.isLoggedIn()) {
//TODO implement proper auth guard
this.router.navigate(['/boards/backlog']);
this.router.navigate([`${RouterPaths.PROJECT_LIST_DIRECT_PATH}`]);
}
}

Expand Down

0 comments on commit 6f46a54

Please sign in to comment.