AD071CE606CD2ACE00A9EEF4,
AD071CEC06CD2ACE00A9EEF4,
AD071CED06CD2ACE00A9EEF4,
+ AD73BE4A06CF88BF00226A2D,
+ AD73BE4B06CF88BF00226A2D,
AD071D1206CD2BCB00A9EEF4,
AD071D1306CD2BCB00A9EEF4,
);
refType = 4;
sourceTree = "<group>";
};
+ AD73BE4A06CF88BF00226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.h;
+ path = SOGoAppointmentICalRenderer.h;
+ refType = 4;
+ sourceTree = "<group>";
+ };
+ AD73BE4B06CF88BF00226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.objc;
+ path = SOGoAppointmentICalRenderer.m;
+ refType = 4;
+ sourceTree = "<group>";
+ };
+ AD73BE6106CF8CC500226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.h;
+ path = "UIxComponent+Agenor.h";
+ refType = 4;
+ sourceTree = "<group>";
+ };
+ AD73BE6206CF8CC500226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.objc;
+ path = "UIxComponent+Agenor.m";
+ refType = 4;
+ sourceTree = "<group>";
+ };
+ AD73BE7D06CF90EA00226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.h;
+ path = "NSCalendarDate+UIx.h";
+ refType = 4;
+ sourceTree = "<group>";
+ };
+ AD73BE7E06CF90EA00226A2D = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ lastKnownFileType = sourcecode.c.objc;
+ path = "NSCalendarDate+UIx.m";
+ refType = 4;
+ sourceTree = "<group>";
+ };
ADCDE53106ADA8AC00BFCE2B = {
fileEncoding = 5;
isa = PBXFileReference;
E87208930692E3D30099CBBD = {
explicitFileType = sourcecode.make;
fileEncoding = 4;
+ indentWidth = 8;
isa = PBXFileReference;
path = GNUmakefile;
refType = 4;
sourceTree = "<group>";
- tabWidth = 4;
+ tabWidth = 8;
};
E87208940692E3D30099CBBD = {
explicitFileType = sourcecode.make;
E872090B0692E3D30099CBBD,
E87209020692E3D30099CBBD,
E87209030692E3D30099CBBD,
+ AD73BE7D06CF90EA00226A2D,
+ AD73BE7E06CF90EA00226A2D,
AD071B3C06CCFA2000A9EEF4,
AD071B3D06CCFA2000A9EEF4,
+ AD73BE6106CF8CC500226A2D,
+ AD73BE6206CF8CC500226A2D,
);
isa = PBXGroup;
name = Classes;
+2004-08-14 Marcus Mueller <znek@mulle-kybernetik.com>
+
+ * v0.9.38
+
+ * UIxComponent+Agenor.[hm]: -cnForUser and -emailForUser require the
+ AgenorUserManager from Logic.
+
+ * UIxAppointmentEditor.m: refactored -cnForUser and -emailForUser,
+ moved to extra category.
+
+ * UIxCalWeekView.wox: added custom style if apt belongs to user.
+
+ * UIxCalView.m: added some extra logic in redirect, provided extra
+ style sheet selector for appointments.
+
+ * GNUmakefile: added new files
+
2004-08-14 Marcus Mueller <znek@mulle-kybernetik.com>
* v0.9.37
UIxAppointmentFormatter.m \
iCalPerson+UIx.m \
NSCalendarDate+UIx.m \
+ UIxComponent+Agenor.m \
\
UIxCalView.m \
UIxCalDayView.m \
- (NSString *)iCalStringTemplate;
- (NSString *)iCalString;
-- (NSString *)emailForUser;
-- (NSString *)cnForUser;
-
- (NSString *)_completeURIForMethod:(NSString *)_method;
- (iCalPerson *)getOrganizer;
#include <NGiCal/NGiCal.h>
#include <SOGoLogic/AgenorUserManager.h>
#include "iCalPerson+UIx.h"
+#include "UIxComponent+Agenor.h"
@interface NSDate(UsedPrivates)
- (NSString *)icalString; // TODO: this is in NGiCal
/* email, cn */
-- (NSString *)emailForUser {
- NSString *uid;
-
- uid = [[self user] login];
- return [[AgenorUserManager sharedUserManager] getEmailForUID:uid];
-}
-
-- (NSString *)cnForUser {
- NSString *uid;
-
- uid = [[self user] login];
- return [[AgenorUserManager sharedUserManager] getCNForUID:uid];
-}
-
- (NSString *)combinedCNAndEmailForUser {
return [NSString stringWithFormat:@"%@;%@",
[self emailForUser],
#include "SoObjects/Appointments/SOGoAppointmentFolder.h"
#include <NGObjWeb/SoUser.h>
#include <SOGoUI/SOGoAptFormatter.h>
+#include <SOGoLogic/AgenorUserManager.h>
@interface UIxCalView (PrivateAPI)
- (NSString *)_userFolderURI;
return title;
}
-/* TODO: remove this */
- (NSString *)tooltipForApt {
return [[self aptTooltipFormatter] stringForObjectValue:self->appointment];
}
+- (BOOL)isMyApt {
+ return YES;
+}
+
+- (NSString *)aptStyle {
+ if(![self isMyApt])
+ return @"other_apt";
+ return nil;
+}
+
- (NSCalendarDate *)referenceDateForFormatter {
return [self selectedDate];
}
stringByAppendingString:@"/view"];
}
-
/* backend */
/* resource URLs (TODO?) */
- (id)redirectForUIDsAction {
NSMutableString *uri;
- NSString *uidsString, *loc, *prevMethod;
+ NSString *uidsString, *loc, *prevMethod, *userFolderID;
WORequest *req;
id <WOActionResults> r;
BOOL useGroups;
+ unsigned index;
req = [[self context] request];
uri = [[NSMutableString alloc] initWithString:[self _userFolderURI]];
/* if we have more than one entry, use groups - otherwise don't */
useGroups = [uidsString rangeOfString:@","].length > 0;
-
+ userFolderID = [uri lastPathComponent];
if(useGroups) {
+ NSArray *uids;
+
+ uids = [uidsString componentsSeparatedByString:@","];
+ /* guarantee that our id is the first */
+ if(((index = [uids indexOfObject:userFolderID]) != NSNotFound) &&
+ (index != 0)) {
+ uids = [[uids mutableCopy] autorelease];
+ [(NSMutableArray *)uids removeObjectAtIndex:index];
+ [(NSMutableArray *)uids insertObject:userFolderID atIndex:0];
+ uidsString = [uids componentsJoinedByString:@","];
+ }
[uri appendString:@"Groups/_custom_"];
[uri appendString:uidsString];
[uri appendString:@"/"];
else {
/* check if lastPathComponent is the base that we want to have */
if((([uidsString length] != 0) &&
- (![[uri lastPathComponent] isEqualToString:uidsString]))) {
+ (![userFolderID isEqualToString:uidsString]))) {
NSRange r;
/* uri ends with an '/', so we have to adjust the range a little */
<var:foreach list="allDayApts" item="appointment">
<a var:href="appointmentViewURL"
var:queryDictionary="currentDayQueryParameters"
- ><var:string value="shortTextForApt"
+ ><var:string value="appointment"
+ formatter="aptFormatter"
const:escapeHTML="NO"
+ style="aptStyle"
/></a>
</var:foreach>
</var:week-info>
<var:week>
<a var:href="appointmentViewURL"
var:title="tooltipForApt"
- ><small><var:string value="shortTextForApt"
+ ><small><var:string value="appointment"
+ formatter="aptFormatter"
const:escapeHTML="NO"
+ style="aptStyle"
/></small></a><br />
</var:week>
</var:week-overview>
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OGo
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+// $Id$
+
+
+#ifndef __UIxComponent_Agenor_H_
+#define __UIxComponent_Agenor_H_
+
+
+#import <SOGoUI/UIxComponent.h>
+
+
+@interface UIxComponent (Agenor)
+/* email, cn */
+- (NSString *)emailForUser;
+- (NSString *)cnForUser;
+@end
+
+#endif /* __UIxComponent_Agenor_H_ */
--- /dev/null
+/*
+ Copyright (C) 2000-2004 SKYRIX Software AG
+
+ This file is part of OGo
+
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
+// $Id$
+
+
+#include "UIxComponent+Agenor.h"
+#include <SOGoLogic/AgenorUserManager.h>
+#include "common.h"
+
+@implementation UIxComponent (Agenor)
+
+- (NSString *)emailForUser {
+ NSString *uid;
+
+ uid = [[self user] login];
+ return [[AgenorUserManager sharedUserManager] getEmailForUID:uid];
+}
+
+- (NSString *)cnForUser {
+ NSString *uid;
+
+ uid = [[self user] login];
+ return [[AgenorUserManager sharedUserManager] getCNForUID:uid];
+}
+
+@end