Forum Discussion
bojanvelevski
4 months agoValued Contributor
Hi SL12345 ,
Map your blackout dates in the following format and with the following expressions:
[].concat($schedule.repeat.get('blackout_datetimes') == null ? [] : $schedule.repeat.blackout_datetimes ,[{startDate:"2025-06-04",startTime:"00:00",endDate:"2025-06-05",endTime:"00:00"}])
You always start with an empty array, followed by a concat function with 2 arguments, the blackout_datetimes , which is extended with a ternary expression to check whether the array exists or not, and the blackout date times array you want to add.
This will safely update your blackoud dates with any overwriting of the previous ones.
Let me know if this helps.
Regards,
Bojan