Remove usage of patterns

Usage of patterns in obsolete, so removing the same.

Change-Id: I5199676041b91f419bacad1fd19e33004e442758
This commit is contained in:
Anusha Ramineni 2017-07-12 10:51:48 +05:30
parent 3225f02334
commit 955d6d76eb
2 changed files with 4 additions and 8 deletions

View File

@ -12,7 +12,6 @@
# License for the specific language governing permissions and limitations
# under the License.
from django.conf.urls import patterns
from django.conf.urls import url
from congress_dashboard.datasources import views
@ -23,8 +22,7 @@ SERVICES = (
DATASOURCE = r'^(?P<datasource_id>[^/]+)/%s$'
urlpatterns = patterns(
'',
urlpatterns = [
url(r'^$', views.IndexView.as_view(), name='index'),
url(r'^create/$', views.CreateView.as_view(), name='create'),
url(SERVICES % 'detail', views.DetailView.as_view(),
@ -32,4 +30,4 @@ urlpatterns = patterns(
url(DATASOURCE % 'detail', views.DatasourceView.as_view(),
name='datasource_detail'),
)
]

View File

@ -12,7 +12,6 @@
# License for the specific language governing permissions and limitations
# under the License.
from django.conf.urls import patterns
from django.conf.urls import url
from congress_dashboard.datasources import views as data_views
@ -24,8 +23,7 @@ POLICY = r'^(?P<policy_name>[^/]+)/%s$'
POLICYTABLE = r'^(?P<datasource_id>[^/]+)/(?P<policy_table_name>[^/]+)/%s$'
urlpatterns = patterns(
'',
urlpatterns = [
url(r'^$', views.IndexView.as_view(), name='index'),
url(r'^create/$', views.CreateView.as_view(), name='create'),
url(POLICY % 'detail', views.DetailView.as_view(), name='detail'),
@ -33,4 +31,4 @@ urlpatterns = patterns(
name='policy_table_detail'),
url(POLICY % 'rules/create',
rule_views.CreateView.as_view(), name='create_rule'),
)
]