Created
November 19, 2020 15:37
-
-
Save chasebaker21/dd87ed94646e1efc32b63810a2206fb2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// sends data to project input dialog modal | |
// when closed the projectForm updates the day selected tasks | |
openProjectInputDialog(day: string, index: number, taskData: any, clientName: string, project: string, date: Date) { | |
const dialogRef = this.dialog.open(ProjectInputModalComponent, { | |
data: { | |
dayOfWeek: day, | |
taskData: taskData, | |
client: clientName, | |
currentProject: project, | |
date: date | |
} | |
}); | |
dialogRef.afterClosed().subscribe(results => { | |
if (results) { | |
let dayOfWeek = results.event; | |
this.tasksForm = results.data; | |
this.projectForm.get("projectTime").value[index].hoursHashMap[dayOfWeek] = this.tasksForm.value; | |
this.project.emit(this.projectForm); | |
} | |
}) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment