django2.2: replace deprecated login view

This commit is contained in:
2019-10-06 02:24:03 +02:00
parent 99c8d95443
commit 308cf30a5a
2 changed files with 6 additions and 8 deletions

View File

@ -69,15 +69,13 @@ from counter.views import StudentCardForm
from trombi.views import UserTrombiForm
def login(request):
class SithLoginView(views.LoginView):
"""
The login View
"""
The login view
Needs to be improve with correct handling of form exceptions
"""
return views.login(
request, template_name="core/login.jinja", authentication_form=LoginForm
)
template_name = "core/login.jinja"
authentication_form = LoginForm
def logout(request):