projects
/
cascardo
/
eventmanager.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Mudança da data final de inscrição.
[cascardo/eventmanager.git]
/
decorators.py
diff --git
a/decorators.py
b/decorators.py
index
079a484
..
6918158
100644
(file)
--- a/
decorators.py
+++ b/
decorators.py
@@
-17,7
+17,10
@@
License along with this program; if not, write to the
Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA.
+ Changes:
+
* Lincoln de Sousa (22 Jul 2007) adding is_login_form here.
* Lincoln de Sousa (22 Jul 2007) adding is_login_form here.
+
"""
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.auth import login
"""
from django.contrib.auth.forms import AuthenticationForm
from django.contrib.auth import login
@@
-40,10
+43,9
@@
def enable_login_form(func):
request.session.delete_test_cookie()
except KeyError:
pass
request.session.delete_test_cookie()
except KeyError:
pass
+ return HttpResponseRedirect('/')
else:
else:
- # TODO: Notify the user that data sent is wrong.
- msg = _('User name and Password doesn\'t match')
- request.error_message = msg
+ return HttpResponseRedirect('/?login_failed')
request.session.set_test_cookie()
return func(request, *args, **kwargs)
request.session.set_test_cookie()
return func(request, *args, **kwargs)