Browse Source

Fix qa

pull/537/head
Eduardo Edson Batista Cordeiro Alves 9 years ago
parent
commit
db1ac508e0
  1. 3
      sapl/base/forms.py
  2. 5
      sapl/base/views.py
  3. 4
      sapl/templates/base/RelatorioMateriasPorAutor_filter.html

3
sapl/base/forms.py

@ -11,8 +11,7 @@ from django.utils.translation import ugettext_lazy as _
from sapl.crispy_layout_mixin import form_actions, to_row from sapl.crispy_layout_mixin import form_actions, to_row
from sapl.materia.models import MateriaLegislativa from sapl.materia.models import MateriaLegislativa
from sapl.settings import MAX_IMAGE_UPLOAD_SIZE from sapl.settings import MAX_IMAGE_UPLOAD_SIZE
from sapl.utils import (RANGE_ANOS, ImageThumbnailFileInput, autor_label, from sapl.utils import ImageThumbnailFileInput, autor_label, autor_modal
autor_modal)
from .models import CasaLegislativa from .models import CasaLegislativa

5
sapl/base/views.py

@ -6,7 +6,7 @@ from django.views.generic.base import TemplateView
from django_filters.views import FilterView from django_filters.views import FilterView
from sapl.crud.base import (Crud, CrudBaseMixin, CrudCreateView, from sapl.crud.base import (Crud, CrudBaseMixin, CrudCreateView,
CrudDetailView, CrudUpdateView, make_pagination) CrudDetailView, CrudUpdateView)
from sapl.materia.models import MateriaLegislativa, TipoMateriaLegislativa from sapl.materia.models import MateriaLegislativa, TipoMateriaLegislativa
from sapl.utils import permissao_tb_aux from sapl.utils import permissao_tb_aux
@ -21,7 +21,6 @@ def get_casalegislativa():
class RelatorioMateriasPorAutorView(FilterView): class RelatorioMateriasPorAutorView(FilterView):
model = MateriaLegislativa model = MateriaLegislativa
filterset_class = RelatorioMateriasPorAutorFilterSet filterset_class = RelatorioMateriasPorAutorFilterSet
paginate_by = 10
template_name = 'base/RelatorioMateriasPorAutor_filter.html' template_name = 'base/RelatorioMateriasPorAutor_filter.html'
def get_filterset_kwargs(self, filterset_class): def get_filterset_kwargs(self, filterset_class):
@ -29,8 +28,6 @@ class RelatorioMateriasPorAutorView(FilterView):
self).get_filterset_kwargs(filterset_class) self).get_filterset_kwargs(filterset_class)
kwargs = {'data': self.request.GET or None} kwargs = {'data': self.request.GET or None}
qs = self.get_queryset()
return kwargs return kwargs
def get_context_data(self, **kwargs): def get_context_data(self, **kwargs):

4
sapl/templates/base/RelatorioMateriasPorAutor_filter.html

@ -55,10 +55,6 @@
{% endfor %} {% endfor %}
</tbody> </tbody>
</table> </table>
{% include "paginacao.html" %}
{% endif %} {% endif %}
{% endblock base_content %} {% endblock base_content %}

Loading…
Cancel
Save