Skip to content

Commit

Permalink
fix: fix monthly/yearly events are ko with outlookConnector - EXO-69013
Browse files Browse the repository at this point in the history
… (#102)

Before this change, Monthly and Yearly events are not added to the outlook agenda since the recurrent event properties are not well set and some ones are missed
After this change, the properties are well set and the events are well-displayed
  • Loading branch information
GouadriaHanen authored Jan 26, 2024
1 parent 3ac57ce commit d96de29
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,14 @@ function buildConnectorEvent(event) {
connectorEvent.recurrence.pattern.firstDayOfWeek = 'monday';
}
if (daysOfMonth) {
connectorEvent.recurrence.pattern.daysOfMonth = daysOfMonth;
if (recurrenceType === 'absoluteMonthly') {
connectorEvent.recurrence.pattern.dayOfMonth = daysOfMonth[0];
} else if (recurrenceType === 'absoluteYearly') {
connectorEvent.recurrence.pattern.dayOfMonth = daysOfMonth[0];
connectorEvent.recurrence.pattern.month = event.recurrence?.byMonth[0];
} else {
connectorEvent.recurrence.pattern.daysOfMonth = daysOfMonth;
}
}
if (event.recurrence.count) {
connectorEvent.recurrence.range.numberOfOccurrences = event.recurrence.count;
Expand Down

0 comments on commit d96de29

Please sign in to comment.