Example #1
0
def evolveScheduleContainers(app):
    annotations = IAnnotations(app)
    prefs = getApplicationPreferences(app)
    schedule_containers = app[SCHEDULES_KEY]
    for container in schedule_containers.values():
        if container.timezone != prefs.timezone:
            container.timezone = prefs.timezone
            zope.lifecycleevent.modified(container)
Example #2
0
def evolveTimetableContainers(app):
    annotations = IAnnotations(app)
    prefs = getApplicationPreferences(app)
    schedule_containers = app[TIMETABLES_KEY]
    for container in schedule_containers.values():
        for timetable in container.values():
            if timetable.timezone != prefs.timezone:
                timetable.timezone = prefs.timezone
                zope.lifecycleevent.modified(timetable)
Example #3
0
 def initializePreferences(self, app):
     prefs = getApplicationPreferences(app)
     prefs.initializeTimezone()
Example #4
0
 def initializePreferences(self, app):
     prefs = getApplicationPreferences(app)
     prefs.initializeTimezone()