mirror of https://github.com/interlegis/sapl.git
4 changed files with 130 additions and 15 deletions
@ -0,0 +1,106 @@ |
|||||
|
{% load i18n %} |
||||
|
{% load common_tags %} |
||||
|
{% load static %} |
||||
|
|
||||
|
|
||||
|
<head> |
||||
|
<style> |
||||
|
@page{ |
||||
|
margin-top: 4.5cm; |
||||
|
size: A4 portrait; |
||||
|
|
||||
|
@bottom-right { |
||||
|
content: "Página" counter(page); |
||||
|
height: 3cm; |
||||
|
font-size: 8pt; |
||||
|
} |
||||
|
|
||||
|
@bottom-center { |
||||
|
border-top: 1px solid black; |
||||
|
font-size: 8pt; |
||||
|
height: 1cm; |
||||
|
content: "{{rodape|safe}}"; |
||||
|
font-style:italic; |
||||
|
} |
||||
|
@bottom-left { |
||||
|
content: "{{data}}"; |
||||
|
height: 3cm; |
||||
|
font-size: 8pt; |
||||
|
} |
||||
|
|
||||
|
@top-center { |
||||
|
content: string(title); |
||||
|
} |
||||
|
header { |
||||
|
width: 0; |
||||
|
height: 0; |
||||
|
visibility: hidden; |
||||
|
string-set: title content(); |
||||
|
} |
||||
|
} |
||||
|
</style> |
||||
|
<link rel="stylesheet" href="{% static '/sapl/css/relatorio.css'%}"> |
||||
|
</head> |
||||
|
|
||||
|
<h2>Matérias por Autor</h2> |
||||
|
|
||||
|
<b>PARÂMETROS DE PESQUISA:<br /></b> |
||||
|
 Autor: {{ autor }}<br /> |
||||
|
 Tipo de Norma: {{ tipo }}<br /> |
||||
|
 Data: {{periodo}}<br /><br /><br/> |
||||
|
{% if object_list %} |
||||
|
<table class="table table-bordered table-hover"> |
||||
|
<thead class="thead-default" > |
||||
|
<tr class="active"><th colspan="3" class="text-center">QUADRO GERAL</th></tr> |
||||
|
<tr class="active"> |
||||
|
<th colspan="2">Tipo de Norma</th> |
||||
|
<th>Quantidade</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
{% for key, value in qtdes.items %} |
||||
|
<tr> |
||||
|
<td colspan="2">{{key.sigla}} - {{key}}</td> |
||||
|
<td>{{value}}</td> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
</tbody> |
||||
|
|
||||
|
{% for norma in object_list %} |
||||
|
{% ifchanged norma.autorianorma_set.first.autor %} |
||||
|
|
||||
|
<thead class="thead-default" > |
||||
|
<tr style="border-left: hidden; border-right: hidden;"><th colspan="3"></th></tr> |
||||
|
<tr class="active"><th colspan="3" class="text-center">Autor: {{ norma.autorianorma_set.first.autor }}</th></tr> |
||||
|
<tr class="active"> |
||||
|
<th width="10%">Norma</th> |
||||
|
<th>Ementa</th> |
||||
|
<th width="20%">Coautor(es)</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
{% endifchanged %} |
||||
|
<tbody> |
||||
|
<tr> |
||||
|
<td> |
||||
|
{{norma.tipo.sigla}} {{norma.numero}}/{{norma.ano}} |
||||
|
</td> |
||||
|
<td>{% autoescape off %}{{norma.ementa}}<br>{{norma.observacao}}{% endautoescape %}</td> |
||||
|
<td> |
||||
|
{% if norma.autorianorma_set.first != norma.autorianorma_set.last %} |
||||
|
{% for autor in norma.autorianorma_set.all %} |
||||
|
{% if not autor.primeiro_autor %} |
||||
|
{{ autor.autor }}<br /> |
||||
|
{% endif %} |
||||
|
{% endfor %} |
||||
|
{% endif %} |
||||
|
</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
|
||||
|
{% endfor %} |
||||
|
</table> |
||||
|
{% else %} |
||||
|
<h3>Não foram encontradas normas com os parâmetros pesquisados.</h3> |
||||
|
{% endif %} |
||||
|
|
||||
|
</body> |
||||
Loading…
Reference in new issue