02111-1307, USA.
*/
+#import <Foundation/NSCalendarDate.h>
+#import <Foundation/NSDictionary.h>
+#import <Foundation/NSEnumerator.h>
+#import <Foundation/NSValue.h>
+
+#import <NGObjWeb/WOContext+SoObjects.h>
+#import <NGObjWeb/WOResponse.h>
+#import <NGExtensions/NSCalendarDate+misc.h>
#import <NGCards/iCalCalendar.h>
#import <NGCards/iCalFreeBusy.h>
#import <NGCards/iCalPerson.h>
-#import "common.h"
-
#import <SOGo/LDAPUserManager.h>
+#import <SOGo/SOGoUser.h>
#import <SOGo/SOGoPermissions.h>
+#import "SOGoAppointmentFolder.h"
+
#import "SOGoFreeBusyObject.h"
@interface SOGoFreeBusyObject (PrivateAPI)
- (NSArray *) fetchFreeBusyInfosFrom: (NSCalendarDate *) _startDate
to: (NSCalendarDate *) _endDate
{
- id calFolder;
+ SOGoAppointmentFolder *calFolder;
// SoSecurityManager *sm;
NSArray *infos;
- calFolder = [container lookupName: @"Calendar" inContext: nil acquire: NO];
+ calFolder = [[container lookupName: @"Calendar" inContext: nil acquire: NO]
+ lookupName: @"personal" inContext: nil acquire: NO];
// sm = [SoSecurityManager sharedSecurityManager];
// if (![sm validatePermission: SOGoPerm_FreeBusyLookup
// onObject: calFolder
// inContext: context])
- infos = [calFolder fetchFreeBusyInfosFrom: _startDate
- to: _endDate];
+ infos = [calFolder fetchFreeBusyInfosFrom: _startDate
+ to: _endDate];
// else
// {
// infos = [NSArray new];
info = [events nextObject];
while (info)
{
- if ([[info objectForKey: @"isopaque"] boolValue])
+ if ([[info objectForKey: @"c_isopaque"] boolValue])
{
- type = [self _fbTypeForEventStatus: [info objectForKey: @"status"]];
+ type = [self _fbTypeForEventStatus: [info objectForKey: @"c_status"]];
[freebusy addFreeBusyFrom: [info objectForKey: @"startDate"]
to: [info objectForKey: @"endDate"]
type: type];