mirror of https://github.com/interlegis/sapl.git
Browse Source
Co-authored-by: ulyssesBML <ulysses3353@gmail.com> sobe alterações Iniciando relatorio com weasyprint Atualizando informaçoes do relatorio de reunião Arrumando logo e topicos incompletos Refatorando codigo para gerar relatorio Adicionando butão para novo estilo de relatorio Arrumando erros relatados noPR Arrumando margens das tabelas e dos headerspull/2513/head
committed by
ulysses
7 changed files with 417 additions and 2 deletions
@ -0,0 +1,30 @@ |
|||||
|
html body p { |
||||
|
border-top: 1px solid black; |
||||
|
text-align: center; |
||||
|
font-size: 11pt; |
||||
|
padding: 5px; |
||||
|
} |
||||
|
html body section { |
||||
|
box-sizing: border-box; |
||||
|
} |
||||
|
html body section dl { |
||||
|
display: flex; |
||||
|
flex-wrap: wrap; |
||||
|
rows: 2; |
||||
|
columns: 2; |
||||
|
} |
||||
|
html body section dt{ |
||||
|
width: 50px; |
||||
|
} |
||||
|
html body section dd { |
||||
|
max-width:550px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
html body section dd ul li { |
||||
|
list-style-type: none; |
||||
|
margin-left: 50px; |
||||
|
} |
||||
|
h3 { |
||||
|
font-size: 12pt; |
||||
|
color: #6e6e6e; |
||||
|
} |
||||
@ -0,0 +1,55 @@ |
|||||
|
@page{ |
||||
|
margin-top: 8cm; |
||||
|
size: A4 portrait; |
||||
|
} |
||||
|
|
||||
|
h2.gray-title{ |
||||
|
color: gray; |
||||
|
font-size: 14pt; |
||||
|
break-after: avoid-page; |
||||
|
page-break-after: avoid; |
||||
|
} |
||||
|
|
||||
|
h3 { |
||||
|
font-size: 10pt; |
||||
|
break-after: avoid-page; |
||||
|
page-break-after: avoid; |
||||
|
} |
||||
|
p { |
||||
|
font-size: 10pt; |
||||
|
} |
||||
|
table { |
||||
|
max-width: 520px; |
||||
|
} |
||||
|
table.grayTable { |
||||
|
border: 1px solid #6e6e6e; |
||||
|
width: 100%; |
||||
|
text-align: left; |
||||
|
border-collapse: collapse; |
||||
|
} |
||||
|
table.grayTable td, table.grayTable th { |
||||
|
border: 1px solid #000000; |
||||
|
} |
||||
|
table.grayTable tbody td { |
||||
|
font-size: 10px; |
||||
|
max-width: 80px; |
||||
|
overflow-wrap: break-word; |
||||
|
word-wrap: break-word; |
||||
|
text-align: justify; |
||||
|
} |
||||
|
table.grayTable tr:nth-child(even) { |
||||
|
background: #dddddd; |
||||
|
} |
||||
|
table.grayTable thead { |
||||
|
background: #BBBBBB; |
||||
|
border-bottom: 2px solid #000000; |
||||
|
} |
||||
|
table.grayTable thead th { |
||||
|
font-size:10px; |
||||
|
color: rgb(0, 0, 0); |
||||
|
border-left: 1px solid #000000; |
||||
|
|
||||
|
} |
||||
|
table.grayTable thead th:first-child { |
||||
|
border-left: none; |
||||
|
} |
||||
@ -0,0 +1,39 @@ |
|||||
|
{% load i18n staticfiles menus %} |
||||
|
{% load common_tags %} |
||||
|
{% load render_bundle from webpack_loader %} |
||||
|
{% load webpack_static from webpack_loader %} |
||||
|
{% load static %} |
||||
|
<!DOCTYPE html> |
||||
|
<meta charset="utf-8"> |
||||
|
</meta> |
||||
|
<html lang="pt-br"> |
||||
|
|
||||
|
<head> |
||||
|
<link rel="stylesheet" href="{% static '/css/header-relatorio.css' %}"> |
||||
|
</head> |
||||
|
|
||||
|
<body> |
||||
|
<section id="informations"> |
||||
|
|
||||
|
<dl> |
||||
|
<dt class="image-header"> |
||||
|
<img src="{% if logotipo %}{{ MEDIA_URL }}{{ logotipo }}{% else %}{% webpack_static 'img/logo.png' %}{% endif %}" |
||||
|
alt="Logo"> |
||||
|
</dt> |
||||
|
<dd class="title"> |
||||
|
<ul> |
||||
|
<li><h1>{{ info.nom_camara }}</h1></li> |
||||
|
<li><h3>Sistema de Apoio ao Processo Legislativo</h3></li> |
||||
|
</ul> |
||||
|
</dd> |
||||
|
</dl> |
||||
|
|
||||
|
|
||||
|
</section> |
||||
|
<p>Resumo da {{ info.num_sessao_plen }} Reunião {{nom_sessao}} da {{ info.num_sessao_leg}} Sessão Legislativa da |
||||
|
{{info.num_legislatura}} Legislatura</p> |
||||
|
|
||||
|
</body> |
||||
|
|
||||
|
|
||||
|
</html> |
||||
@ -0,0 +1,182 @@ |
|||||
|
{% load static %} |
||||
|
<!DOCTYPE html> |
||||
|
<meta charset="utf-8"> |
||||
|
</meta> |
||||
|
<html lang="pt-br"> |
||||
|
|
||||
|
<head> |
||||
|
<style> |
||||
|
@page{ |
||||
|
@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}}"; |
||||
|
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 '/css/relatorio.css' %}"> |
||||
|
</head> |
||||
|
|
||||
|
<body> |
||||
|
<div style="margin-bottom: 3cm"> |
||||
|
<h2 class="gray-title">Informações Básicas</h2> |
||||
|
<p><b>Tipo da Sessão:</b> {{inf_basicas_dic.nom_sessao}}</p> |
||||
|
<p><b>Abertura:</b> {{inf_basicas_dic.dat_inicio_sessao}} - {{inf_basicas_dic.hr_inicio_sessao}}</p> |
||||
|
<p><b>Encerramento:</b> {{inf_basicas_dic.dat_fim_sessao}} - {{inf_basicas_dic.hr_fim_sessao}}</p> |
||||
|
|
||||
|
<h2 class="gray-title">Mesa Diretora</h2> |
||||
|
{% for membro in lst_mesa%} |
||||
|
<p><b>{{membro.des_cargo}}:</b> {{membro.nom_parlamentar}}/{{membro.sgl_partido}}</p> |
||||
|
{% endfor%} |
||||
|
|
||||
|
<h2 class="gray-title">Lista de Presença da Sessão</h2> |
||||
|
{% for membro in lst_presenca_sessao%} |
||||
|
<p>{{membro.nom_parlamentar}}/{{membro.sgl_partido}}</p> |
||||
|
{% endfor%} |
||||
|
|
||||
|
<h2 class="gray-title">Justificativas de Ausência da Sessão</h2> |
||||
|
|
||||
|
<table class="grayTable"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Parlamentar</th> |
||||
|
<th>Justificativa</th> |
||||
|
<th>Ausente em</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
{% for ausencia in lst_ausencia_sessao%} |
||||
|
<tr> |
||||
|
<td>{{ausencia.parlamentar}}</td> |
||||
|
<td>{{ausencia.justificativa}}</td> |
||||
|
<td>{{ausencia.tipo}}</td> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
<h2 class="gray-title">Expedientes</h2> |
||||
|
{% for expediente in lst_expedientes%} |
||||
|
<h3>{{expediente.nom_expediente}}</h3> |
||||
|
<p style="margin-bottom: 1cm">{{expediente.txt_expediente|safe}}</p> |
||||
|
{% endfor%} |
||||
|
|
||||
|
|
||||
|
<h2 class="gray-title">Matérias do Expediente</h2> |
||||
|
|
||||
|
<table class="grayTable"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Matéria</th> |
||||
|
<th>Ementa</th> |
||||
|
<th>Resultado da Votação</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
{% for materia in lst_expediente_materia%} |
||||
|
<tr> |
||||
|
<td style="width:300px"> |
||||
|
<dl> |
||||
|
<dt><b>{{materia.num_ordem}} -</b> {{materia.id_materia}}</dt> |
||||
|
<dt><b>Turno:</b> {{materia.des_turno}}</dt> |
||||
|
<dt><b>{{materia.num_autores}}: </b>{{materia.nom_autor}}</dt> |
||||
|
</dl> |
||||
|
</td> |
||||
|
<td><div style="margin:10px">{{materia.txt_ementa}}</div></td> |
||||
|
<td style="width:10px"><b>{{materia.nom_resultado}}</b></td> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
<h2 class="gray-title">Oradores do Expediente</h2> |
||||
|
|
||||
|
{% for orador in lst_oradores_expediente%} |
||||
|
<tr> |
||||
|
<p> <b>{{orador.num_ordem}}</b> - {{orador.nom_parlamentar}}/{{orador.sgl_partido}}</p> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
|
||||
|
<h2 class="gray-title">Lista de Presença da Ordem do Dia</h2> |
||||
|
|
||||
|
{% for orador in lst_presenca_ordem_dia%} |
||||
|
<tr> |
||||
|
<p>{{orador.nom_parlamentar}}/{{orador.sgl_partido}}</p> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
|
||||
|
<h2 class="gray-title">Matérias da Ordem do Dia</h2> |
||||
|
|
||||
|
<table class="grayTable" style="height: 145px;" width="443"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<th>Matéria</th> |
||||
|
<th>Ementa</th> |
||||
|
<th>Resultado da Votação</th> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
<tbody> |
||||
|
{% for materia in lst_votacao%} |
||||
|
<tr> |
||||
|
<td style="width:300px"> |
||||
|
<dl> |
||||
|
<dt><b>{{materia.num_ordem}} -</b> {{materia.id_materia}}</dt> |
||||
|
<dt><b>Turno:</b> {{materia.des_turno}}</dt> |
||||
|
<dt><b>{{materia.num_autores}}: </b>{{materia.nom_autor}}</dt> |
||||
|
</dl> |
||||
|
</td> |
||||
|
<td><div style="margin:10px">{{materia.txt_ementa}}</div></td> |
||||
|
<td style="width:30px"><b>{{materia.nom_resultado}}</b></td> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
|
||||
|
</tbody> |
||||
|
</table> |
||||
|
|
||||
|
<div> |
||||
|
<h2 class="gray-title">Oradores das Explicações Pessoais</h2> |
||||
|
{% for orador in lst_oradores%} |
||||
|
<tr> |
||||
|
<p style="page-break-after: avoid;">{{orador.num_ordem}} - {{orador.nom_parlamentar}}/{{orador.sgl_partido}}</p> |
||||
|
</tr> |
||||
|
{% endfor %} |
||||
|
</div> |
||||
|
|
||||
|
|
||||
|
<h2 class="gray-title">Ocorrências da Sessão</h2> |
||||
|
{% for ocorrencia in lst_ocorrencias%} |
||||
|
<p>{{ocorrencia}}</p> |
||||
|
{% endfor %} |
||||
|
</div> |
||||
|
|
||||
|
</body> |
||||
|
|
||||
|
|
||||
|
</html> |
||||
Loading…
Reference in new issue