From 974c3c0eac2180d39f82b8672cb40d71f74b2ef6 Mon Sep 17 00:00:00 2001 From: ievavold <ievavold@wisc.edu> Date: Tue, 9 Apr 2019 10:18:41 -0500 Subject: [PATCH] ROENROLL-1586 add academic year from degree planner menu --- src/app/degree-planner/degree-planner.component.html | 3 +++ src/app/degree-planner/degree-planner.component.ts | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/src/app/degree-planner/degree-planner.component.html b/src/app/degree-planner/degree-planner.component.html index 09caf29..418891a 100644 --- a/src/app/degree-planner/degree-planner.component.html +++ b/src/app/degree-planner/degree-planner.component.html @@ -100,6 +100,9 @@ >settings</mat-icon> </button> <mat-menu #degreePlanMenu="matMenu"> + <button mat-menu-item (click)="onAddAcademicYear()"> + Add academic year + </button> <button mat-menu-item (click)="onRenamePlanClick(degreePlan)"> Rename plan </button> diff --git a/src/app/degree-planner/degree-planner.component.ts b/src/app/degree-planner/degree-planner.component.ts index af577d9..88ec16f 100644 --- a/src/app/degree-planner/degree-planner.component.ts +++ b/src/app/degree-planner/degree-planner.component.ts @@ -30,6 +30,7 @@ import { ConfirmDialogComponent } from '@app/shared/dialogs/confirm-dialog/confi import { CloseCourseSearch } from './store/actions/ui.actions'; import { YearCode } from '@app/core/models/termcode'; import { ConstantsService } from './services/constants.service'; +import { AddAcademicYearRequest } from './store/actions/addAcademicYear.actions'; @Component({ selector: 'cse-degree-planner', @@ -115,6 +116,10 @@ export class DegreePlannerComponent implements OnInit { }); } + public onAddAcademicYear() { + this.store.dispatch(new AddAcademicYearRequest()); + } + public onRenamePlanClick(currentPlan: DegreePlan) { this.dialog .open(PromptDialogComponent, { -- GitLab