mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-11-21 15:02:40 +00:00
See ChangeLog
Monotone-Parent: c66c023a1a42d53c473a7338a49a9b456d889ed9 Monotone-Revision: 62137d02651888053a8bd415f6e6f5aa79e44cf4 Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2009-10-28T17:48:22 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
1 parent
837f13a0c3
commit
2e0d488f3e
52 files changed
+461
-379
No files matched your search
@@ -820,7 +820,7 @@
|
||||
{
|
||||
[delegates addObject: otherDelegate];
|
||||
|
||||
delegatedUID = [otherDelegate uid];
|
||||
delegatedUID = [otherDelegate uid];
|
||||
if (delegatedUID)
|
||||
// Delegated attendee is a local user; remove event from his calendar
|
||||
[self _removeEventFromUID: delegatedUID
|
||||
@@ -1336,11 +1336,12 @@
|
||||
iCalEvent *event;
|
||||
iCalPerson *attendee;
|
||||
NSException *ex;
|
||||
SOGoUser *ownerUser;
|
||||
NSString *recurrenceTime;
|
||||
SOGoUser *ownerUser, *delegatedUser;
|
||||
NSString *recurrenceTime, *delegatedUid;
|
||||
|
||||
event = nil;
|
||||
ex = nil;
|
||||
delegatedUser = nil;
|
||||
|
||||
calendar = [self calendar: NO secure: NO];
|
||||
if (calendar)
|
||||
@@ -1374,6 +1375,12 @@
|
||||
if (delegate
|
||||
&& ![[delegate email] isEqualToString: [attendee delegatedTo]])
|
||||
{
|
||||
delegatedUid = [delegate uid];
|
||||
if (delegatedUid)
|
||||
delegatedUser = [SOGoUser userWithLogin: delegatedUid];
|
||||
if (delegatedUser != nil && [event userIsOrganizer: delegatedUser])
|
||||
ex = [NSException exceptionWithHTTPStatus: 403
|
||||
reason: @"delegate is organizer"];
|
||||
if ([event isParticipant: [[delegate email] rfc822Email]])
|
||||
ex = [NSException exceptionWithHTTPStatus: 403
|
||||
reason: @"delegate is a participant"];
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
@interface SOGoContactGCSFolder : SOGoGCSFolder <SOGoContactFolder>
|
||||
|
||||
- (void) fixupContactRecord: (NSMutableDictionary *) contactRecord;
|
||||
- (NSDictionary *) lookupContactWithName: (NSString *) aName;
|
||||
|
||||
@end
|
||||
|
||||
|
||||
@@ -224,6 +224,36 @@
|
||||
return newRecords;
|
||||
}
|
||||
|
||||
- (NSDictionary *) lookupContactWithName: (NSString *) aName
|
||||
{
|
||||
NSArray *fields, *dbRecords, *records;
|
||||
NSDictionary *record;
|
||||
EOQualifier *qualifier;
|
||||
NSString *qs;
|
||||
|
||||
fields = folderListingFields;
|
||||
record = nil;
|
||||
|
||||
if (aName && [aName length] > 0)
|
||||
{
|
||||
aName = [[aName stringByReplacingString: @"\\" withString: @"\\\\"]
|
||||
stringByReplacingString: @"'" withString: @"\\'\\'"];
|
||||
qs = [NSString stringWithFormat: @"(c_name isCaseInsensitiveLike: '%@')", aName];
|
||||
qualifier = [EOQualifier qualifierWithQualifierFormat: qs];
|
||||
|
||||
dbRecords = [[self ocsFolder] fetchFields: fields
|
||||
matchingQualifier: qualifier];
|
||||
|
||||
if ([dbRecords count] > 0)
|
||||
{
|
||||
records = [self _flattenedRecords: dbRecords];
|
||||
record = [records lastObject];
|
||||
}
|
||||
}
|
||||
|
||||
return record;
|
||||
}
|
||||
|
||||
- (NSArray *) lookupContactsWithFilter: (NSString *) filter
|
||||
sortBy: (NSString *) sortKey
|
||||
ordering: (NSComparisonResult) sortOrdering
|
||||
|
||||
Reference in new issue
Block a user