diff --git a/ChangeLog b/ChangeLog index fdc71f777..e398df6a0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2009-07-14 Wolfgang Sourdeau + + * SoObjects/Appointments/SOGoUserFolder+Appointments.m + (-davCalendarUserAddressSet): we return the "MAILTO:" prefix in + lower case instead. + + * SoObjects/Appointments/SOGoAppointmentFolders.m + (-davCalendarComponentSet): new method, copied from + SOGoAppointmentFolder. + 2009-07-10 Wolfgang Sourdeau * SoObjects/SOGo/SOGoContentObject.m (-davResourceType): new diff --git a/SoObjects/Appointments/SOGoAppointmentFolders.m b/SoObjects/Appointments/SOGoAppointmentFolders.m index c64afa030..4917c6abd 100644 --- a/SoObjects/Appointments/SOGoAppointmentFolders.m +++ b/SoObjects/Appointments/SOGoAppointmentFolders.m @@ -1,3 +1,4 @@ + /* SOGoAppointmentFolders.m - this file is part of SOGo * * Copyright (C) 2007 Inverse inc. @@ -21,14 +22,17 @@ */ #import +#import #import #import #import #import #import - +#import #import +#import +#import #import "SOGoAppointmentFolder.h" #import "SOGoAppointmentFolders.h" @@ -167,4 +171,32 @@ return classes; } +- (SOGoWebDAVValue *) davCalendarComponentSet +{ + static SOGoWebDAVValue *componentSet = nil; + NSMutableArray *components; + + if (!componentSet) + { + components = [NSMutableArray array]; + /* Totally hackish.... we use the "n1" prefix because we know our + extensions will assign that one to ..:caldav but we really need to + handle element attributes */ + [components addObject: [SOGoWebDAVValue + valueForObject: @"" + attributes: nil]]; + [components addObject: [SOGoWebDAVValue + valueForObject: @"" + attributes: nil]]; + componentSet + = [davElementWithContent (@"supported-calendar-component-set", + XMLNS_CALDAV, + components) + asWebDAVValue]; + [componentSet retain]; + } + + return componentSet; +} + @end diff --git a/SoObjects/Appointments/SOGoUserFolder+Appointments.m b/SoObjects/Appointments/SOGoUserFolder+Appointments.m index 211c72460..46a5b5eaf 100644 --- a/SoObjects/Appointments/SOGoUserFolder+Appointments.m +++ b/SoObjects/Appointments/SOGoUserFolder+Appointments.m @@ -60,7 +60,7 @@ while ((currentEmail = [emails nextObject])) { tag = [NSArray arrayWithObjects: @"href", @"DAV:", @"D", - [NSString stringWithFormat: @"MAILTO:%@", currentEmail], + [NSString stringWithFormat: @"mailto:%@", currentEmail], nil]; [addresses addObject: tag]; } diff --git a/SoObjects/SOGo/SOGoGCSFolder.m b/SoObjects/SOGo/SOGoGCSFolder.m index 0aa9e451d..5150dc6ef 100644 --- a/SoObjects/SOGo/SOGoGCSFolder.m +++ b/SoObjects/SOGo/SOGoGCSFolder.m @@ -818,6 +818,7 @@ static NSArray *childRecordFields = nil; davSQLFieldsTable = [NSMutableDictionary new]; [davSQLFieldsTable setObject: @"c_version" forKey: @"{DAV:}getetag"]; [davSQLFieldsTable setObject: @"" forKey: @"{DAV:}getcontenttype"]; + [davSQLFieldsTable setObject: @"" forKey: @"{DAV:}resourcetype"]; } return davSQLFieldsTable; diff --git a/UI/WebServerResources/SchedulerUI.js b/UI/WebServerResources/SchedulerUI.js index e73500f5b..a218455f3 100644 --- a/UI/WebServerResources/SchedulerUI.js +++ b/UI/WebServerResources/SchedulerUI.js @@ -1504,7 +1504,6 @@ function onShowCompletedTasks(event) { function updateTaskStatus(event) { var newStatus = (this.checked ? 1 : 0); - var http = createHTTPClient(); if (isSafari() && !isSafari3()) { newStatus = (newStatus ? 0 : 1); @@ -1513,12 +1512,19 @@ function updateTaskStatus(event) { url = (ApplicationBaseURL + this.parentNode.calendar + "/" + this.parentNode.cname + "/changeStatus?status=" + newStatus); + var http = createHTTPClient(); if (http) { // TODO: add parameter to signal that we are only interested in OK http.open("POST", url, false /* not async */); http.url = url; - http.send(""); -// http.setRequestHeader("Content-Length", 0); + try { + http.send(""); + } + catch (e) { + /* IE7 tends to generate "tranaction aborted" errors for synchronous + transactions returning HTTP code 204. */ + log("exception during http.send (expected on IE7)"); + } if (isHttpStatus204(http.status)) refreshTasks(); } else diff --git a/UI/WebServerResources/generic.js b/UI/WebServerResources/generic.js index 1caf9f477..d9809ad85 100644 --- a/UI/WebServerResources/generic.js +++ b/UI/WebServerResources/generic.js @@ -356,12 +356,13 @@ function getContrastingTextColor(bgColor) { } function triggerAjaxRequest(url, callback, userdata, content, headers) { - var http = createHTTPClient(); - activeAjaxRequests++; - document.animTimer = setTimeout("checkAjaxRequestsState();", 250); //url = appendDifferentiator(url); + var http = createHTTPClient(); if (http) { + activeAjaxRequests++; + document.animTimer = setTimeout("checkAjaxRequestsState();", 250); + http.open("POST", url, true); http.url = url; http.callback = callback;