Monotone-Parent: 886f71d2861cb6d59b81ebbddad0f7edee83e3c7

Monotone-Revision: 8e3ccd6bdd643adbebe091bde0df46f1f37150f4

Monotone-Author: flachapelle@inverse.ca
Monotone-Date: 2009-01-07T18:32:24
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Francis Lachapelle
2009-01-07 18:32:24 +00:00
parent 79d2eb30dd
commit 8ca1f8a614
3 changed files with 37 additions and 17 deletions

View File

@@ -1,3 +1,16 @@
2009-01-07 Francis Lachapelle <flachapelle@inverse.ca>
* UI/Scheduler/UIxComponentEditor.m ([UIxComponentEditor
-_handleCustomRRule:]): set the proper timezone for the end date.
([UIxComponentEditor -_loadRRules]): idem.
* UI/Scheduler/UIxAppointmentEditor.m ([UIxAppointmentEditor
-saveAction]): for recurrent events with an end date, the method
_adjustRecurrentRules must be called unconditionally. This fixes
the missing occurence on the last day.
([UIxAppointmentEditor -_adjustRecurrentRules]): fixed adjustment
of end date by using the proper timezone.
2009-01-07 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* SoObjects/SOGo/NSString+Utilities.m ([NSString
@@ -6,13 +19,6 @@
algorithm used in jsonRepresentation, the latter is now calling
this new method.
2009-01-07 Francis Lachapelle <flachapelle@inverse.ca>
* UI/Scheduler/UIxAppointmentEditor.m ([UIxAppointmentEditor
-saveAction]): for recurrent events with an end date, the method
_adjustRecurrentRules must be called unconditionally. This fixes
the missing occurence on the last day.
2008-01-06 Ludovic Marcotte <lmarcotte@inverse.ca>
* SoObjects/Appointments/SOGoCalendarComponent.m

View File

@@ -310,13 +310,16 @@
if (untilDate)
{
// The until date must match the time of the start date
untilDate = [untilDate initWithYear: [untilDate yearOfCommonEra]
month: [untilDate monthOfYear]
day: [untilDate dayOfMonth]
hour: [[event startDate] hourOfDay]
minute: [[event startDate] minuteOfHour]
second: 0
timeZone: [untilDate timeZone]];
NSCalendarDate *date;
date = [[event startDate] copy];
[date setTimeZone: [[context activeUser] timeZone]];
untilDate = [untilDate dateByAddingYears:0
months:0
days:0
hours:[date hourOfDay]
minutes:[date minuteOfHour]
seconds:0];
[rule setUntilDate: untilDate];
}
}

View File

@@ -37,6 +37,7 @@
#import <NGCards/NSCalendarDate+NGCards.h>
#import <NGObjWeb/SoSecurityManager.h>
#import <NGObjWeb/NSException+HTTP.h>
#import <NGObjWeb/WOApplication.h>
#import <NGObjWeb/WORequest.h>
#import <NGExtensions/NSCalendarDate+misc.h>
#import <NGExtensions/NSObject+Logs.h>
@@ -340,8 +341,12 @@ iRANGE(2);
}
else if ([rule untilDate])
{
NSCalendarDate *date;
date = [[rule untilDate] copy];
[date setTimeZone: [[context activeUser] timeZone]];
[self setRange1: @"2"];
[self setRange2: [[rule untilDate] descriptionWithCalendarFormat: @"%Y-%m-%d"]];
[self setRange2: [date descriptionWithCalendarFormat: @"%Y-%m-%d"]];
}
else
[self setRange1: @"0"];
@@ -1387,8 +1392,14 @@ RANGE(2);
// Repeat until date
else if (range == 2)
{
[theRule setUntilDate: [NSCalendarDate dateWithString: [self range2]
calendarFormat: @"%Y-%m-%d"]];
NSCalendarDate *date;
SOGoUser *user;
user = [context activeUser];
date = [NSCalendarDate dateWithString: [self range2]
calendarFormat: @"%Y-%m-%d"
locale: [[WOApplication application] localeForLanguageNamed: [user language]]];
[theRule setUntilDate: date];
}
// No end date.
else