Add Django OAuth toolkit admin
This commit is contained in:
parent
6d54aae614
commit
72bac75fbd
3 changed files with 16 additions and 4 deletions
|
|
@ -32,9 +32,6 @@ urlpatterns = [
|
|||
path('api/', include('api.urls')),
|
||||
path('permission/', include('permission.urls')),
|
||||
|
||||
# OAuth2 provider
|
||||
path('o/', include('oauth2_provider.urls', namespace='oauth2_provider')),
|
||||
|
||||
# Make coffee
|
||||
path('coffee/', include('django_htcpcp_tea.urls')),
|
||||
]
|
||||
|
|
@ -43,6 +40,11 @@ urlpatterns = [
|
|||
if settings.DEBUG:
|
||||
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
|
||||
if "oauth2_provider" in settings.INSTALLED_APPS:
|
||||
# OAuth2 provider
|
||||
urlpatterns.append(
|
||||
path('o/', include('oauth2_provider.urls', namespace='oauth2_provider'))
|
||||
)
|
||||
|
||||
if "debug_toolbar" in settings.INSTALLED_APPS:
|
||||
import debug_toolbar
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue