From 66775cd1d45f179ff33013a7ad60cef99e392322 Mon Sep 17 00:00:00 2001 From: Anika Tibrewala <62497183+anika-001@users.noreply.github.com> Date: Sun, 27 Nov 2022 12:55:04 +0530 Subject: [PATCH] fixes issue 1556 (#1574) Co-authored-by: Anika Tibrewala <89638069+Ann-001@users.noreply.github.com> --- src/app/home/dashboard/dashboard.component.html | 3 +-- src/app/home/dashboard/dashboard.component.ts | 11 ++++++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/app/home/dashboard/dashboard.component.html b/src/app/home/dashboard/dashboard.component.html index 3e10d390a..59f61d483 100644 --- a/src/app/home/dashboard/dashboard.component.html +++ b/src/app/home/dashboard/dashboard.component.html @@ -13,8 +13,7 @@ - + diff --git a/src/app/home/dashboard/dashboard.component.ts b/src/app/home/dashboard/dashboard.component.ts index d7ba1de2d..d1b73e67c 100644 --- a/src/app/home/dashboard/dashboard.component.ts +++ b/src/app/home/dashboard/dashboard.component.ts @@ -1,5 +1,6 @@ /** Angular Imports */ import { Component, OnInit } from '@angular/core'; +import { Router } from '@angular/router'; /** * Dashboard component. @@ -21,7 +22,7 @@ export class DashboardComponent implements OnInit { /** * Gets user activities from local storage. */ - constructor() { + constructor(private router: Router) { this.userActivity = JSON.parse(localStorage.getItem('mifosXLocation')); } @@ -67,4 +68,12 @@ export class DashboardComponent implements OnInit { return topEigthFrequentActivities; } + /** + * Navigates to the activity + */ + navigatetoActivity(activity:string){ + this.router.navigateByUrl(activity); + } + } +