From f2527bfde3d4b1f8eb59ecd9e125d57c14e49c03 Mon Sep 17 00:00:00 2001 From: Wolfgang Sourdeau Date: Wed, 16 Jul 2008 21:47:18 +0000 Subject: [PATCH] Monotone-Parent: 2ddcd15039e17a87969eaaf79e013a0f2d393679 Monotone-Revision: 1d8390cb8afe22fe543231383205ab7e41337609 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2008-07-16T21:47:18 Monotone-Branch: ca.inverse.sogo --- SoObjects/Appointments/SOGoAppointmentFolder.m | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/SoObjects/Appointments/SOGoAppointmentFolder.m b/SoObjects/Appointments/SOGoAppointmentFolder.m index 5131dc99a..980b43e2f 100644 --- a/SoObjects/Appointments/SOGoAppointmentFolder.m +++ b/SoObjects/Appointments/SOGoAppointmentFolder.m @@ -64,7 +64,6 @@ #import #import #import -#import #import "iCalEntityObject+SOGo.h" #import "SOGoAppointmentObject.h" @@ -566,6 +565,9 @@ static Class sogoAppointmentFolderKlass = Nil; unsigned int count; NSCalendarDate *date; NSNumber *dateValue; + BOOL isAllDay; + + isAllDay = [[_record objectForKey: @"c_isallday"] boolValue]; md = [[_record mutableCopy] autorelease]; for (count = 0; count < 2; count++) @@ -573,8 +575,7 @@ static Class sogoAppointmentFolderKlass = Nil; dateValue = [_record objectForKey: fields[count * 2]]; if (dateValue) { - date = [NSCalendarDate dateWithTimeIntervalSince1970: - (NSTimeInterval) [dateValue unsignedIntValue]]; + date = [NSCalendarDate dateWithTimeIntervalSince1970: (NSTimeInterval) [dateValue unsignedIntValue]]; if (date) { [date setTimeZone: timeZone]; @@ -582,7 +583,7 @@ static Class sogoAppointmentFolderKlass = Nil; } } else - [self logWithFormat:@"missing '%@' in record?", fields[count * 2]]; + [self logWithFormat: @"missing '%@' in record?", fields[count * 2]]; } return md; @@ -926,9 +927,11 @@ static Class sogoAppointmentFolderKlass = Nil; /* prepare mandatory fields */ fields = [NSMutableArray arrayWithArray: _fields]; - [fields addObject: @"c_uid"]; - [fields addObject: @"c_startdate"]; - [fields addObject: @"c_enddate"]; + [fields addObjectUniquely: @"c_name"]; + [fields addObjectUniquely: @"c_uid"]; + [fields addObjectUniquely: @"c_startdate"]; + [fields addObjectUniquely: @"c_enddate"]; + [fields addObjectUniquely: @"c_isallday"]; if (logger) [self debugWithFormat:@"should fetch (%@=>%@) ...", _startDate, _endDate];