diff --git a/src/app/features/administration/form/steps/step-four/step-four.component.html b/src/app/features/administration/form/steps/step-four/step-four.component.html
index 3f558e0b..e422c00f 100644
--- a/src/app/features/administration/form/steps/step-four/step-four.component.html
+++ b/src/app/features/administration/form/steps/step-four/step-four.component.html
@@ -39,7 +39,7 @@
diff --git a/src/app/features/administration/form/steps/step-four/step-four.component.ts b/src/app/features/administration/form/steps/step-four/step-four.component.ts
index 44bf652a..cb7f6b1e 100644
--- a/src/app/features/administration/form/steps/step-four/step-four.component.ts
+++ b/src/app/features/administration/form/steps/step-four/step-four.component.ts
@@ -51,25 +51,16 @@ export class StepFourComponent implements OnInit {
});
}
- addChoiceForDay(day_id, dayChoice: DateChoice): void {
+ addChoiceHourForDay(day_id, dayChoice: DateChoice): void {
let lastDateChoice = this.pollService.dateChoiceList[this.pollService.dateChoiceList.length];
- let lastDateChoiceObject = this.dateUtilitiesService.addDaysToDate(
- this.pollService.dateChoiceList.length,
- new Date()
- );
- if (lastDateChoice && lastDateChoice.date_object) {
- lastDateChoiceObject = lastDateChoice.date_object;
- } else {
- lastDateChoiceObject = new Date();
- }
dayChoice.timeSlices.push({
literal: '',
});
dayChoice.timeSlices.sort((a: any, b: any) => {
return a.date_object - b.date_object;
});
- this.focusOnChoice(day_id, this.storageService.dateChoices.length - 1);
+ this.focusOnChoice(day_id, dayChoice.timeSlices.length - 1);
}
focusOnChoice(day_id, index): void {