Skip to content

Commit f54da40

Browse files
authored
Merge pull request #2033 from bcgov/bugfix/ALCS-2446-set-date-type-default
ALCS-2446 Set single date as default if date is not checked
2 parents ae6842a + ec14404 commit f54da40

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

alcs-frontend/src/app/features/admin/decision-condition-types/decision-condition-types-dialog/decision-condition-types-dialog.component.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export class DecisionConditionTypesDialogComponent {
9191
[this.conditionAsyncValidator(ValidationFields.Dates)],
9292
),
9393
isDateRequired: new FormControl(this.data?.content?.isDateRequired ? this.data.content.isDateRequired : false),
94-
dateType: new FormControl(this.data?.content?.dateType),
94+
dateType: new FormControl((!this.data?.content?.isDateChecked && !this.data?.content?.dateType) ? DateType.SINGLE : this.data?.content?.dateType),
9595
singleDateLabel: new FormControl(
9696
this.data?.content?.singleDateLabel ? this.data.content.singleDateLabel : DateLabel.DUE_DATE,
9797
),

0 commit comments

Comments
 (0)