walace 2018-01-17 19:46:29 +00:00
parent c6790162bc
commit b2a8eb7ba4
4 changed files with 14 additions and 2 deletions

View File

@ -16,6 +16,7 @@ import org.apache.log4j.Logger;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.DataSource;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.RelatorioSegundaViaBean;
import com.rjconsultores.ventaboletos.utilerias.DateUtil;
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource;
@ -84,6 +85,7 @@ public class RelatorioSegundaVia extends Relatorio {
r.setDataViagem(rset.getDate("dataViagem"));
r.setDataServico(rset.getDate("dataServico"));
r.setDataSegundaVia(rset.getDate("dataSegundaVia"));
r.setHoraServico(DateUtil.getStringDate(rset.getDate("dataViagem"), "HH:mm"));
r.setDestino(rset.getString("destino"));
r.setOrigem(rset.getString("origem"));
r.setDescDestino(rset.getString("descDestino"));

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="RelatorioSegundaVia" pageWidth="1080" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="1070" leftMargin="5" rightMargin="5" topMargin="20" bottomMargin="20" uuid="0a7b3817-e201-4a91-8edd-6102b120e19f">
<property name="ireport.zoom" value="1.3636363636363662"/>
<property name="ireport.x" value="71"/>
<property name="ireport.x" value="232"/>
<property name="ireport.y" value="0"/>
<property name="net.sf.jasperreports.export.xls.exclude.origin.band.1" value="title"/>
<property name="net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.2" value="columnHeader"/>
@ -42,6 +42,7 @@
<field name="serieImpFiscalSegundaVia" class="java.lang.String"/>
<field name="utr" class="java.math.BigDecimal"/>
<field name="tpp" class="java.math.BigDecimal"/>
<field name="horaServico" class="java.lang.String"/>
<title>
<band height="109" splitType="Stretch">
<textField>
@ -396,7 +397,7 @@
<textElement>
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{dataViagem}]]></textFieldExpression>
<textFieldExpression><![CDATA[$F{horaServico}]]></textFieldExpression>
</textField>
<textField isStretchWithOverflow="true" isBlankWhenNull="true">
<reportElement stretchType="RelativeToTallestObject" x="525" y="0" width="64" height="29" uuid="a7c27960-ee5f-495c-9f26-40895de057d0"/>

View File

@ -37,6 +37,7 @@ public class RelatorioSegundaViaBean {
private BigDecimal valorTotal;
private String siglaTipoPassagem;
private String tipoPassagem;
private String horaServico;
public String getServico() {
return servico;
@ -294,4 +295,12 @@ public class RelatorioSegundaViaBean {
this.utr = utr;
}
public String getHoraServico() {
return horaServico;
}
public void setHoraServico(String horaServico) {
this.horaServico = horaServico;
}
}