diff -r d8f2ec7e91fa -r 993997b4b41d web/views/basetemplates.py --- a/web/views/basetemplates.py Tue Oct 13 16:00:09 2009 +0200 +++ b/web/views/basetemplates.py Tue Oct 13 18:20:05 2009 +0200 @@ -58,7 +58,7 @@ # FIXME Deprecated code ? msg = self._cw._('you have been logged out') w(u'
' % ( xml_escape(indexurl), @@ -489,7 +489,7 @@ if message: self.display_message() - if self._cw.config['auth-mode'] == 'http': + if self._cw.vreg.config['auth-mode'] == 'http': # HTTP authentication pass else: @@ -505,22 +505,28 @@ def login_form(self, id): _ = self._cw._ self.w(u'
\n') self._cw.html_headers.add_onload('jQuery("#__login:visible").focus()') + def add_fields(self): + msg = (self._cw.vreg.config['allow-email-login'] and _('login or email')) or _('login') + self.add_field('__login', msg, 'text') + self.add_field('__password', self._cw._('password'), 'password') + + def add_field(self, name, label, inputtype): + self.w(u'