Browse Source

Rename views

pull/6/head
Marcio Mazza 10 years ago
parent
commit
8e6e59cdbd
  1. 8
      comissoes/urls.py
  2. 6
      comissoes/views.py

8
comissoes/urls.py

@ -1,15 +1,15 @@
from django.conf.urls import url
from comissoes.views import (
comissao_crud, ComposicaoListView, MateriasListView, ReunioesListView)
comissao_crud, ComposicaoView, MateriasView, ReunioesView)
urlpatterns = comissao_crud.urlpatterns + [
url(r'^(?P<pk>\d+)/composicao$',
ComposicaoListView.as_view(), name='composicao'),
ComposicaoView.as_view(), name='composicao'),
url(r'^(?P<pk>\d+)/materias$',
MateriasListView.as_view(), name='materias'),
MateriasView.as_view(), name='materias'),
url(r'^(?P<pk>\d+)/reunioes$',
ReunioesListView.as_view(), name='reunioes'),
ReunioesView.as_view(), name='reunioes'),
]
comissoes_urls = urlpatterns, comissao_crud.namespace, comissao_crud.namespace

6
comissoes/views.py

@ -55,13 +55,13 @@ comissao_crud = build_crud(
)
class ComposicaoListView(comissao_crud.CrudDetailView):
class ComposicaoView(comissao_crud.CrudDetailView):
template_name = 'comissoes/composicao.html'
class MateriasListView(comissao_crud.CrudDetailView):
class MateriasView(comissao_crud.CrudDetailView):
template_name = 'comissoes/materias.html'
class ReunioesListView(comissao_crud.CrudDetailView):
class ReunioesView(comissao_crud.CrudDetailView):
template_name = 'comissoes/reunioes.html'

Loading…
Cancel
Save