Browse Source

Merge pull request #294 from interlegis/287-Filtrar_Anos_De_Norma

Fix #287 Muda opções de ano na pesquisa de Norma
pull/278/merge
Edward 9 years ago
parent
commit
caf0d68541
  1. 8
      norma/forms.py

8
norma/forms.py

@ -49,6 +49,14 @@ class NormaJuridicaPesquisaForm(ModelForm):
format='%d/%m/%Y',
attrs={'class': 'dateinput'}))
ano = forms.ModelChoiceField(
label='Ano',
required=False,
queryset=NormaJuridica.objects.order_by('ano').values_list(
'ano', flat=True).distinct(),
empty_label='Selecione'
)
class Meta:
model = NormaJuridica
fields = ['tipo',

Loading…
Cancel
Save