|
@ -13,6 +13,7 @@ from django.template import Context, loader |
|
|
from django.utils.translation import ugettext_lazy as _ |
|
|
from django.utils.translation import ugettext_lazy as _ |
|
|
from django.views.generic import CreateView, FormView, ListView, TemplateView |
|
|
from django.views.generic import CreateView, FormView, ListView, TemplateView |
|
|
|
|
|
|
|
|
|
|
|
import crud.base |
|
|
from base.models import CasaLegislativa |
|
|
from base.models import CasaLegislativa |
|
|
from comissoes.models import Comissao, Composicao |
|
|
from comissoes.models import Comissao, Composicao |
|
|
from compilacao.views import IntegracaoTaView |
|
|
from compilacao.views import IntegracaoTaView |
|
@ -23,7 +24,6 @@ from sapl.utils import get_base_url |
|
|
|
|
|
|
|
|
from .forms import (AcompanhamentoMateriaForm, AutoriaForm, |
|
|
from .forms import (AcompanhamentoMateriaForm, AutoriaForm, |
|
|
DespachoInicialForm, DocumentoAcessorioForm, |
|
|
DespachoInicialForm, DocumentoAcessorioForm, |
|
|
FormularioCadastroForm, FormularioSimplificadoForm, |
|
|
|
|
|
LegislacaoCitadaForm, MateriaAnexadaForm, |
|
|
LegislacaoCitadaForm, MateriaAnexadaForm, |
|
|
MateriaLegislativaPesquisaForm, NumeracaoForm, |
|
|
MateriaLegislativaPesquisaForm, NumeracaoForm, |
|
|
ProposicaoForm, RelatoriaForm, TramitacaoForm) |
|
|
ProposicaoForm, RelatoriaForm, TramitacaoForm) |
|
@ -56,16 +56,16 @@ UnidadeTramitacaoCrud = Crud.build(UnidadeTramitacao, 'unidade_tramitacao') |
|
|
TramitacaoCrud = Crud.build(Tramitacao, '') |
|
|
TramitacaoCrud = Crud.build(Tramitacao, '') |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class FormularioSimplificadoView(CreateView): |
|
|
# TODO qual url? |
|
|
template_name = "materia/formulario_simplificado.html" |
|
|
class MateriaLegislativaSimplificadaCrud(Crud): |
|
|
form_class = FormularioSimplificadoForm |
|
|
model = MateriaLegislativa |
|
|
success_url = reverse_lazy('materia:materialegislativa_list') |
|
|
help_path = '' |
|
|
|
|
|
|
|
|
|
|
|
class CreateView(crud.base.CrudCreateView): |
|
|
|
|
|
|
|
|
class FormularioCadastroView(CreateView): |
|
|
@property |
|
|
template_name = "materia/formulario_cadastro.html" |
|
|
def layout_key(self): |
|
|
form_class = FormularioCadastroForm |
|
|
return 'MateriaLegislativaSimplificado' |
|
|
success_url = reverse_lazy('materia:formulario_cadastro') |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class MateriaAnexadaView(FormView): |
|
|
class MateriaAnexadaView(FormView): |
|
|