fix: set field before using
This commit is contained in:
parent
660f251b40
commit
8c9b798bff
@ -45,13 +45,13 @@ export class ScheduleComponent {
|
||||
@ViewChild('tableHeader') childComponent!: TableHeaderComponent;
|
||||
|
||||
constructor(api: ScheduleService) {
|
||||
this.calculateCurrentWeek();
|
||||
this.startTerm = new Date(1, 1, 1);
|
||||
api.pairPeriod().subscribe(date => {
|
||||
this.pairPeriods = date;
|
||||
});
|
||||
api.startTerm().subscribe(date => {
|
||||
this.startTerm = date.date;
|
||||
this.calculateCurrentWeek();
|
||||
});
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user