propagate from branch 'ca.inverse.sogo.1_3_17' (head c9c54e20cc8e010c29ef8e5fa1cbd039c35e5344)
to branch 'ca.inverse.sogo' (head 1e529d97ad640de07982d342ce216985cba625f7) Monotone-Parent: 1e529d97ad640de07982d342ce216985cba625f7 Monotone-Parent: c9c54e20cc8e010c29ef8e5fa1cbd039c35e5344 Monotone-Revision: 30b98f3bab78c6daecd8eab77d0e1251fc687791 Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2012-07-20T19:23:37 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
commit
35098cda85
15
ChangeLog
15
ChangeLog
|
@ -1,3 +1,16 @@
|
|||
2012-07-20 Francis Lachapelle <flachapelle@inverse.ca>
|
||||
|
||||
* UI/WebServerResources/MailerUI.js (onEmailTo): append the email
|
||||
address from the href attribute if it doesn't appear in the link content.
|
||||
|
||||
* UI/MailPartViewers/UIxMailPartHTMLViewer.m
|
||||
(-startElement:namespace:rawName:attributes:): don't skip "mailto:"
|
||||
href.
|
||||
|
||||
* SoObjects/Appointments/SOGoAptMailReceipt.m (aptSummary-): new
|
||||
method that returns a properly formatted string of the event title
|
||||
with respect to the current operation (creation/deletion/update).
|
||||
|
||||
2012-07-20 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* OpenChange/NSObject+MAPIStore.m (-getSMTPAddrType:inMemCtx:):
|
||||
|
@ -183,7 +196,7 @@
|
|||
when modifying their own calendars or when someone else to it. These
|
||||
defaults are over-writable by users from their calendar properties window.
|
||||
|
||||
* Implemented the code related to the two new defaults together with a
|
||||
* Implemented the code related to the two new defaults together with a
|
||||
third option - which is to notify a specific person when one modifies
|
||||
his/her calendar. This commit is partial as more testing is required
|
||||
and some code changes to trigger the right notifications.
|
||||
|
|
|
@ -8,13 +8,9 @@ vtodo_class1 = "(Private task)";
|
|||
vtodo_class2 = "(Confidential task)";
|
||||
|
||||
/* Receipts */
|
||||
"Title:" = "Title:";
|
||||
"Start:" = "Start:";
|
||||
"End:" = "End:";
|
||||
"Location:" = "Location:";
|
||||
"Receipt: event was created" = "Receipt: event was created";
|
||||
"Receipt: event was deleted" = "Receipt: event was deleted";
|
||||
"Receipt: event was updated" = "Receipt: event was updated";
|
||||
"The event \"%{Summary}\" was created" = "The event \"%{Summary}\" was created";
|
||||
"The event \"%{Summary}\" was deleted" = "The event \"%{Summary}\" was deleted";
|
||||
"The event \"%{Summary}\" was updated" = "The event \"%{Summary}\" was updated";
|
||||
"The following attendees(s) were notified:" = "The following attendees(s) were notified:";
|
||||
"The following attendees(s) were added:" = "The following attendees(s) were added:";
|
||||
"The following attendees(s) were removed:" = "The following attendees(s) were removed:";
|
||||
|
|
|
@ -8,25 +8,16 @@ vtodo_class1 = "(Tâche privée)";
|
|||
vtodo_class2 = "(Tâche confidentielle)";
|
||||
|
||||
/* Receipts */
|
||||
"Title:" = "Titre :";
|
||||
"Start:" = "Début :";
|
||||
"End:" = "Fin :";
|
||||
|
||||
"Receipt: users invited to a meeting" = "Acc. de réception : vous avez ajouté des participants à une réunion";
|
||||
"You have invited the following attendees(s):" = "Vous avez invité les personnes suivantes :";
|
||||
"... to attend the following event:" = "... à participer à cette réunion :";
|
||||
|
||||
"Receipt: invitation updated" = "Acc. de réception : invitation mise à jour";
|
||||
"The following attendees(s):" = "Les participants suivants :";
|
||||
"... have been notified of the changes to the following event:" = "... ont été avisés des changements apportés à cette réunion :";
|
||||
|
||||
"Receipt: attendees removed from an event" = "Acc. de réception: invitations annulées";
|
||||
"You have removed the following attendees(s):" = "Les utilisateurs suivants :";
|
||||
"... from the following event:" = "... ne sont plus invités à cette réunion :";
|
||||
"The event \"%{Summary}\" was created" = "L'événement «%{Summary}» a été créé";
|
||||
"The event \"%{Summary}\" was deleted" = "L'événement «%{Summary}» a été effacé";
|
||||
"The event \"%{Summary}\" was updated" = "L'événement «%{Summary}» a été modifié";
|
||||
"The following attendees(s) were notified:" = "Les invités suivants ont été avisés :";
|
||||
"The following attendees(s) were added:" = "Les invités suivants ont été ajoutés :";
|
||||
"The following attendees(s) were removed:" = "Les invités suivants ont été supprimés :";
|
||||
|
||||
/* IMIP messages */
|
||||
"startDate_label" = "Du :";
|
||||
"endDate_label" = "au :";
|
||||
"startDate_label" = "Début :";
|
||||
"endDate_label" = "Fin :";
|
||||
"due_label" = "Fin prévue :";
|
||||
"location_label" = "Lieu :";
|
||||
"summary_label" = "Titre :";
|
||||
|
@ -67,4 +58,5 @@ vtodo_class2 = "(Tâche confidentielle)";
|
|||
= "%{Attendee} %{SentByText}choisit de reporter sa décision par rapport à votre invitation.";
|
||||
|
||||
/* Resources */
|
||||
"Maximum number of simultaneous bookings (%{NumberOfSimultaneousBookings}) reached for resource \"%{Cn} %{SystemEmail}\". The conflicting event is \"%{EventTitle}\", and starts on %{StartDate}." = "Le nombre maximal de réservations simultanées (%{NumberOfSimultaneousBookings}) est atteint pour la ressource «%{Cn} %{SystemEmail}». L'événement en conflit est «%{EventTitle}» et débute le %{StartDate}.";
|
||||
"Cannot access resource: \"%{Cn} %{SystemEmail}\"" = "Impossible d'accéder à la ressource suivante: \"%{Cn} %{SystemEmail}\"";
|
||||
"Maximum number of simultaneous bookings (%{NumberOfSimultaneousBookings}) reached for resource \"%{Cn} %{SystemEmail}\". The conflicting event is \"%{EventTitle}\", and starts on %{StartDate}." = "Le nombre maximal de réservations simultanées (%{NumberOfSimultaneousBookings}) est atteint pour la ressource «%{Cn} %{SystemEmail}». L'événement en conflit est «%{EventTitle}» et débute le %{StartDate}.";
|
||||
|
|
|
@ -47,7 +47,8 @@
|
|||
- (void) setDeletedAttendees: (NSArray *) theAttendees;
|
||||
- (void) setUpdatedAttendees: (NSArray *) theAttendees;
|
||||
- (void) setOperation: (SOGoEventOperation) theOperation;
|
||||
- (NSString *) subject;
|
||||
|
||||
- (NSString *) aptSummary;
|
||||
|
||||
@end
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
* Ludovic Marcotte <lmarcotte@inverse.ca>
|
||||
* Francis Lachapelle <flachapelle@inverse.ca>
|
||||
*
|
||||
* This file is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
@ -31,6 +32,7 @@
|
|||
#import <NGCards/iCalEvent.h>
|
||||
#import <NGCards/iCalPerson.h>
|
||||
|
||||
#import <SOGo/NSDictionary+Utilities.h>
|
||||
#import <SOGo/NSObject+Utilities.h>
|
||||
#import <SOGo/NSString+Utilities.h>
|
||||
#import <SOGo/SOGoUserManager.h>
|
||||
|
@ -138,25 +140,37 @@ static NSCharacterSet *wsSet = nil;
|
|||
operation = theOperation;
|
||||
}
|
||||
|
||||
- (NSString *) subject
|
||||
- (NSString *) aptSummary
|
||||
{
|
||||
NSString *s;
|
||||
|
||||
if (!values)
|
||||
[self setupValues];
|
||||
|
||||
switch (operation)
|
||||
{
|
||||
case EventCreated:
|
||||
s = [self labelForKey: @"Receipt: event was created" inContext: context];
|
||||
s = [self labelForKey: @"The event \"%{Summary}\" was created"
|
||||
inContext: context];
|
||||
break;
|
||||
|
||||
case EventDeleted:
|
||||
s = [self labelForKey: @"Receipt: event was deleted" inContext: context];
|
||||
s = [self labelForKey: @"The event \"%{Summary}\" was deleted"
|
||||
inContext: context];
|
||||
break;
|
||||
|
||||
case EventUpdated:
|
||||
default:
|
||||
s = [self labelForKey: @"Receipt: event was updated" inContext: context];
|
||||
s = [self labelForKey: @"The event \"%{Summary}\" was updated"
|
||||
inContext: context];
|
||||
}
|
||||
|
||||
return [[s stringByTrimmingCharactersInSet: wsSet] asQPSubjectString: @"utf-8"];
|
||||
return [values keysWithFormat: s];
|
||||
}
|
||||
|
||||
- (NSString *) getSubject
|
||||
{
|
||||
return [[[self aptSummary] stringByTrimmingCharactersInSet: wsSet] asQPSubjectString: @"utf-8"];
|
||||
}
|
||||
|
||||
- (NSString *) _formattedUserDate: (NSCalendarDate *) date
|
||||
|
|
|
@ -1015,7 +1015,7 @@
|
|||
|
||||
mailDate = [[NSCalendarDate date] rfc822DateString];
|
||||
[headerMap setObject: mailDate forKey: @"date"];
|
||||
[headerMap setObject: [page subject] forKey: @"subject"];
|
||||
[headerMap setObject: [page getSubject] forKey: @"subject"];
|
||||
[headerMap setObject: @"1.0" forKey: @"MIME-Version"];
|
||||
[headerMap setObject: @"text/html; charset=utf-8"
|
||||
forKey: @"content-type"];
|
||||
|
|
|
@ -468,6 +468,7 @@ static NSData* _sanitizeContent(NSData *theData)
|
|||
value = [_attributes valueAtIndex: count];
|
||||
skipAttribute = ([value rangeOfString: @"://"].location
|
||||
== NSNotFound
|
||||
&& ![value hasPrefix: @"mailto:"]
|
||||
&& ![value hasPrefix: @"#"]);
|
||||
}
|
||||
else
|
||||
|
|
|
@ -7,52 +7,48 @@
|
|||
xmlns:rsrc="OGo:url"
|
||||
xmlns:label="OGo:label">
|
||||
|
||||
<var:string label:value="Event details:" const:escapeHTML="NO"/>
|
||||
<br/>
|
||||
|
||||
<var:string label:value="Title:" const:escapeHTML="NO"/> <var:string
|
||||
value="apt.summary" const:escapeHTML="NO"/>
|
||||
<br/>
|
||||
|
||||
<var:if condition="apt.location.length">
|
||||
<var:string label:value="Location:" const:escapeHTML="NO"/> <var:string
|
||||
value="apt.location" const:escapeHTML="NO"/>
|
||||
</var:if>
|
||||
<br/>
|
||||
|
||||
<var:string label:value="Start:" const:escapeHTML="NO"/> <var:string
|
||||
value="aptStartDate" const:escapeHTML="NO"/>
|
||||
<br/>
|
||||
|
||||
<var:string label:value="End:" const:escapeHTML="NO"/> <var:string
|
||||
value="aptEndDate" const:escapeHTML="NO"/>
|
||||
<br/>
|
||||
|
||||
<var:if condition="updatedAttendees.count">
|
||||
<var:string label:value="The following attendees(s) were notified:"
|
||||
const:escapeHTML="NO"/>
|
||||
<var:foreach list="updatedAttendees" item="currentRecipient">
|
||||
<var:string value="currentRecipient.mailAddress" const:escapeHTML="NO"
|
||||
/></var:foreach>
|
||||
</var:if>
|
||||
<br/>
|
||||
|
||||
<var:if condition="addedAttendees.count">
|
||||
<var:string label:value="The following attendees(s) were added:"
|
||||
const:escapeHTML="NO"/>
|
||||
<var:foreach list="addedAttendees" item="currentRecipient">
|
||||
<var:string value="currentRecipient.mailAddress" const:escapeHTML="NO"
|
||||
/></var:foreach>
|
||||
</var:if>
|
||||
<br/>
|
||||
|
||||
<var:if condition="deletedAttendees.count">
|
||||
<var:string label:value="The following attendees(s) were removed:"
|
||||
const:escapeHTML="NO"/>
|
||||
<var:foreach list="deletedAttendees" item="currentRecipient">
|
||||
<var:string value="currentRecipient.mailAddress" const:escapeHTML="NO"
|
||||
/></var:foreach>
|
||||
</var:if>
|
||||
<br/>
|
||||
|
||||
<head>
|
||||
<style type="text/css">
|
||||
.container { width: 600px; }
|
||||
h1 { font-size: 18px; font-weight: normal; padding-bottom: 9px; border-bottom: 1px solid #ccc; }
|
||||
.dl-horizontal dt { float: left; width: 120px; overflow: hidden; clear: left; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
|
||||
dt { font-weight: bold; line-height: 17px; }
|
||||
dt, dd { font-size: 12px; line-height: 18px; }
|
||||
dt { display: block; }
|
||||
h1, dd, .dl-list dt { margin-left: 130px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1><var:string value="aptSummary" const:escapeHTML="NO"/></h1>
|
||||
|
||||
<dl class="dl-horizontal">
|
||||
<var:if condition="apt.location.length"
|
||||
><dt><var:string label:value="location_label" const:escapeHTML="NO"/></dt>
|
||||
<dd><var:string value="apt.location" const:escapeHTML="NO"/></dd></var:if>
|
||||
<dt><var:string label:value="startDate_label" const:escapeHTML="NO"/></dt>
|
||||
<dd><var:string value="aptStartDate" const:escapeHTML="NO"/></dd>
|
||||
<dt><var:string label:value="endDate_label" const:escapeHTML="NO"/></dt>
|
||||
<dd><var:string value="aptEndDate" const:escapeHTML="NO"/></dd>
|
||||
</dl>
|
||||
|
||||
<dl class="dl-list">
|
||||
<var:if condition="updatedAttendees.count">
|
||||
<dt><var:string label:value="The following attendees(s) were notified:" const:escapeHTML="NO"/></dt>
|
||||
<var:foreach list="updatedAttendees" item="currentRecipient">
|
||||
<dd><a var:href="currentRecipient.email"><var:string value="currentRecipient.cn" const:escapeHTML="NO"/></a></dd></var:foreach>
|
||||
</var:if>
|
||||
<var:if condition="addedAttendees.count">
|
||||
<dt><var:string label:value="The following attendees(s) were added:" const:escapeHTML="NO"/></dt>
|
||||
<var:foreach list="addedAttendees" item="currentRecipient">
|
||||
<dd><a var:href="currentRecipient.email"><var:string value="currentRecipient.cn" const:escapeHTML="NO"/></a></dd></var:foreach>
|
||||
</var:if>
|
||||
<var:if condition="deletedAttendees.count">
|
||||
<dt><var:string label:value="The following attendees(s) were removed:" const:escapeHTML="NO"/></dt>
|
||||
<var:foreach list="deletedAttendees" item="currentRecipient">
|
||||
<dd><a var:href="currentRecipient.email"><var:string value="currentRecipient.cn" const:escapeHTML="NO"/></a></dd></var:foreach>
|
||||
</var:if>
|
||||
</dl>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -1790,7 +1790,11 @@ function newContactFromEmail(event) {
|
|||
}
|
||||
|
||||
function onEmailTo(event) {
|
||||
openMailTo(this.innerHTML.strip());
|
||||
var s = this.innerHTML.strip();
|
||||
if (!/@/.test(s)) {
|
||||
s += ' <' + this.href.substr(7) + '>';
|
||||
}
|
||||
openMailTo(s);
|
||||
Event.stop(event);
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue