mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-21 21:53:30 +00:00
Add Django debug toolbar
This commit is contained in:
parent
aa93211025
commit
a4984317e9
@ -11,5 +11,6 @@ django-ajax-selects
|
||||
reportlab
|
||||
django-haystack
|
||||
whoosh
|
||||
django-debug-toolbar
|
||||
# mysqlclient
|
||||
|
||||
|
@ -481,3 +481,8 @@ try:
|
||||
print("Custom settings imported")
|
||||
except:
|
||||
print("Custom settings failed")
|
||||
|
||||
if DEBUG:
|
||||
INTERNAL_IPS = ['127.0.0.1']
|
||||
INSTALLED_APPS += ("debug_toolbar",)
|
||||
MIDDLEWARE_CLASSES = ('debug_toolbar.middleware.DebugToolbarMiddleware',) + MIDDLEWARE_CLASSES
|
||||
|
@ -49,4 +49,8 @@ urlpatterns = [
|
||||
if settings.DEBUG:
|
||||
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
|
||||
import debug_toolbar
|
||||
urlpatterns += [
|
||||
url(r'^__debug__/', include(debug_toolbar.urls)),
|
||||
]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user