From 62362207c84f4a362f2b186f1d05f6564bd2ccda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Fri, 19 Jan 2018 13:55:46 +0100 Subject: [PATCH] settings: add requests context processor (#21007) --- corbo/settings.py | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/corbo/settings.py b/corbo/settings.py index 29f740d..0edebf4 100644 --- a/corbo/settings.py +++ b/corbo/settings.py @@ -24,8 +24,6 @@ SECRET_KEY = '$%7m&rq1-&$c77a1s^_$=xgiqez-%_x3^&5=*^-4(6si2zu59z' # SECURITY WARNING: don't run with debug turned on in production! DEBUG = True -TEMPLATE_DEBUG = True - ALLOWED_HOSTS = [] @@ -84,6 +82,27 @@ USE_TZ = True STATICFILES_FINDERS = global_settings.STATICFILES_FINDERS + ('gadjo.finders.XStaticFinder',) +# Templates +TEMPLATES = [ + { + 'BACKEND': 'django.template.backends.django.DjangoTemplates', + 'DIRS': [ + ], + 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.contrib.auth.context_processors.auth', + 'django.template.context_processors.debug', + 'django.template.context_processors.i18n', + 'django.template.context_processors.media', + 'django.template.context_processors.request', + 'django.template.context_processors.static', + 'django.template.context_processors.tz', + 'django.contrib.messages.context_processors.messages', + ], + }, + }, +] # Static files (CSS, JavaScript, Images) # https://docs.djangoproject.com/en/1.7/howto/static-files/ -- 2.15.1