Install rest-auth
This commit is contained in:
parent
24386dbcec
commit
1ee7ca25e1
|
@ -37,7 +37,13 @@ INSTALLED_APPS = [
|
||||||
'django.contrib.sessions',
|
'django.contrib.sessions',
|
||||||
'django.contrib.messages',
|
'django.contrib.messages',
|
||||||
'django.contrib.staticfiles',
|
'django.contrib.staticfiles',
|
||||||
|
'django.contrib.sites',
|
||||||
'rest_framework',
|
'rest_framework',
|
||||||
|
'rest_framework.authtoken',
|
||||||
|
'rest_auth',
|
||||||
|
'allauth',
|
||||||
|
'allauth.account',
|
||||||
|
'rest_auth.registration',
|
||||||
]
|
]
|
||||||
|
|
||||||
MIDDLEWARE = [
|
MIDDLEWARE = [
|
||||||
|
@ -119,3 +125,5 @@ USE_TZ = True
|
||||||
# https://docs.djangoproject.com/en/3.1/howto/static-files/
|
# https://docs.djangoproject.com/en/3.1/howto/static-files/
|
||||||
|
|
||||||
STATIC_URL = '/static/'
|
STATIC_URL = '/static/'
|
||||||
|
|
||||||
|
SITE_ID = 1
|
||||||
|
|
|
@ -7,5 +7,7 @@ router.register(r'users', views.UserViewSet)
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
path('', include(router.urls)),
|
path('', include(router.urls)),
|
||||||
path('api-auth/', include('rest_framework.urls', namespace='rest_framework'))
|
path('api-auth/', include('rest_framework.urls', namespace='rest_framework')),
|
||||||
|
url(r'^rest-auth/', include('rest_auth.urls')),
|
||||||
|
url(r'^rest-auth/registration/', include('rest_auth.registration.urls')),
|
||||||
]
|
]
|
||||||
|
|
Loading…
Reference in New Issue
Block a user