MAJ : MAJ 2.0, remove debug_panel, django.change url.resolvers to django.urls

This commit is contained in:
Qwann 2018-08-27 00:30:12 +02:00
parent b45d7722a7
commit 906db7069b
6 changed files with 9 additions and 8 deletions

View file

@ -10,7 +10,7 @@ We also load the secrets in this file.
import os
from . import secret
from django.core.urlresolvers import reverse_lazy
from django.urls import reverse_lazy
from django.contrib import messages
@ -85,7 +85,7 @@ MIDDLEWARE = [
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
# 'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
]

View file

@ -11,9 +11,11 @@ EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
DEBUG = True
# Add some debugging tools
INSTALLED_APPS += ["debug_toolbar", "debug_panel"] # NOQA
INSTALLED_APPS += ["debug_toolbar", ] # NOQA
MIDDLEWARE = (
["debug_panel.middleware.DebugPanelMiddleware"]
[
"debug_toolbar.middleware.DebugToolbarMiddleware",
]
+ MIDDLEWARE # NOQA
)

View file

@ -1,4 +1,3 @@
-r requirements.txt
django-debug-toolbar
django-debug-panel
ipython

View file

@ -2,7 +2,7 @@ asgi-redis==1.3.0
asgiref==1.1.1
django-bootstrap3==10.0.1
channels==1.1.5
Django==1.11.11
Django==2.0
django-allauth==0.36.0
django-allauth-cas==1.0.0b2
django-tables2==2.0.0a2

View file

@ -1,6 +1,6 @@
from django.conf.urls import url
from django.contrib.auth import views as auth_views
from django.core.urlresolvers import reverse_lazy
from django.urls import reverse_lazy
from django.utils.translation import ugettext_lazy as _
from shared.views import Home
from users.views import CreateUser

View file

@ -1,7 +1,7 @@
from .forms import CreateUserForm
from django.views.generic.edit import CreateView
from django.contrib.messages.views import SuccessMessageMixin
from django.core.urlresolvers import reverse_lazy
from django.urls import reverse_lazy
class CreateUser(SuccessMessageMixin, CreateView):