Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
setDataFromParent() {
this.dayOfWeek = this.data.dayOfWeek
this.timesheetHours = this.data.taskData.hours
this.projectDesc = this.data.currentProject
this.client = this.data.client
this.tasks = this.data.taskData.tasks
this.taskSeq = this.data.taskData.tasks.length
this.storageKey = this.projectDesc.concat(this.dayOfWeek);
this.taskData = this.data.taskData;
this.taskDate = this.data.date;
}
patchValues() {
this.taskForm.get('comments').patchValue(this.taskData.comments);
this.taskForm.get('day').patchValue(this.taskData.day);
this.taskForm.get('hours').patchValue(this.taskData.hours);
this.taskForm.get('oldHours').patchValue(this.taskData.oldHours);
this.taskForm.get('open').patchValue(this.taskData.open);
this.taskForm.get('tasks').patchValue(this.taskData.tasks);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment