From b3a830753a7165c68a0c2624e453c23ddbf65804 Mon Sep 17 00:00:00 2001 From: Edward Ribeiro Date: Wed, 7 Jun 2017 18:07:03 -0300 Subject: [PATCH] Fixes #1179 --- sapl/base/forms.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sapl/base/forms.py b/sapl/base/forms.py index 11d93a13f..259fe8950 100644 --- a/sapl/base/forms.py +++ b/sapl/base/forms.py @@ -505,6 +505,11 @@ class RelatorioHistoricoTramitacaoFilterSet(django_filters.FilterSet): 'widget': RangeWidgetOverride} }} + @property + def qs(self): + parent = super(RelatorioHistoricoTramitacaoFilterSet, self).qs + return parent.distinct().order_by('-ano', 'tipo', 'numero') + class Meta: model = MateriaLegislativa fields = ['tipo', 'tramitacao__unidade_tramitacao_local',