diff --git a/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.css b/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.css index 493c8b7b1..e69de29bb 100644 --- a/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.css +++ b/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.css @@ -1,9 +0,0 @@ -.view-all { - cursor: pointer; - color: rgb(106, 164, 217); - font-weight: 500; -} - -.view-all:hover { - color: rgb(46, 117, 182); -} diff --git a/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.html b/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.html index f884a86a1..5d90670ce 100644 --- a/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.html +++ b/dmp-frontend/src/app/ui/dashboard/info-counter/info-counter.component.html @@ -10,7 +10,7 @@ diff --git a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.css b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.css index 9c428ccaa..7f666f835 100644 --- a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.css +++ b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.css @@ -19,3 +19,4 @@ th { border-radius: 10em; text-align: center; } + diff --git a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.html b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.html index c955c4edf..63dfa42a9 100644 --- a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.html +++ b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.html @@ -8,7 +8,7 @@ {{ 'RECENT-ACTIVITY.LICENSE' | translate}}

- {{ 'GENERAL.ACTIONS.VIEW-ALL' | translate }} +
{{ 'GENERAL.ACTIONS.VIEW-ALL' | translate}}
@@ -23,7 +23,7 @@ - +
{{ activity.label }}
diff --git a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.ts b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.ts index 48695cdf4..53e94b5b3 100644 --- a/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.ts +++ b/dmp-frontend/src/app/ui/dashboard/recent-edited-activity/recent-edited-activity.component.ts @@ -5,6 +5,8 @@ import { AuthService } from '../../../core/services/auth/auth.service'; import { DataTableRequest } from '../../../core/model/data-table/data-table-request'; import { DmpCriteria } from '../../../core/query/dmp/dmp-criteria'; import { DmpService } from '../../../core/services/dmp/dmp.service'; +import { RecentActivityType } from '../../../core/common/enum/recent-activity-type'; +import { Router } from '@angular/router'; @Component({ selector: 'app-recent-edited-activity', @@ -13,8 +15,10 @@ import { DmpService } from '../../../core/services/dmp/dmp.service'; }) export class RecentEditedActivityComponent implements OnInit { dmpActivities: DmpListingModel[]; + recentActivityTypeEnum = RecentActivityType; constructor( + private router: Router, public enumUtils: EnumUtils, private authentication: AuthService, private dmpService: DmpService @@ -38,4 +42,24 @@ export class RecentEditedActivityComponent implements OnInit { return !!this.authentication.current(); } + redirect(id: string, type: RecentActivityType) { + switch (type) { + case RecentActivityType.Project: { + this.router.navigate(["projects/edit/" + id]); + return; + } + case RecentActivityType.Dataset: { + this.router.navigate(["datasets/edit/" + id]); + return; + } + case RecentActivityType.Dmp: { + this.router.navigate(["plans/edit/" + id]); + return; + } + default: + throw new Error("Unsupported Activity Type "); + } + } + + navigateToUrl() { } } diff --git a/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.html b/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.html index 780020d24..5ea9c1bbd 100644 --- a/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.html +++ b/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.html @@ -8,7 +8,8 @@ {{ 'RECENT-ACTIVITY.LICENSE' | translate}}

- {{ 'GENERAL.ACTIONS.VIEW-ALL' | translate }} +
+ {{ 'GENERAL.ACTIONS.VIEW-ALL' | translate}}
@@ -23,8 +24,7 @@ - +
{{ activity.label }}
diff --git a/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.ts b/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.ts index 2e9ee0ef9..562634d40 100644 --- a/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.ts +++ b/dmp-frontend/src/app/ui/dashboard/recent-visited-activity/recent-visited-activity.component.ts @@ -68,4 +68,6 @@ export class RecentVisitedActivityComponent extends BaseComponent public isAuthenticated(): boolean { return !!this.authentication.current(); } + + navigateToUrl() { } }