--- a/web/views/basecontrollers.py Thu Mar 01 12:08:35 2012 +0100
+++ b/web/views/basecontrollers.py Thu Mar 15 17:42:31 2012 +0100
@@ -84,6 +84,17 @@
# Cookie authentication
return self.appli.need_login_content(self._cw)
+class LoginControllerForAuthed(Controller):
+ __regid__ = 'login'
+ __select__ = ~anonymous_user()
+
+ def publish(self, rset=None):
+ """log in the instance"""
+ path = self._cw.form.get('postlogin_path')
+ if not path:
+ path = '/'
+ raise Redirect(path)
+
class LogoutController(Controller):
__regid__ = 'logout'