Update to Django 1.9
- update all dependencies - fix deprecation warnings and errors for Django 1.9 compatibility
This commit is contained in:
parent
1b30b1a38c
commit
085b126416
21 changed files with 85 additions and 110 deletions
|
@ -46,9 +46,6 @@ path.append(DJANGO_ROOT)
|
|||
# ######### DEBUG CONFIGURATION
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#debug
|
||||
DEBUG = False
|
||||
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#template-debug
|
||||
TEMPLATE_DEBUG = DEBUG
|
||||
# ######### END DEBUG CONFIGURATION
|
||||
|
||||
|
||||
|
@ -158,34 +155,31 @@ FIXTURE_DIRS = (
|
|||
|
||||
|
||||
# ######### TEMPLATE CONFIGURATION
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#template-context-processors # noqa
|
||||
TEMPLATE_CONTEXT_PROCESSORS = (
|
||||
'django.contrib.auth.context_processors.auth',
|
||||
'django.core.context_processors.debug',
|
||||
'django.core.context_processors.i18n',
|
||||
'django.core.context_processors.media',
|
||||
'django.core.context_processors.static',
|
||||
'django.core.context_processors.tz',
|
||||
'django.contrib.messages.context_processors.messages',
|
||||
'django.core.context_processors.request',
|
||||
# allauth specific context processors
|
||||
'allauth.account.context_processors.account',
|
||||
'allauth.socialaccount.context_processors.socialaccount',
|
||||
# custom context processors
|
||||
'gnuviechadmin.context_processors.navigation',
|
||||
'gnuviechadmin.context_processors.version_info',
|
||||
)
|
||||
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#template-loaders
|
||||
TEMPLATE_LOADERS = (
|
||||
'django.template.loaders.filesystem.Loader',
|
||||
'django.template.loaders.app_directories.Loader',
|
||||
)
|
||||
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#template-dirs
|
||||
TEMPLATE_DIRS = (
|
||||
normpath(join(SITE_ROOT, 'templates')),
|
||||
)
|
||||
# See: https://docs.djangoproject.com/en/1.9/ref/settings/#std:setting-TEMPLATES # noqa
|
||||
TEMPLATES = [
|
||||
{
|
||||
'BACKEND': 'django.template.backends.django.DjangoTemplates',
|
||||
'DIRS': [
|
||||
normpath(join(SITE_ROOT, 'templates')),
|
||||
],
|
||||
'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.static',
|
||||
'django.template.context_processors.tz',
|
||||
'django.contrib.messages.context_processors.messages',
|
||||
'django.template.context_processors.request',
|
||||
# custom context processors
|
||||
'gnuviechadmin.context_processors.navigation',
|
||||
'gnuviechadmin.context_processors.version_info',
|
||||
],
|
||||
},
|
||||
},
|
||||
]
|
||||
# ######### END TEMPLATE CONFIGURATION
|
||||
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ from .base import * # NOQA
|
|||
DEBUG = True
|
||||
|
||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#template-debug
|
||||
TEMPLATE_DEBUG = DEBUG
|
||||
TEMPLATES[0]['OPTIONS']['debug'] = DEBUG
|
||||
# ######### END DEBUG CONFIGURATION
|
||||
|
||||
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
from __future__ import absolute_import
|
||||
|
||||
from django.conf.urls import patterns, include, url
|
||||
from django.conf.urls import include, url
|
||||
from django.conf import settings
|
||||
|
||||
from django.contrib import admin
|
||||
from django.contrib.flatpages import views
|
||||
admin.autodiscover()
|
||||
|
||||
urlpatterns = patterns(
|
||||
'',
|
||||
urlpatterns = [
|
||||
url(r'', include('dashboard.urls')),
|
||||
url(r'^accounts/', include('allauth.urls')),
|
||||
url(r'^database/', include('userdbs.urls')),
|
||||
|
@ -16,19 +16,18 @@ urlpatterns = patterns(
|
|||
url(r'^website/', include('websites.urls')),
|
||||
url(r'^mail/', include('managemails.urls')),
|
||||
url(r'^osuser/', include('osusers.urls')),
|
||||
url(r'^admin/', include(admin.site.urls)),
|
||||
url(r'^admin/', admin.site.urls),
|
||||
url(r'^contact/', include('contact_form.urls')),
|
||||
)
|
||||
urlpatterns += patterns(
|
||||
'django.contrib.flatpages.views',
|
||||
url(r'^impressum/$', 'flatpage', {'url': '/impressum/'}, name='imprint'),
|
||||
)
|
||||
url(r'^impressum/$', views.flatpage, {
|
||||
'url': '/impressum/'
|
||||
}, name='imprint'),
|
||||
]
|
||||
|
||||
# Uncomment the next line to serve media files in dev.
|
||||
# urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
|
||||
|
||||
if settings.DEBUG: # pragma: no cover
|
||||
import debug_toolbar
|
||||
urlpatterns += patterns('',
|
||||
url(r'^__debug__/', include(debug_toolbar.urls)),
|
||||
)
|
||||
urlpatterns += [
|
||||
url(r'^__debug__/', debug_toolbar.urls),
|
||||
]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue