Guest User

Untitled

a guest
Feb 25th, 2014
58
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. class ApplicationView(BrowserView):
  2. """A view for the main application."""
  3.  
  4. def update(self):
  5. prefs = IApplicationPreferences(ISchoolToolApplication(None))
  6. if prefs.frontPageCalendar:
  7. url = absoluteURL(ISchoolToolCalendar(self.context),
  8. self.request)
  9. url += '/monthly.html'
  10. else:
  11. url = absoluteURL(self.context,
  12. self.request) + '/auth/@@login.html'
  13. self.request.response.redirect(url)
RAW Paste Data