Make contrib plugins compatible with django 1.9
parent
5e51ed4ee5
commit
7c505b70d9
|
@ -1,20 +0,0 @@
|
|||
# Copyright (C) 2014-2016 Andrey Antukh <niwi@niwi.nz>
|
||||
# Copyright (C) 2014-2016 Jesús Espino <jespinog@gmail.com>
|
||||
# Copyright (C) 2014-2016 David Barragán <bameda@dbarragan.com>
|
||||
# Copyright (C) 2014-2016 Alejandro Alonso <alejandro.alonso@kaleidos.net>
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
from taiga.base import routers
|
||||
|
||||
router = routers.DefaultRouter(trailing_slash=False)
|
|
@ -24,7 +24,7 @@ from django.conf import settings
|
|||
def get_modules_config(project):
|
||||
modules_config, created = models.ProjectModulesConfig.objects.get_or_create(project=project)
|
||||
|
||||
if created:
|
||||
if created or modules_config.config == None:
|
||||
modules_config.config = {}
|
||||
|
||||
for key, configurator_function_name in settings.PROJECT_MODULES_CONFIGURATORS.items():
|
||||
|
|
|
@ -20,7 +20,6 @@ from django.conf.urls import patterns, include, url
|
|||
from django.contrib import admin
|
||||
|
||||
from .routers import router
|
||||
from .contrib_routers import router as contrib_router
|
||||
|
||||
|
||||
##############################################
|
||||
|
@ -29,7 +28,6 @@ from .contrib_routers import router as contrib_router
|
|||
|
||||
urlpatterns = [
|
||||
url(r'^api/v1/', include(router.urls)),
|
||||
url(r'^api/v1/', include(contrib_router.urls)),
|
||||
url(r'^api/v1/api-auth/', include('taiga.base.api.urls', namespace='api')),
|
||||
url(r'^admin/', include(admin.site.urls)),
|
||||
]
|
||||
|
|
Loading…
Reference in New Issue