Handle reverse_lazy

Fixes #209.
This commit is contained in:
Cristi Vîjdea
2018-09-13 03:38:13 +03:00
parent 586b88d8f3
commit 857ef05b07
2 changed files with 7 additions and 1 deletions
+3 -1
View File
@@ -1,6 +1,8 @@
import os
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
from django.urls import reverse_lazy
BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
ALLOWED_HOSTS = [
@@ -91,7 +93,7 @@ REST_FRAMEWORK = {
# drf-yasg
SWAGGER_SETTINGS = {
'LOGIN_URL': '/admin/login',
'LOGIN_URL': reverse_lazy('admin:login'),
'LOGOUT_URL': '/admin/logout',
'DEFAULT_INFO': 'testproj.urls.swagger_info',