Commit ffcf84ed authored by Mickaël Guessant's avatar Mickaël Guessant

Caldav: EWS refactoring, handle mozilla alarm fields

git-svn-id: https://svn.code.sf.net/p/davmail/code/trunk@2522 3d1905a2-6b24-0410-a738-b14d5a86fcbd
parent 08b4197f
......@@ -1624,7 +1624,12 @@ public class EwsExchangeSession extends ExchangeSession {
protected void handleModifiedOccurrences(ItemId currentItemId, VCalendar vCalendar) throws DavMailException {
for (VObject modifiedOccurrence : vCalendar.getModifiedOccurrences()) {
VProperty originalDateProperty = modifiedOccurrence.getProperty("RECURRENCE-ID");
String convertedValue = vCalendar.convertCalendarDateToExchangeZulu(originalDateProperty.getValue(), originalDateProperty.getParamValue("TZID"));
String convertedValue = null;
try {
convertedValue = vCalendar.convertCalendarDateToExchangeZulu(originalDateProperty.getValue(), originalDateProperty.getParamValue("TZID"));
} catch (IOException e) {
throw new DavMailException("EXCEPTION_INVALID_DATE", originalDateProperty.getValue());
}
LOGGER.debug("Looking for occurrence " + convertedValue);
int instanceIndex = 0;
......@@ -1772,6 +1777,21 @@ public class EwsExchangeSession extends ExchangeSession {
}
}
// store mozilla invitations option
String xMozSendInvitations = vCalendar.getFirstVeventPropertyValue("X-MOZ-SEND-INVITATIONS");
if (xMozSendInvitations != null) {
updates.add(Field.createFieldUpdate("xmozsendinvitations", xMozSendInvitations));
}
// handle mozilla alarm
String xMozLastack = vCalendar.getFirstVeventPropertyValue("X-MOZ-LASTACK");
if (xMozLastack != null) {
updates.add(Field.createFieldUpdate("xmozlastack", xMozLastack));
}
String xMozSnoozeTime = vCalendar.getFirstVeventPropertyValue("X-MOZ-SNOOZE-TIME");
if (xMozSnoozeTime != null) {
updates.add(Field.createFieldUpdate("xmozsnoozetime", xMozSnoozeTime));
}
return updates;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment