From: wolfgang Date: Thu, 26 Jul 2007 19:22:12 +0000 (+0000) Subject: git-svn-id: http://svn.opengroupware.org/SOGo/inverse/trunk@1121 d1b88da0-ebda-0310... X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3b1f5f1d8dbff2c42318d2ba714967a0aacf723a;p=scalable-opengroupware.org git-svn-id: http://svn.opengroupware.org/SOGo/inverse/trunk@1121 d1b88da0-ebda-0310-925b-ed51d893ca5b --- diff --git a/NEWS b/NEWS index d26220fc..281d6d33 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,8 @@ application settings; - put a work-around in the LDAP directory code to avoid fetching all the entries whenever a specific one is being requested; +- added support for limiting LDAP queries with the SOGoLDAPQueryLimit and + the SOGoLDAPSizeLimit settings; 0.9.0-20070713 -------------- diff --git a/SoObjects/Appointments/SOGoAppointmentFolder.m b/SoObjects/Appointments/SOGoAppointmentFolder.m index af7370d5..4d0b3357 100644 --- a/SoObjects/Appointments/SOGoAppointmentFolder.m +++ b/SoObjects/Appointments/SOGoAppointmentFolder.m @@ -31,6 +31,7 @@ #import #import #import +#import #import #import "common.h" @@ -139,23 +140,23 @@ static NSNumber *sharedYes = nil; { SOGoCalendarComponent *component; Class componentClass; - NSString *c_name, *etagLine, *calString; + NSString *name, *etagLine, *calString; - c_name = [object objectForKey: @"c_name"]; + name = [object objectForKey: @"c_name"]; if ([[object objectForKey: @"c_component"] isEqualToString: @"vevent"]) componentClass = [SOGoAppointmentObject class]; else componentClass = [SOGoTaskObject class]; - component = [componentClass objectWithName: c_name inContainer: self]; + component = [componentClass objectWithName: name inContainer: self]; [r appendContentString: @" \r\n"]; [r appendContentString: @" "]; [r appendContentString: baseURL]; if (![baseURL hasSuffix: @"/"]) [r appendContentString: @"/"]; - [r appendContentString: c_name]; + [r appendContentString: name]; [r appendContentString: @"\r\n"]; [r appendContentString: @" \r\n"]; @@ -448,7 +449,7 @@ static NSNumber *sharedYes = nil; if (nameFields == nil) nameFields = [[NSArray alloc] initWithObjects: @"c_name", nil]; - qualifier = [EOQualifier qualifierWithQualifierFormat:@"uid = %@", _u]; + qualifier = [EOQualifier qualifierWithQualifierFormat:@"c_uid = %@", _u]; records = [_f fetchFields: nameFields matchingQualifier: qualifier]; if ([records count] == 1) @@ -489,14 +490,14 @@ static NSNumber *sharedYes = nil; return rname; } -- (Class) objectClassForResourceNamed: (NSString *) c_name +- (Class) objectClassForResourceNamed: (NSString *) name { EOQualifier *qualifier; NSArray *records; NSString *component; Class objectClass; - qualifier = [EOQualifier qualifierWithQualifierFormat:@"c_name = %@", c_name]; + qualifier = [EOQualifier qualifierWithQualifierFormat:@"c_name = %@", name]; records = [[self ocsFolder] fetchFields: [NSArray arrayWithObject: @"c_component"] matchingQualifier: qualifier]; @@ -615,13 +616,13 @@ static NSNumber *sharedYes = nil; [row removeObjectForKey: @"c_cycleinfo"]; [row setObject: sharedYes forKey:@"isRecurrentEvent"]; - startDate = [row objectForKey:@"c_startDate"]; - endDate = [row objectForKey:@"c_endDate"]; + startDate = [row objectForKey:@"startDate"]; + endDate = [row objectForKey:@"endDate"]; fir = [NGCalendarDateRange calendarDateRangeWithStartDate:startDate endDate:endDate]; - rules = [cycleinfo objectForKey:@"c_rules"]; - exRules = [cycleinfo objectForKey:@"c_exRules"]; - exDates = [cycleinfo objectForKey:@"c_exDates"]; + rules = [cycleinfo objectForKey:@"rules"]; + exRules = [cycleinfo objectForKey:@"exRules"]; + exDates = [cycleinfo objectForKey:@"exDates"]; ranges = [iCalRecurrenceCalculator recurrenceRangesWithinCalendarDateRange:_r firstInstanceCalendarDateRange:fir @@ -709,7 +710,7 @@ static NSNumber *sharedYes = nil; currentRole = [self roleForComponentsWithAccessClass: classes[counter] forUser: uid]; if ([currentRole length] > 0) - [classificationString appendFormat: @"classification = %d or ", + [classificationString appendFormat: @"c_classification = %d or ", classes[counter]]; } @@ -727,16 +728,16 @@ static NSNumber *sharedYes = nil; if ([login isEqualToString: owner]) privacySqlString = @""; else if ([login isEqualToString: @"freebusy"]) - privacySqlString = @"and (isopaque = 1)"; + privacySqlString = @"and (c_isopaque = 1)"; else { email = [activeUser primaryEmail]; privacySqlString = [NSString stringWithFormat: - @"(%@(orgmail = '%@')" - @" or ((partmails caseInsensitiveLike '%@%%'" - @" or partmails caseInsensitiveLike '%%\n%@%%')))", + @"(%@(c_orgmail = '%@')" + @" or ((c_partmails caseInsensitiveLike '%@%%'" + @" or c_partmails caseInsensitiveLike '%%\n%@%%')))", [self _privacyClassificationStringsForUID: login], email, email, email]; } @@ -990,7 +991,7 @@ static NSNumber *sharedYes = nil; result = [[ctx application] traversePathArray:path inContext:ctx error:&error acquire:NO]; if (error != nil) { - [self errorWithFormat: @"folder lookup failed (uid=%@): %@", + [self errorWithFormat: @"folder lookup failed (c_uid=%@): %@", _uid, error]; return nil; }