From 2ae39c763e9328043acc20725484d0635dedaba4 Mon Sep 17 00:00:00 2001 From: Eduardo Edson Batista Cordeiro Alves Date: Wed, 31 Aug 2016 12:06:03 -0300 Subject: [PATCH] Ajusta url de detalhe para comissao --- sapl/parlamentares/views.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sapl/parlamentares/views.py b/sapl/parlamentares/views.py index 6506c9739..6bff705ec 100644 --- a/sapl/parlamentares/views.py +++ b/sapl/parlamentares/views.py @@ -2,7 +2,7 @@ from django.contrib import messages from django.contrib.auth.mixins import PermissionRequiredMixin from django.contrib.auth.models import Permission from django.contrib.contenttypes.models import ContentType -from django.core.urlresolvers import reverse_lazy +from django.core.urlresolvers import reverse, reverse_lazy from django.shortcuts import redirect from django.utils.datastructures import MultiValueDictKeyError from django.utils.translation import ugettext_lazy as _ @@ -36,7 +36,9 @@ class ParticipacaoParlamentarCrud(MasterDetailCrud): for p in object_list: if p.cargo.nome != 'Relator': comissao = [ - (p.composicao.comissao.nome, p.composicao.comissao.pk), + (p.composicao.comissao.nome, reverse( + 'sapl.comissoes:comissao_detail', kwargs={ + 'pk': p.composicao.comissao.pk})), (p.cargo.nome, None), (p.composicao.periodo.data_inicio.strftime( "%d/%m/%Y") + ' a ' +