diff --git a/taxi_service/settings.py b/taxi_service/settings.py index cc0368eb..37713182 100644 --- a/taxi_service/settings.py +++ b/taxi_service/settings.py @@ -27,6 +27,7 @@ # SECURITY WARNING: don"t run with debug turned on in production! DEBUG = True LOGIN_REDIRECT_URL = "/" +LOGIN_URL = "login" ALLOWED_HOSTS = [] diff --git a/taxi_service/urls.py b/taxi_service/urls.py index 2d314449..076476a0 100644 --- a/taxi_service/urls.py +++ b/taxi_service/urls.py @@ -21,8 +21,8 @@ urlpatterns = [ - path("login/", auth_views.LoginView.as_view()), - path("logout/", auth_views.LogoutView.as_view()), + path("login/", auth_views.LoginView.as_view(), name="login"), + path("logout/", auth_views.LogoutView.as_view(), name="logout"), path("admin/", admin.site.urls), path("", include("taxi.urls", namespace="taxi")), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)