From 509ea49e58e814dc7741dfa654effc61a4e43b15 Mon Sep 17 00:00:00 2001 From: Edward Ribeiro Date: Mon, 16 Apr 2018 17:50:25 -0300 Subject: [PATCH] Fixes #1877 --- sapl/sessao/forms.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sapl/sessao/forms.py b/sapl/sessao/forms.py index f20a9e21c..6bb6b13e6 100644 --- a/sapl/sessao/forms.py +++ b/sapl/sessao/forms.py @@ -345,6 +345,10 @@ class SessaoPlenariaFilterSet(django_filters.FilterSet): def __init__(self, *args, **kwargs): super(SessaoPlenariaFilterSet, self).__init__(*args, **kwargs) + # pré-popula o campo do formulário com o ano corrente + self.form.fields['data_inicio__year'].initial = timezone.now().year + + row1 = to_row( [('data_inicio__year', 3), ('data_inicio__month', 3),