imip-agent

Change of imip_manager.py

291:e28bfb8b0ca1
imip_manager.py
     1.1 --- a/imip_manager.py	Sun Feb 08 01:26:33 2015 +0100
     1.2 +++ b/imip_manager.py	Sun Feb 08 18:39:03 2015 +0100
     1.3 @@ -34,7 +34,7 @@
     1.4  from imiptools.data import get_address, get_uri, make_freebusy, parse_object, \
     1.5                             Object, to_part
     1.6  from imiptools.dates import format_datetime, format_time, get_date, get_datetime, \
     1.7 -                            get_datetime_item, \
     1.8 +                            get_datetime_item, get_default_timezone, \
     1.9                              get_end_of_day, get_start_of_day, get_start_of_next_day, \
    1.10                              get_timestamp, ends_on_same_day, to_timezone
    1.11  from imiptools.mail import Messenger
    1.12 @@ -292,7 +292,7 @@
    1.13  
    1.14      def get_tzid(self):
    1.15          prefs = self.get_preferences()
    1.16 -        return prefs.get("TZID", "UTC")
    1.17 +        return prefs.get("TZID") or get_default_timezone()
    1.18  
    1.19      # Prettyprinting of dates and times.
    1.20  
    1.21 @@ -1297,7 +1297,7 @@
    1.22  
    1.23                              has_continued = continuation and point != start
    1.24                              will_continue = not ends_on_same_day(point, end, tzid)
    1.25 -                            is_organiser = obj.get_value("ORGANIZER") == self.user
    1.26 +                            is_organiser = obj and obj.get_value("ORGANIZER") == self.user
    1.27  
    1.28                              css = " ".join(
    1.29                                  ["event"] +
    1.30 @@ -1314,7 +1314,7 @@
    1.31                                  page.td(class_=css, rowspan=span)
    1.32  
    1.33                              if not obj:
    1.34 -                                page.span("")
    1.35 +                                page.span("(Participant is busy)")
    1.36                              else:
    1.37                                  summary = obj.get_value("SUMMARY")
    1.38