[tryton-debian-vcs] tryton-modules-calendar branch upstream-1.8 created. 4f792264ee21e165386c91da13840dddb5028235

Mathias Behrle tryton-debian-vcs at alioth.debian.org
Wed Nov 27 16:59:30 UTC 2013


The following commit has been merged in the upstream-1.8 branch:
https://alioth.debian.org/plugins/scmgit/cgi-bin/gitweb.cgi/?p=tryton/tryton-modules-calendar.git;a=commitdiff;h=4f792264ee21e165386c91da13840dddb5028235
commit 4f792264ee21e165386c91da13840dddb5028235
Author: Mathias Behrle <mathiasb at m9s.biz>
Date:   Tue Oct 11 19:37:57 2011 +0200

    Adding upstream version 1.8.2.

diff --git a/CHANGELOG b/CHANGELOG
index 4869665..1b03f07 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,6 @@
+Version 1.8.2 - 2011-09-10
+* Bug fixes (see mercurial logs for details)
+
 Version 1.8.1 - 2011-02-13
 * Bug fixes (see mercurial logs for details)
 
diff --git a/PKG-INFO b/PKG-INFO
index c5e22a2..cd6e5f9 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond_calendar
-Version: 1.8.1
+Version: 1.8.2
 Summary: Add CalDAV support
 Home-page: http://www.tryton.org/
 Author: B2CK
diff --git a/__tryton__.py b/__tryton__.py
index 07b6402..06bf1f6 100644
--- a/__tryton__.py
+++ b/__tryton__.py
@@ -7,7 +7,7 @@
     'name_es_CO' : 'Calendario',
     'name_es_ES' : 'Calendario',
     'name_fr_FR' : 'Calendrier',
-    'version' : '1.8.1',
+    'version': '1.8.2',
     'author' : 'B2CK',
     'email': 'info at b2ck.com',
     'website': 'http://www.tryton.org/',
diff --git a/calendar.py b/calendar.py
index d5204e8..bec5a57 100644
--- a/calendar.py
+++ b/calendar.py
@@ -280,7 +280,7 @@ class Calendar(ModelSQL, ModelView):
         if not calendar_id:
             raise DAV_Forbidden
         calendar = self.browse(calendar_id)
-        if calendar.owner.id != user:
+        if calendar.owner.id != Transaction().user:
             raise DAV_Forbidden
         ical = vobject.readOne(data)
         if ical.method.value == 'REQUEST' \
@@ -675,6 +675,8 @@ class Event(ModelSQL, ModelView):
                     'SET sequence = sequence + 1 ' \
                     'WHERE ' + red_sql, red_ids)
 
+        if not values:
+            return res
         for event in self.browse(ids):
             if event.calendar.owner \
                     and (event.organizer == event.calendar.owner.email \
@@ -688,18 +690,20 @@ class Event(ModelSQL, ModelView):
                     attendee_emails = [x.email for x in event.parent.attendees
                             if x.status != 'declined'
                             and x.email != event.parent.organizer]
-                if attendee_emails:
-                    with Transaction().set_user(0):
-                        event_ids = self.search([
-                            ('uuid', '=', event.uuid),
-                            ('calendar.owner.email', 'in', attendee_emails),
-                            ('id', '!=', event.id),
-                            ('recurrence', '=', event.recurrence or False),
-                            ])
-                        for event2 in self.browse(event_ids):
-                            if event2.calendar.owner.email in attendee_emails:
-                                attendee_emails.remove(
-                                        event2.calendar.owner.email)
+                with Transaction().set_user(0):
+                    event_ids = self.search([
+                        ('uuid', '=', event.uuid),
+                        ('id', '!=', event.id),
+                        ('recurrence', '=', event.recurrence or False),
+                        ])
+                    for event2 in self.browse(event_ids):
+                        if event2.calendar.owner.email in attendee_emails:
+                            attendee_emails.remove(
+                                    event2.calendar.owner.email)
+                        else:
+                            event_ids.remove(event2.id)
+                            self.delete(event2.id)
+                    if event_ids:
                         self.write(event_ids, self._event2update(event))
                 if attendee_emails:
                     with Transaction().set_user(0):
diff --git a/trytond_calendar.egg-info/PKG-INFO b/trytond_calendar.egg-info/PKG-INFO
index e6c9d58..0489bbe 100644
--- a/trytond_calendar.egg-info/PKG-INFO
+++ b/trytond_calendar.egg-info/PKG-INFO
@@ -1,6 +1,6 @@
 Metadata-Version: 1.0
 Name: trytond-calendar
-Version: 1.8.1
+Version: 1.8.2
 Summary: Add CalDAV support
 Home-page: http://www.tryton.org/
 Author: B2CK
-- 
tryton-modules-calendar



More information about the tryton-debian-vcs mailing list