Browse Source

HOT-FIX: adiciona 'indexação' a Norma e corrige acentuação

pull/2196/head
Edward Ribeiro 6 years ago
parent
commit
457c0203c8
  1. 3
      sapl/materia/forms.py
  2. 8
      sapl/norma/forms.py

3
sapl/materia/forms.py

@ -676,7 +676,8 @@ class MateriaLegislativaFilterSet(django_filters.FilterSet):
widget=forms.HiddenInput())
ementa = django_filters.CharFilter(lookup_expr='icontains')
indexacao = django_filters.CharFilter(lookup_expr='icontains')
indexacao = django_filters.CharFilter(lookup_expr='icontains',
label=_('Indexação'))
em_tramitacao = django_filters.ChoiceFilter(required=False,
label='Em tramitação',

8
sapl/norma/forms.py

@ -52,6 +52,9 @@ class NormaFilterSet(django_filters.FilterSet):
ementa = django_filters.CharFilter(lookup_expr='icontains')
indexacao = django_filters.CharFilter(lookup_expr='icontains',
label=_('Indexação'))
assuntos = django_filters.ModelChoiceFilter(
queryset=AssuntoNorma.objects.all())
@ -67,13 +70,14 @@ class NormaFilterSet(django_filters.FilterSet):
row1 = to_row([('tipo', 4), ('numero', 4), ('ano', 4)])
row2 = to_row([('data', 6), ('data_publicacao', 6)])
row3 = to_row([('ementa', 6), ('assuntos', 6), ('o',6)])
row3 = to_row([('ementa', 6), ('assuntos', 6)])
row4 = to_row([('o',6), ('indexacao', 6)])
self.form.helper = FormHelper()
self.form.helper.form_method = 'GET'
self.form.helper.layout = Layout(
Fieldset(_('Pesquisa de Norma'),
row1, row2, row3,
row1, row2, row3, row4,
form_actions(label='Pesquisar'))
)

Loading…
Cancel
Save