fixes bug #6809
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@49822 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
9e27bff86b
commit
854a0aa9b9
|
@ -0,0 +1,160 @@
|
|||
package com.rjconsultores.ventaboletos.relatorios.impl;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.sql.Connection;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import com.rjconsultores.ventaboletos.entidad.Estado;
|
||||
import com.rjconsultores.ventaboletos.entidad.PuntoVenta;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.DataSource;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.DevolucaoBilhetes;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
|
||||
|
||||
import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource;
|
||||
|
||||
public class RelatorioDevolucaoBilhetes extends Relatorio {
|
||||
|
||||
public RelatorioDevolucaoBilhetes(Map<String, Object> parametros, Connection conexao) throws Exception {
|
||||
super(parametros, conexao);
|
||||
|
||||
this.setCustomDataSource(new DataSource(this) {
|
||||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public void initDados() throws Exception {
|
||||
|
||||
Connection conexao = this.relatorio.getConexao();
|
||||
Map<String, Object> parametros = this.relatorio.getParametros();
|
||||
|
||||
List<PuntoVenta> lsPuntoVenta = parametros.get("PUNTOVENTAS") == null ? new ArrayList<PuntoVenta>() : (ArrayList<PuntoVenta>) parametros.get("PUNTOVENTAS");
|
||||
List<Estado> lsEstado = parametros.get("ESTADOS") == null ? new ArrayList<Estado>() : (ArrayList<Estado>) parametros.get("ESTADOS");
|
||||
Integer empresaId = parametros.get("EMPRESA_ID") == null ? null : (Integer) parametros.get("EMPRESA_ID");
|
||||
|
||||
String puntoVentas = null;
|
||||
for (PuntoVenta pv : lsPuntoVenta) {
|
||||
if (lsPuntoVenta.indexOf(pv) == 0) {
|
||||
puntoVentas = "" + pv.getPuntoventaId();
|
||||
} else {
|
||||
puntoVentas += ", " + pv.getPuntoventaId();
|
||||
}
|
||||
}
|
||||
|
||||
String estados = null;
|
||||
for (Estado e : lsEstado) {
|
||||
if (lsEstado.indexOf(e) == 0) {
|
||||
estados = "" + e.getEstadoId();
|
||||
} else {
|
||||
estados += ", " + e.getEstadoId();
|
||||
}
|
||||
}
|
||||
|
||||
String sql = getSql(empresaId, puntoVentas, estados);
|
||||
NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql);
|
||||
ResultSet rset = null;
|
||||
|
||||
stmt.setTimestamp("DATA_INICIO", (Timestamp) parametros.get("DATA_INICIO"));
|
||||
stmt.setTimestamp("DATA_FINAL", (Timestamp) parametros.get("DATA_FINAL"));
|
||||
|
||||
rset = stmt.executeQuery();
|
||||
|
||||
List<DevolucaoBilhetes> lsDev = new ArrayList<DevolucaoBilhetes>();
|
||||
while (rset.next()) {
|
||||
|
||||
DevolucaoBilhetes db = new DevolucaoBilhetes();
|
||||
db.setEstado((String) rset.getObject("ESTADO"));
|
||||
db.setAidf((String) rset.getObject("AIDF"));
|
||||
db.setNumFolioSistema((String) rset.getObject("AIDF") == null ? (String) rset.getObject("NUMFOLIOSISTEMA") : (String) rset.getObject("AIDF"));
|
||||
db.setSerieSubSerie((String) rset.getObject("SERIE_SUBSERIE"));
|
||||
db.setFolio((String) rset.getObject("FOLIO"));
|
||||
db.setUf((String) rset.getObject("UF"));
|
||||
db.setFechorVenta((String) rset.getObject("FECHOR_VENTA"));
|
||||
db.setEstadoId(rset.getObject("ESTADO_ID") == null ? null : ((BigDecimal) rset.getObject("ESTADO_ID")).intValue());
|
||||
db.setIcms((BigDecimal) rset.getObject("ICMS"));
|
||||
db.setPrecioBase((BigDecimal) rset.getObject("PRECIOBASE"));
|
||||
db.setPrecioPagado((BigDecimal) rset.getObject("PRECIOPAGADO"));
|
||||
db.setEmpresaId(rset.getObject("EMPRESA_ID") == null ? null : ((BigDecimal) rset.getObject("EMPRESA_ID")).intValue());
|
||||
db.setEmpresa((String) rset.getObject("NOMB_EMPRESA"));
|
||||
|
||||
BigDecimal valorIcms = BigDecimal.ZERO;
|
||||
valorIcms = db.getPrecioPagado().multiply(db.getIcms().divide(BigDecimal.valueOf(100)));
|
||||
db.setValorIcms(valorIcms);
|
||||
|
||||
db.setPorcMunicipal(rset.getObject("PORC_MUNICIPAL") == null ? BigDecimal.ZERO : (BigDecimal) rset.getObject("PORC_MUNICIPAL"));
|
||||
db.setPorcEstadual(rset.getObject("PORC_ESTADUAL") == null ? BigDecimal.ZERO : (BigDecimal) rset.getObject("PORC_ESTADUAL"));
|
||||
|
||||
boolean isEstadual = ((BigDecimal) rset.getObject("IS_ESTADUAL")).equals(BigDecimal.ZERO) ? false : true;
|
||||
|
||||
BigDecimal estornoMunicipal = BigDecimal.ZERO;
|
||||
BigDecimal estornoEstadual = BigDecimal.ZERO;
|
||||
if (isEstadual) {
|
||||
estornoEstadual = valorIcms.multiply(db.getPorcEstadual().divide(BigDecimal.valueOf(100)));
|
||||
} else {
|
||||
estornoMunicipal = valorIcms.multiply(db.getPorcMunicipal().divide(BigDecimal.valueOf(100)));
|
||||
}
|
||||
db.setEstornoMunicipal(estornoMunicipal);
|
||||
db.setEstornoEstadual(estornoEstadual);
|
||||
|
||||
lsDev.add(db);
|
||||
}
|
||||
|
||||
setLsDadosRelatorio(lsDev);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
public void setLsDadosRelatorio(List<DevolucaoBilhetes> lsDev) {
|
||||
this.setCollectionDataSource(new JRBeanCollectionDataSource(lsDev));
|
||||
}
|
||||
|
||||
private String getSql(Integer empresaId, String puntoVentas, String estados) {
|
||||
|
||||
StringBuilder sql = new StringBuilder();
|
||||
sql.append("SELECT AIDF.ACFISCAL AS AIDF, ");
|
||||
sql.append(" COALESCE(CAJ.NUMFOLIOSISTEMA, NUMOPERACION) AS NUMFOLIOSISTEMA, ");
|
||||
sql.append(" CAJ.NUMSERIEPREIMPRESA AS SERIE_SUBSERIE, ");
|
||||
sql.append(" CAJ.NUMFOLIOPREIMPRESO AS FOLIO, ");
|
||||
sql.append(" CAJ.PRECIOPAGADO AS PRECIOPAGADO, ");
|
||||
sql.append(" CAJ.PRECIOBASE AS PRECIOBASE, ");
|
||||
sql.append(" E.NOMBEMPRESA AS NOMB_EMPRESA, ");
|
||||
sql.append(" E.EMPRESA_ID AS EMPRESA_ID, ");
|
||||
sql.append(" EST.ESTADO_ID AS ESTADO_ID, ");
|
||||
sql.append(" EST.NOMBESTADO AS ESTADO, ");
|
||||
sql.append(" EST.CVEESTADO AS UF, ");
|
||||
sql.append(" EST.ICMS AS ICMS, ");
|
||||
sql.append(" TO_CHAR(CAJ.FECHORVENTA, 'DD/MM/YYYY') AS FECHOR_VENTA, ");
|
||||
sql.append(" CASE WHEN CO.ESTADO_ID <> CD.ESTADO_ID THEN 1 ELSE 0 END IS_ESTADUAL, ");
|
||||
sql.append(" EI.PORCREDMUNICIPAL AS PORC_MUNICIPAL, ");
|
||||
sql.append(" EI.PORCREDESTADUAL AS PORC_ESTADUAL ");
|
||||
sql.append("FROM CAJA CAJ ");
|
||||
sql.append("INNER JOIN EMPRESA E ON E.EMPRESA_ID = CAJ.MARCA_ID ");
|
||||
sql.append("INNER JOIN PUNTO_VENTA PTV ON PTV.PUNTOVENTA_ID = CAJ.PUNTOVENTA_ID ");
|
||||
sql.append("INNER JOIN PARADA ORIGEM ON (CAJ.ORIGEN_ID = ORIGEM.PARADA_ID ) ");
|
||||
sql.append("INNER JOIN PARADA DESTINO ON (CAJ.DESTINO_ID = DESTINO.PARADA_ID ) ");
|
||||
sql.append("INNER JOIN CIUDAD CO ON (CO.CIUDAD_ID = ORIGEM.CIUDAD_ID ) ");
|
||||
sql.append("INNER JOIN CIUDAD CD ON (CD.CIUDAD_ID = DESTINO.CIUDAD_ID ) ");
|
||||
sql.append("INNER JOIN ESTADO EST ON EST.ESTADO_ID = CO.ESTADO_ID ");
|
||||
sql.append("LEFT JOIN EMPRESA_IMPOSTO EI ON EST.ESTADO_ID = EI.ESTADO_ID AND EI.EMPRESA_ID = CAJ.MARCA_ID ");
|
||||
sql.append("LEFT JOIN AIDF AIDF ON ((AIDF.SERIE = CAJ.NUMSERIEPREIMPRESA OR ");
|
||||
sql.append(" AIDF.SERIE = SUBSTR(CAJ.NUMSERIEPREIMPRESA,1,INSTR(CAJ.NUMSERIEPREIMPRESA,'-',1)-1)) ");
|
||||
sql.append(" AND (CAJ.NUMFOLIOPREIMPRESO BETWEEN AIDF.FORMINICIAL AND AIDF.FORMFINAL)) ");
|
||||
sql.append("WHERE CAJ.MOTIVOCANCELACION_ID IN (32) ");
|
||||
sql.append("AND CAJ.FECHORVENTA BETWEEN :DATA_INICIO AND :DATA_FINAL ");
|
||||
sql.append("AND CAJ.CATEGORIA_ID NOT IN (SELECT VALORCONSTANTE FROM CONSTANTE WHERE NOMBCONSTANTE = 'GRATUIDADE_CRIANCA') ");
|
||||
sql.append(estados == null ? "" : "AND EST.ESTADO_ID IN (" + estados + ") ");
|
||||
sql.append(puntoVentas == null ? "" : "AND PTV.PUNTOVENTA_ID IN (" + puntoVentas + ") ");
|
||||
sql.append(empresaId == null ? "" : "AND CAJ.MARCA_ID IN (" + empresaId + ") ");
|
||||
sql.append("ORDER BY NOMB_EMPRESA, ESTADO, FECHOR_VENTA ");
|
||||
|
||||
return sql.toString();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void processaParametros() throws Exception {
|
||||
}
|
||||
|
||||
}
|
Binary file not shown.
|
@ -1,6 +1,6 @@
|
|||
<?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="RelatorioDevolucaoBilhetes" pageWidth="595" pageHeight="842" whenNoDataType="NoDataSection" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="efbc89d4-6f08-4ea5-802f-d4f48ed208e2">
|
||||
<property name="ireport.zoom" value="2.0"/>
|
||||
<property name="ireport.zoom" value="1.6528925619834718"/>
|
||||
<property name="ireport.x" value="0"/>
|
||||
<property name="ireport.y" value="0"/>
|
||||
<style name="textStyle" isDefault="true" fontSize="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false"/>
|
||||
|
@ -24,7 +24,7 @@
|
|||
<pen lineWidth="0.5" lineColor="#000000"/>
|
||||
</box>
|
||||
</style>
|
||||
<parameter name="DATA_INICIAL" class="java.util.Date"/>
|
||||
<parameter name="DATA_INICIO" class="java.util.Date"/>
|
||||
<parameter name="DATA_FINAL" class="java.util.Date"/>
|
||||
<parameter name="EMPRESA" class="java.lang.String"/>
|
||||
<parameter name="NOME_RELATORIO" class="java.lang.String"/>
|
||||
|
@ -35,93 +35,217 @@
|
|||
<queryString>
|
||||
<![CDATA[]]>
|
||||
</queryString>
|
||||
<group name="grpEmpresa">
|
||||
<groupExpression><![CDATA[$F{NOMBEMPRESA}]]></groupExpression>
|
||||
<field name="aidf" class="java.lang.String"/>
|
||||
<field name="numFolioSistema" class="java.lang.String"/>
|
||||
<field name="serieSubSerie" class="java.lang.String"/>
|
||||
<field name="folio" class="java.lang.String"/>
|
||||
<field name="precioPagado" class="java.math.BigDecimal"/>
|
||||
<field name="precioBase" class="java.math.BigDecimal"/>
|
||||
<field name="estadoId" class="java.lang.Integer"/>
|
||||
<field name="estado" class="java.lang.String"/>
|
||||
<field name="uf" class="java.lang.String"/>
|
||||
<field name="fechorVenta" class="java.lang.String"/>
|
||||
<field name="icms" class="java.math.BigDecimal"/>
|
||||
<field name="valorIcms" class="java.math.BigDecimal"/>
|
||||
<field name="empresaId" class="java.lang.Integer"/>
|
||||
<field name="empresa" class="java.lang.String"/>
|
||||
<field name="porcMunicipal" class="java.math.BigDecimal"/>
|
||||
<field name="porcEstadual" class="java.math.BigDecimal"/>
|
||||
<field name="estornoMunicipal" class="java.math.BigDecimal"/>
|
||||
<field name="estornoEstadual" class="java.math.BigDecimal"/>
|
||||
<variable name="precioPagado_1" class="java.math.BigDecimal" resetType="Group" resetGroup="data_group" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{precioPagado}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="valorIcms_1" class="java.math.BigDecimal" resetType="Group" resetGroup="data_group" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{valorIcms}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="folio_1" class="java.lang.Integer" calculation="Count">
|
||||
<variableExpression><![CDATA[$F{folio}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="precioPagado_total" class="java.math.BigDecimal" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{precioPagado}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="valorIcms_total" class="java.math.BigDecimal" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{valorIcms}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="estornoMunicipal_1" class="java.math.BigDecimal" resetType="Group" resetGroup="estado_empresa" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{estornoMunicipal}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="estornoEstadual_1" class="java.math.BigDecimal" resetType="Group" resetGroup="estado_empresa" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{estornoEstadual}]]></variableExpression>
|
||||
</variable>
|
||||
<variable name="somaEstorno" class="java.math.BigDecimal" resetType="Group" resetGroup="estado_empresa" calculation="Sum">
|
||||
<variableExpression><![CDATA[$F{estornoEstadual}.add($F{estornoMunicipal})]]></variableExpression>
|
||||
</variable>
|
||||
<group name="empresa">
|
||||
<groupExpression><![CDATA[$F{empresaId}]]></groupExpression>
|
||||
<groupHeader>
|
||||
<band height="14">
|
||||
<band height="15">
|
||||
<textField>
|
||||
<reportElement uuid="95e0028f-60d8-4bbf-afea-a2f3d40b2deb" x="0" y="0" width="187" height="14"/>
|
||||
<textElement verticalAlignment="Middle">
|
||||
<font size="8" isBold="true"/>
|
||||
<reportElement x="2" y="0" width="138" height="14" uuid="3055dd3d-ea00-4d23-9a0d-7b86d4b4979f"/>
|
||||
<textElement>
|
||||
<font size="9" isBold="true"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Empresa: "+$F{NOMBEMPRESA}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA[$F{empresa}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</groupHeader>
|
||||
</group>
|
||||
<group name="estado_empresa">
|
||||
<groupExpression><![CDATA[$F{estadoId}]]></groupExpression>
|
||||
<groupHeader>
|
||||
<band height="15">
|
||||
<textField>
|
||||
<reportElement x="2" y="0" width="138" height="14" uuid="c15cca63-a37a-4709-9895-3357287ba7c4"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{estado}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</groupHeader>
|
||||
<groupFooter>
|
||||
<band height="11">
|
||||
<staticText>
|
||||
<reportElement uuid="2a963103-78f6-46c6-ac37-29ed4654df56" x="0" y="0" width="51" height="11"/>
|
||||
<textElement/>
|
||||
<text><![CDATA[Total Empresa: ]]></text>
|
||||
</staticText>
|
||||
<textField pattern="#,##0.00">
|
||||
<reportElement uuid="0617c1e5-cd2f-4b67-ba79-d68c6604275e" x="354" y="0" width="64" height="11"/>
|
||||
<textElement textAlignment="Right"/>
|
||||
<textFieldExpression><![CDATA[$V{TOTAL_EMBARQUE_1}]]></textFieldExpression>
|
||||
<band height="52">
|
||||
<textField>
|
||||
<reportElement x="2" y="1" width="271" height="17" uuid="0244fe68-ad89-44e9-a002-ae0a861f51c9"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Imposto a Estornar Interestadual (" + $F{porcEstadual} + " % )"]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement uuid="7fc66df3-edd7-4149-847e-1375a3621e80" x="0" y="10" width="554" height="1" forecolor="#666666"/>
|
||||
<graphicElement>
|
||||
<pen lineWidth="0.5"/>
|
||||
</graphicElement>
|
||||
<reportElement x="2" y="0" width="553" height="1" uuid="9f5bfcdb-8a1f-45b5-bf7c-76fe28f72e9f"/>
|
||||
</line>
|
||||
<textField>
|
||||
<reportElement x="2" y="18" width="271" height="17" uuid="5726d4b8-da32-4b50-8531-3c31285e03d6"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Imposto a Estornar Interestadual (" + $F{porcMunicipal} + " % )"]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="461" y="18" width="72" height="17" uuid="cf8b4127-af83-4ef1-9913-fbd00f0ffe35"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{estornoMunicipal_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="461" y="1" width="72" height="17" uuid="c9cec4e3-dd36-4806-b32f-010b4f2c4705"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{estornoEstadual_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="461" y="35" width="72" height="16" uuid="693122b4-eb19-463d-8061-76a4b58b458f"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{somaEstorno}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</groupFooter>
|
||||
</group>
|
||||
<group name="data_group">
|
||||
<groupExpression><![CDATA[$F{fechorVenta}]]></groupExpression>
|
||||
<groupHeader>
|
||||
<band height="17">
|
||||
<textField>
|
||||
<reportElement x="1" y="0" width="100" height="15" uuid="c92216da-0d77-4711-94a4-b8b2d00465a3"/>
|
||||
<textElement>
|
||||
<font size="9" isBold="false"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{fechorVenta}]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement uuid="c4a77336-68c6-4e8e-8cd0-ee9c5cdcea51" x="0" y="0" width="554" height="1" forecolor="#666666"/>
|
||||
<graphicElement>
|
||||
<pen lineWidth="0.5"/>
|
||||
</graphicElement>
|
||||
<reportElement x="1" y="15" width="553" height="1" uuid="fc2f690d-3659-4d11-a671-9c004341d03d"/>
|
||||
</line>
|
||||
</band>
|
||||
</groupHeader>
|
||||
<groupFooter>
|
||||
<band height="15">
|
||||
<textField pattern="###0.00" isBlankWhenNull="true">
|
||||
<reportElement x="343" y="0" width="60" height="14" uuid="67bdceb4-d6ed-42c5-871f-d809ffec832b"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{precioPagado_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00" isBlankWhenNull="true">
|
||||
<reportElement x="273" y="0" width="70" height="14" uuid="943bc881-8248-4da5-999a-62b2f67a573a"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{precioPagado_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement x="1" y="0" width="554" height="1" uuid="eb29c074-35dc-47d8-855b-78b95676b7ae"/>
|
||||
</line>
|
||||
<textField pattern="###0.00" isBlankWhenNull="true">
|
||||
<reportElement x="461" y="1" width="72" height="13" uuid="6e65196e-b844-4c3d-9697-44aadad52344"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{valorIcms_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="1" y="1" width="139" height="13" uuid="bbb5fed7-d553-42f3-9d90-4e548e0b7b38"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Subtotal - " + $F{fechorVenta}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</groupFooter>
|
||||
</group>
|
||||
<background>
|
||||
<band splitType="Stretch"/>
|
||||
</background>
|
||||
<pageHeader>
|
||||
<band height="59" splitType="Stretch">
|
||||
<band height="62" splitType="Stretch">
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="2ed4524d-5c06-487c-a8f1-abc59a8ef7fc" mode="Transparent" x="1" y="1" width="257" height="15" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<reportElement mode="Transparent" x="1" y="1" width="257" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="2ed4524d-5c06-487c-a8f1-abc59a8ef7fc"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$P{NOME_RELATORIO}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="fc199edd-4f2f-4b5f-9397-44f4af50a920" mode="Transparent" x="1" y="16" width="44" height="14" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textField>
|
||||
<reportElement mode="Transparent" x="461" y="16" width="93" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="1e340cae-0c0a-48a3-b2b8-6667a44078af"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Página: " + $V{PAGE_COUNT}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="45" y="30" width="51" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="f64c2e3c-d936-4072-a0b1-d914f408bbbb"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.periodo}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA[$P{DATA_INICIO}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy" isBlankWhenNull="false">
|
||||
<reportElement uuid="f64c2e3c-d936-4072-a0b1-d914f408bbbb" mode="Transparent" x="46" y="16" width="51" height="14" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$P{DATA_INICIAL}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy" isBlankWhenNull="false">
|
||||
<reportElement uuid="00093c35-d3a5-4b0e-8a7a-26a86912dd25" mode="Transparent" x="107" y="16" width="51" height="14" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<reportElement mode="Transparent" x="124" y="30" width="63" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="00093c35-d3a5-4b0e-8a7a-26a86912dd25"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$P{DATA_FINAL}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="def1b81c-a286-4749-9ef7-f90984a3a5eb" mode="Transparent" x="97" y="16" width="10" height="14" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textField>
|
||||
<reportElement mode="Transparent" x="96" y="30" width="28" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="98d664b7-8e13-408c-bf89-70bf11c87a60"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.periodoA}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA["até"]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy HH:mm" isBlankWhenNull="false">
|
||||
<reportElement uuid="ea4dfc22-27b5-4600-8e8b-7d74460ed744" mode="Transparent" x="461" y="0" width="89" height="15" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<reportElement mode="Transparent" x="461" y="0" width="93" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="ea4dfc22-27b5-4600-8e8b-7d74460ed744"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
|
@ -129,159 +253,213 @@
|
|||
<textFieldExpression><![CDATA[new java.util.Date()]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement uuid="d9b398e6-2fe9-4a3d-bceb-f9db7a06e5a9" x="1" y="43" width="554" height="1"/>
|
||||
<reportElement x="1" y="45" width="553" height="1" uuid="d9b398e6-2fe9-4a3d-bceb-f9db7a06e5a9"/>
|
||||
</line>
|
||||
<textField>
|
||||
<reportElement uuid="a46c91f5-fb60-48d8-93c1-3814ce0160dd" x="379" y="0" width="80" height="15"/>
|
||||
<textElement textAlignment="Right">
|
||||
<font size="9" isBold="true"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.dataHora}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="623b5d82-e7b3-4439-96c5-f44833fb8864" mode="Transparent" x="450" y="31" width="100" height="12" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="7" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.impressorPor}+" "+$P{USUARIO}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="ccec8b66-ed79-418b-b66d-15d9ed3bf2ce" mode="Transparent" x="1" y="44" width="45" height="14" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<reportElement mode="Transparent" x="1" y="46" width="43" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="11b7c338-166a-4149-b45c-b47698bd88ea"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Middle" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.filtros}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA["Filtros "]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement uuid="98fc1c7e-3fee-4c70-924f-2cbb17fd243f" x="47" y="44" width="508" height="14"/>
|
||||
<reportElement x="46" y="46" width="508" height="14" uuid="98fc1c7e-3fee-4c70-924f-2cbb17fd243f"/>
|
||||
<textElement verticalAlignment="Middle">
|
||||
<font size="8"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$P{FILTROS}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="6aae4c9b-2e2a-4fd5-9115-760449d3c263" mode="Transparent" x="430" y="16" width="105" height="15" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<textField>
|
||||
<reportElement mode="Transparent" x="2" y="30" width="42" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="7f1538d0-be50-4597-bfce-dfc18da5c67a"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.pagina}+" "+$V{PAGE_NUMBER}+" "+$R{cabecalho.de}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField evaluationTime="Report" pattern="" isBlankWhenNull="false">
|
||||
<reportElement uuid="5a57c3a1-ed8e-46fb-836f-d250116a238a" mode="Transparent" x="535" y="16" width="15" height="15" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="9" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA["Período "]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</pageHeader>
|
||||
<columnHeader>
|
||||
<band height="13">
|
||||
<band height="16">
|
||||
<line>
|
||||
<reportElement uuid="04a75f17-3686-484b-be43-7b7e22e9def7" x="0" y="0" width="554" height="1"/>
|
||||
<reportElement x="0" y="0" width="554" height="1" uuid="04a75f17-3686-484b-be43-7b7e22e9def7"/>
|
||||
<graphicElement>
|
||||
<pen lineWidth="0.5"/>
|
||||
</graphicElement>
|
||||
</line>
|
||||
<line>
|
||||
<reportElement uuid="d9f712d0-01a8-4241-a1e6-dc096b4ee773" x="0" y="12" width="554" height="1"/>
|
||||
<reportElement x="0" y="15" width="555" height="1" uuid="d9f712d0-01a8-4241-a1e6-dc096b4ee773"/>
|
||||
<graphicElement>
|
||||
<pen lineWidth="0.5"/>
|
||||
</graphicElement>
|
||||
</line>
|
||||
<staticText>
|
||||
<reportElement uuid="9c579f27-ee14-4804-b73d-64994a6e41ec" x="0" y="1" width="129" height="11"/>
|
||||
<reportElement x="0" y="1" width="140" height="14" uuid="9c579f27-ee14-4804-b73d-64994a6e41ec"/>
|
||||
<textElement>
|
||||
<font size="7"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[AIDF]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="7b8a8f38-e513-4a8c-a82b-a9c6ffd21f6f" x="129" y="1" width="55" height="11"/>
|
||||
<reportElement x="140" y="1" width="74" height="14" uuid="7b8a8f38-e513-4a8c-a82b-a9c6ffd21f6f"/>
|
||||
<textElement>
|
||||
<font size="7"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Série/Subs.]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="4f8fcbb3-73e7-4b15-9687-30ff12bb1526" x="184" y="1" width="55" height="11"/>
|
||||
<reportElement x="214" y="1" width="59" height="14" uuid="4f8fcbb3-73e7-4b15-9687-30ff12bb1526"/>
|
||||
<textElement>
|
||||
<font size="7"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Número]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="7b817589-f754-49f1-bf53-856be52946fb" mode="Transparent" x="290" y="1" width="47" height="11" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="7" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<reportElement mode="Transparent" x="343" y="1" width="60" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="7b817589-f754-49f1-bf53-856be52946fb"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Base Calc.]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="93a5880a-7547-4e53-85f4-09a6c22d5699" mode="Transparent" x="337" y="1" width="32" height="11" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="7" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<reportElement mode="Transparent" x="403" y="1" width="58" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="93a5880a-7547-4e53-85f4-09a6c22d5699"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Alíquota]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="1d4f5650-a014-468d-a9b2-c58887492ace" mode="Transparent" x="369" y="1" width="32" height="11" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="7" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<reportElement mode="Transparent" x="461" y="1" width="72" height="14" forecolor="#000000" backcolor="#FFFFFF" uuid="1d4f5650-a014-468d-a9b2-c58887492ace"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="10" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<text><![CDATA[ICMS]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="9b724ccc-0e90-4271-9e51-54128161d074" mode="Transparent" x="401" y="1" width="63" height="11" forecolor="#000000" backcolor="#FFFFFF"/>
|
||||
<textElement textAlignment="Right" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="7" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Isentas]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement uuid="32c20a27-414c-41be-86b2-0d23645acd18" x="239" y="1" width="51" height="11"/>
|
||||
<reportElement x="273" y="1" width="70" height="14" uuid="32c20a27-414c-41be-86b2-0d23645acd18"/>
|
||||
<textElement>
|
||||
<font size="7"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Vr. Contábil]]></text>
|
||||
</staticText>
|
||||
</band>
|
||||
</columnHeader>
|
||||
<detail>
|
||||
<band height="11"/>
|
||||
<band height="14">
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="0" y="0" width="140" height="14" uuid="a34502fa-62b7-44b6-9218-90034054b7ac"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{numFolioSistema}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="140" y="0" width="74" height="14" uuid="73fc6712-d370-49e2-ac39-55e2fa5ce9e2"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{serieSubSerie}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern=" ###0.00">
|
||||
<reportElement x="273" y="0" width="70" height="14" uuid="b14dbaab-e9a1-4aae-a12c-6305da9d2f80"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{precioPagado}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="403" y="0" width="58" height="14" uuid="3285bf53-66f1-4dc2-b3db-d12875efa546"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{icms}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="343" y="0" width="60" height="14" uuid="6772d6a9-3611-4cb6-9c3b-f78dc3fb5dc0"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{precioPagado}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern=" ###0.00" isBlankWhenNull="true">
|
||||
<reportElement x="461" y="0" width="72" height="14" uuid="e948b0e2-03c4-47c9-91f1-90d3a3fc4bf4"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{valorIcms}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="214" y="0" width="59" height="14" uuid="755796e0-1c3a-470a-a226-35e01d006653"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{folio}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</detail>
|
||||
<lastPageFooter>
|
||||
<band height="11">
|
||||
<textField evaluationTime="Auto" pattern="#,##0.00">
|
||||
<reportElement uuid="1d265368-d216-4cec-a824-a0c0b5536a43" x="355" y="-1" width="63" height="12"/>
|
||||
<textElement textAlignment="Right"/>
|
||||
<textFieldExpression><![CDATA[$V{TOTAL_EMBARQUE_2}]]></textFieldExpression>
|
||||
</textField>
|
||||
<staticText>
|
||||
<reportElement uuid="f7ac3bf7-ac60-405e-b2a3-60c9150421a0" x="0" y="0" width="51" height="11"/>
|
||||
<textElement/>
|
||||
<text><![CDATA[Total Geral: ]]></text>
|
||||
</staticText>
|
||||
<line>
|
||||
<reportElement uuid="06fb8df2-dbea-44e7-9e45-21f8aa82f939" x="0" y="10" width="554" height="1" forecolor="#666666"/>
|
||||
<graphicElement>
|
||||
<pen lineWidth="0.5"/>
|
||||
</graphicElement>
|
||||
</line>
|
||||
</band>
|
||||
<band/>
|
||||
</lastPageFooter>
|
||||
<noData>
|
||||
<band height="39">
|
||||
<summary>
|
||||
<band height="17">
|
||||
<textField>
|
||||
<reportElement uuid="a640c0eb-ead8-4a2a-bda4-675165e8bc7d" x="148" y="8" width="407" height="20"/>
|
||||
<reportElement x="1" y="1" width="44" height="14" uuid="c57012f1-edf2-4505-86c8-693c38a8a0cf"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Total"]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement x="0" y="0" width="555" height="1" uuid="c2a4d216-ecbf-4690-876b-3263188595ad"/>
|
||||
</line>
|
||||
<textField>
|
||||
<reportElement x="242" y="1" width="31" height="14" uuid="0dcac787-43f7-4e9f-84c8-06567671ddb7"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{folio_1}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="140" y="1" width="102" height="14" uuid="fba1bd88-a15f-4d9f-93fb-9abbfaa5429e"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA["Quantidade de Bilhetes :"]]></textFieldExpression>
|
||||
</textField>
|
||||
<line>
|
||||
<reportElement x="1" y="15" width="554" height="1" uuid="ff50b0f9-831b-428e-9177-b264920c542b"/>
|
||||
</line>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="273" y="1" width="70" height="14" uuid="5bb73e4d-a51b-4a04-bed0-8fa3eb7f8553"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{precioPagado_total}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="343" y="1" width="60" height="14" uuid="7c3ce565-f549-48d2-815d-9b4d7a39b1ca"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{precioPagado_total}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="###0.00">
|
||||
<reportElement x="461" y="1" width="72" height="14" uuid="7a2dbe9b-868e-46db-b3b3-6e759d4dba98"/>
|
||||
<textElement>
|
||||
<font size="9"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$V{valorIcms_total}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</summary>
|
||||
<noData>
|
||||
<band height="22">
|
||||
<textField>
|
||||
<reportElement x="97" y="0" width="407" height="20" uuid="a640c0eb-ead8-4a2a-bda4-675165e8bc7d"/>
|
||||
<textElement markup="none">
|
||||
<font size="11" isBold="true"/>
|
||||
</textElement>
|
||||
|
|
|
@ -0,0 +1,171 @@
|
|||
package com.rjconsultores.ventaboletos.relatorios.utilitarios;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
public class DevolucaoBilhetes {
|
||||
|
||||
private String aidf;
|
||||
private String numFolioSistema;
|
||||
private String serieSubSerie;
|
||||
private String folio;
|
||||
private BigDecimal precioPagado;
|
||||
private BigDecimal precioBase;
|
||||
private String empresa;
|
||||
private Integer empresaId;
|
||||
private Integer estadoId;
|
||||
private String estado;
|
||||
private String uf;
|
||||
private BigDecimal icms;
|
||||
private BigDecimal valorIcms;
|
||||
private String fechorVenta;
|
||||
|
||||
BigDecimal porcMunicipal;
|
||||
BigDecimal porcEstadual;
|
||||
BigDecimal estornoMunicipal;
|
||||
BigDecimal estornoEstadual;
|
||||
|
||||
public String getAidf() {
|
||||
return aidf;
|
||||
}
|
||||
|
||||
public void setAidf(String aidf) {
|
||||
this.aidf = aidf;
|
||||
}
|
||||
|
||||
public String getNumFolioSistema() {
|
||||
return numFolioSistema;
|
||||
}
|
||||
|
||||
public void setNumFolioSistema(String numFolioSistema) {
|
||||
this.numFolioSistema = numFolioSistema;
|
||||
}
|
||||
|
||||
public String getSerieSubSerie() {
|
||||
return serieSubSerie;
|
||||
}
|
||||
|
||||
public void setSerieSubSerie(String serieSubSerie) {
|
||||
this.serieSubSerie = serieSubSerie;
|
||||
}
|
||||
|
||||
public String getFolio() {
|
||||
return folio;
|
||||
}
|
||||
|
||||
public void setFolio(String folio) {
|
||||
this.folio = folio;
|
||||
}
|
||||
|
||||
public BigDecimal getPrecioPagado() {
|
||||
return precioPagado;
|
||||
}
|
||||
|
||||
public void setPrecioPagado(BigDecimal precioPagado) {
|
||||
this.precioPagado = precioPagado;
|
||||
}
|
||||
|
||||
public BigDecimal getPrecioBase() {
|
||||
return precioBase;
|
||||
}
|
||||
|
||||
public void setPrecioBase(BigDecimal precioBase) {
|
||||
this.precioBase = precioBase;
|
||||
}
|
||||
|
||||
public Integer getEstadoId() {
|
||||
return estadoId;
|
||||
}
|
||||
|
||||
public void setEstadoId(Integer estadoId) {
|
||||
this.estadoId = estadoId;
|
||||
}
|
||||
|
||||
public String getEstado() {
|
||||
return estado;
|
||||
}
|
||||
|
||||
public void setEstado(String estado) {
|
||||
this.estado = estado;
|
||||
}
|
||||
|
||||
public String getUf() {
|
||||
return uf;
|
||||
}
|
||||
|
||||
public void setUf(String uf) {
|
||||
this.uf = uf;
|
||||
}
|
||||
|
||||
public BigDecimal getIcms() {
|
||||
return icms;
|
||||
}
|
||||
|
||||
public void setIcms(BigDecimal icms) {
|
||||
this.icms = icms;
|
||||
}
|
||||
|
||||
public String getFechorVenta() {
|
||||
return fechorVenta;
|
||||
}
|
||||
|
||||
public void setFechorVenta(String fechorVenta) {
|
||||
this.fechorVenta = fechorVenta;
|
||||
}
|
||||
|
||||
public BigDecimal getValorIcms() {
|
||||
return valorIcms;
|
||||
}
|
||||
|
||||
public void setValorIcms(BigDecimal valorIcms) {
|
||||
this.valorIcms = valorIcms;
|
||||
}
|
||||
|
||||
public BigDecimal getPorcMunicipal() {
|
||||
return porcMunicipal;
|
||||
}
|
||||
|
||||
public void setPorcMunicipal(BigDecimal porcMunicipal) {
|
||||
this.porcMunicipal = porcMunicipal;
|
||||
}
|
||||
|
||||
public BigDecimal getPorcEstadual() {
|
||||
return porcEstadual;
|
||||
}
|
||||
|
||||
public void setPorcEstadual(BigDecimal porcEstadual) {
|
||||
this.porcEstadual = porcEstadual;
|
||||
}
|
||||
|
||||
public BigDecimal getEstornoMunicipal() {
|
||||
return estornoMunicipal;
|
||||
}
|
||||
|
||||
public void setEstornoMunicipal(BigDecimal estornoMunicipal) {
|
||||
this.estornoMunicipal = estornoMunicipal;
|
||||
}
|
||||
|
||||
public BigDecimal getEstornoEstadual() {
|
||||
return estornoEstadual;
|
||||
}
|
||||
|
||||
public void setEstornoEstadual(BigDecimal estornoEstadual) {
|
||||
this.estornoEstadual = estornoEstadual;
|
||||
}
|
||||
|
||||
public Integer getEmpresaId() {
|
||||
return empresaId;
|
||||
}
|
||||
|
||||
public void setEmpresaId(Integer empresaId) {
|
||||
this.empresaId = empresaId;
|
||||
}
|
||||
|
||||
public String getEmpresa() {
|
||||
return empresa;
|
||||
}
|
||||
|
||||
public void setEmpresa(String empresa) {
|
||||
this.empresa = empresa;
|
||||
}
|
||||
|
||||
}
|
|
@ -4,8 +4,8 @@
|
|||
*/
|
||||
package com.rjconsultores.ventaboletos.web.gui.controladores.relatorios;
|
||||
|
||||
import java.sql.Timestamp;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
@ -20,24 +20,20 @@ import org.zkoss.zhtml.Messagebox;
|
|||
import org.zkoss.zk.ui.Component;
|
||||
import org.zkoss.zk.ui.event.Event;
|
||||
import org.zkoss.zul.Bandbox;
|
||||
import org.zkoss.zul.Checkbox;
|
||||
import org.zkoss.zul.Combobox;
|
||||
import org.zkoss.zul.Comboitem;
|
||||
import org.zkoss.zul.Datebox;
|
||||
import org.zkoss.zul.Paging;
|
||||
import org.zkoss.zul.Radio;
|
||||
import org.zkoss.zul.Textbox;
|
||||
|
||||
import com.rjconsultores.ventaboletos.entidad.Empresa;
|
||||
import com.rjconsultores.ventaboletos.entidad.Estado;
|
||||
import com.rjconsultores.ventaboletos.entidad.PuntoVenta;
|
||||
import com.rjconsultores.ventaboletos.entidad.TipoPuntoVenta;
|
||||
import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioReceitaDiariaAgencia;
|
||||
import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioDevolucaoBilhetes;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.service.EmpresaService;
|
||||
import com.rjconsultores.ventaboletos.service.EstadoService;
|
||||
import com.rjconsultores.ventaboletos.service.PuntoVentaService;
|
||||
import com.rjconsultores.ventaboletos.service.TipoPuntoVentaService;
|
||||
import com.rjconsultores.ventaboletos.utilerias.DateUtil;
|
||||
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.MyGenericForwardComposer;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.MyListbox;
|
||||
|
@ -55,44 +51,143 @@ import com.trg.search.Filter;
|
|||
@Scope("prototype")
|
||||
public class RelatorioDevolucaoBilhetesController extends MyGenericForwardComposer {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Autowired
|
||||
private EstadoService estadoService;
|
||||
@Autowired
|
||||
private EmpresaService empresaService;
|
||||
@Autowired
|
||||
private PuntoVentaService puntoVentaService;
|
||||
@Autowired
|
||||
private TipoPuntoVentaService tipoPuntoVentaService;
|
||||
@Autowired
|
||||
private DataSource dataSourceRead;
|
||||
@Autowired
|
||||
private transient PagedListWrapper<PuntoVenta> plwPuntoVenta;
|
||||
|
||||
private List<Estado> lsEstado;
|
||||
private List<Empresa> lsEmpresa;
|
||||
private List<TipoPuntoVenta> lsTipoPuntoVenta;
|
||||
|
||||
private List<PuntoVenta> lsNumPuntoVenta;
|
||||
|
||||
@Autowired
|
||||
private transient PagedListWrapper<PuntoVenta> plwPuntoVenta;
|
||||
|
||||
private MyListbox puntoVentaList;
|
||||
private MyListbox estadoList;
|
||||
private MyListbox puntoVentaSelList;
|
||||
private Paging pagingPuntoVenta;
|
||||
|
||||
private Bandbox bbPesquisaPuntoVenta;
|
||||
|
||||
private Textbox txtPalavraPesquisa;
|
||||
private Combobox cmbEstado;
|
||||
private Combobox cmbEmpresa;
|
||||
private Combobox cmbPuntoVenta;
|
||||
private Combobox cmbTipoPuntoVenta;
|
||||
private Combobox cmbReceitaImposto;
|
||||
private Datebox datInicial;
|
||||
private Datebox datFinal;
|
||||
private Checkbox chkExcessoBagagem;
|
||||
private Checkbox chkContemplarGap;
|
||||
private Radio rd1;
|
||||
|
||||
private void executarPesquisa() {
|
||||
HibernateSearchObject<PuntoVenta> puntoVentaBusqueda = new HibernateSearchObject<PuntoVenta>(PuntoVenta.class,
|
||||
pagingPuntoVenta.getPageSize());
|
||||
|
||||
puntoVentaBusqueda.addFilterOr(Filter.like("nombpuntoventa", "%" + txtPalavraPesquisa.getText().trim().toUpperCase().concat("%")), Filter.like("numPuntoVenta", "%" + txtPalavraPesquisa.getText().trim().toUpperCase().concat("%")));
|
||||
|
||||
puntoVentaBusqueda.addSortAsc("nombpuntoventa");
|
||||
|
||||
puntoVentaBusqueda.addFilterEqual("activo", Boolean.TRUE);
|
||||
|
||||
plwPuntoVenta.init(puntoVentaBusqueda, puntoVentaList, pagingPuntoVenta);
|
||||
|
||||
if (puntoVentaList.getData().length == 0) {
|
||||
try {
|
||||
Messagebox.show(Labels.getLabel("MSG.ningunRegistro"),
|
||||
Labels.getLabel("relatorioDevolucaoBilhetesController.window.title"),
|
||||
Messagebox.OK, Messagebox.INFORMATION);
|
||||
} catch (InterruptedException ex) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void executarRelatorio() throws Exception {
|
||||
|
||||
Map<String, Object> parametros = new HashMap<String, Object>();
|
||||
StringBuilder filtro = new StringBuilder();
|
||||
|
||||
parametros.put("DATA_INICIO", new Timestamp((DateUtil.inicioFecha((java.util.Date) this.datInicial.getValue()).getTime())));
|
||||
parametros.put("DATA_FINAL", new Timestamp((DateUtil.fimFecha((java.util.Date) this.datFinal.getValue()).getTime())));
|
||||
parametros.put("NOME_RELATORIO", Labels.getLabel("relatorioDevolucaoBilhetesAgenciaController.window.title"));
|
||||
parametros.put("USUARIO", UsuarioLogado.getUsuarioLogado().getUsuarioId().toString());
|
||||
|
||||
filtro.append("Agência(s): ");
|
||||
if (puntoVentaSelList.getSelectedsItens().size() > 0) {
|
||||
parametros.put("PUNTOVENTAS", puntoVentaSelList.getSelectedsItens());
|
||||
parametros.put("ISNUMPUNTOVENTATODOS", "N");
|
||||
filtro.append(puntoVentaSelList.getSelectedsItens().size() + " selecionada(s);");
|
||||
} else {
|
||||
parametros.put("ISNUMPUNTOVENTATODOS", "S");
|
||||
filtro.append("Todas ;");
|
||||
}
|
||||
|
||||
filtro.append("Estados(s): ");
|
||||
if (estadoList.getSelectedsItens().size() > 0) {
|
||||
parametros.put("ESTADOS", estadoList.getSelectedsItens());
|
||||
filtro.append(estadoList.getSelectedsItens().size() + " selecionado(s);");
|
||||
} else {
|
||||
filtro.append("Todos ;");
|
||||
}
|
||||
|
||||
filtro.append("Empresa: ");
|
||||
Comboitem itemEmpresa = cmbEmpresa.getSelectedItem();
|
||||
if (itemEmpresa != null) {
|
||||
Empresa empresa = (Empresa) itemEmpresa.getValue();
|
||||
parametros.put("EMPRESA_ID", empresa.getEmpresaId());
|
||||
parametros.put("EMPRESA_NOME", empresa.getNombempresa());
|
||||
} else {
|
||||
filtro.append("Todos ;");
|
||||
}
|
||||
|
||||
parametros.put("FILTROS", filtro.toString());
|
||||
|
||||
Relatorio relatorio = new RelatorioDevolucaoBilhetes(parametros, dataSourceRead.getConnection());
|
||||
|
||||
Map<String, Relatorio> args = new HashMap<String, Relatorio>();
|
||||
args.put("relatorio", relatorio);
|
||||
|
||||
openWindow("/component/reportView.zul",
|
||||
Labels.getLabel("relatorioReceitaDiariaAgenciaController.window.title"), args, MODAL);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void doAfterCompose(Component comp) throws Exception {
|
||||
lsEstado = estadoService.obtenerTodos();
|
||||
lsEmpresa = empresaService.obtenerTodos();
|
||||
|
||||
super.doAfterCompose(comp);
|
||||
|
||||
estadoList.setItemRenderer(new RenderEstadoSimple());
|
||||
puntoVentaList.setItemRenderer(new RenderPuntoVentaSimple());
|
||||
puntoVentaSelList.setItemRenderer(new RenderPuntoVentaSimple());
|
||||
|
||||
estadoList.setData(lsEstado);
|
||||
|
||||
}
|
||||
|
||||
public void onClick$btnExecutarRelatorio(Event ev) throws Exception {
|
||||
executarRelatorio();
|
||||
}
|
||||
|
||||
public void onDoubleClick$puntoVentaList(Event ev) {
|
||||
|
||||
PuntoVenta puntoVentaSel = (PuntoVenta) puntoVentaList.getSelected();
|
||||
puntoVentaSelList.addItemNovo(puntoVentaSel);
|
||||
|
||||
}
|
||||
|
||||
public void onDoubleClick$puntoVentaSelList(Event ev) {
|
||||
|
||||
PuntoVenta puntoVentaSel = (PuntoVenta) puntoVentaSelList.getSelected();
|
||||
puntoVentaSelList.removeItem(puntoVentaSel);
|
||||
|
||||
}
|
||||
|
||||
public void onClick$btnLimpar(Event ev) {
|
||||
limparPesquisaAgencia();
|
||||
}
|
||||
|
||||
public void onClick$btnPesquisa(Event ev) {
|
||||
executarPesquisa();
|
||||
}
|
||||
|
||||
public Datebox getDatInicial() {
|
||||
return datInicial;
|
||||
|
@ -166,14 +261,6 @@ public class RelatorioDevolucaoBilhetesController extends MyGenericForwardCompos
|
|||
this.bbPesquisaPuntoVenta = bbPesquisaPuntoVenta;
|
||||
}
|
||||
|
||||
public Checkbox getChkExcessoBagagem() {
|
||||
return chkExcessoBagagem;
|
||||
}
|
||||
|
||||
public void setChkExcessoBagagem(Checkbox chkExcessoBagagem) {
|
||||
this.chkExcessoBagagem = chkExcessoBagagem;
|
||||
}
|
||||
|
||||
public MyListbox getPuntoVentaSelList() {
|
||||
return puntoVentaSelList;
|
||||
}
|
||||
|
@ -190,174 +277,8 @@ public class RelatorioDevolucaoBilhetesController extends MyGenericForwardCompos
|
|||
this.lsEmpresa = lsEmpresa;
|
||||
}
|
||||
|
||||
public List<TipoPuntoVenta> getLsTipoPuntoVenta() {
|
||||
return lsTipoPuntoVenta;
|
||||
}
|
||||
|
||||
public void setLsTipoPuntoVenta(List<TipoPuntoVenta> lsTipoPuntoVenta) {
|
||||
this.lsTipoPuntoVenta = lsTipoPuntoVenta;
|
||||
}
|
||||
|
||||
public void onClick$btnExecutarRelatorio(Event ev) throws Exception {
|
||||
executarRelatorio();
|
||||
}
|
||||
|
||||
public void onDoubleClick$puntoVentaList(Event ev) {
|
||||
|
||||
PuntoVenta puntoVentaSel = (PuntoVenta) puntoVentaList.getSelected();
|
||||
puntoVentaSelList.addItemNovo(puntoVentaSel);
|
||||
|
||||
}
|
||||
|
||||
public void onDoubleClick$puntoVentaSelList(Event ev) {
|
||||
|
||||
PuntoVenta puntoVentaSel = (PuntoVenta) puntoVentaSelList.getSelected();
|
||||
puntoVentaSelList.removeItem(puntoVentaSel);
|
||||
|
||||
}
|
||||
|
||||
public void onClick$btnLimpar(Event ev) {
|
||||
limparPesquisaAgencia();
|
||||
}
|
||||
|
||||
public void onClick$btnPesquisa(Event ev) {
|
||||
executarPesquisa();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private void limparPesquisaAgencia() {
|
||||
puntoVentaSelList.setData(new ArrayList<Object>());
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private void executarPesquisa() {
|
||||
HibernateSearchObject<PuntoVenta> puntoVentaBusqueda =
|
||||
new HibernateSearchObject<PuntoVenta>(PuntoVenta.class,
|
||||
pagingPuntoVenta.getPageSize());
|
||||
|
||||
puntoVentaBusqueda.addFilterOr(Filter.like("nombpuntoventa", "%" + txtPalavraPesquisa.getText().trim().toUpperCase().concat("%")), Filter.like("numPuntoVenta", "%" + txtPalavraPesquisa.getText().trim().toUpperCase().concat("%")));
|
||||
|
||||
puntoVentaBusqueda.addSortAsc("nombpuntoventa");
|
||||
|
||||
puntoVentaBusqueda.addFilterEqual("activo", Boolean.TRUE);
|
||||
|
||||
plwPuntoVenta.init(puntoVentaBusqueda, puntoVentaList, pagingPuntoVenta);
|
||||
|
||||
if (puntoVentaList.getData().length == 0) {
|
||||
try {
|
||||
Messagebox.show(Labels.getLabel("MSG.ningunRegistro"),
|
||||
Labels.getLabel("relatorioDevolucaoBilhetesController.window.title"),
|
||||
Messagebox.OK, Messagebox.INFORMATION);
|
||||
} catch (InterruptedException ex) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws Exception
|
||||
*
|
||||
*/
|
||||
private void executarRelatorio() throws Exception {
|
||||
|
||||
Map<String, Object> parametros = new HashMap<String, Object>();
|
||||
StringBuilder filtro = new StringBuilder();
|
||||
|
||||
parametros.put("DATA_INICIO", new java.sql.Date(((java.util.Date) this.datInicial.getValue()).getTime()));
|
||||
parametros.put("DATA_FINAL", new java.sql.Date(((java.util.Date) this.datFinal.getValue()).getTime()));
|
||||
parametros.put("B_EXCLUI_BAGAGEM", chkExcessoBagagem.isChecked());
|
||||
parametros.put("B_CONTEMPLAR_GAP", chkContemplarGap.isChecked());
|
||||
parametros.put("NOME_RELATORIO", Labels.getLabel("relatorioDevolucaoBilhetesController.window.title"));
|
||||
parametros.put("ISDEVOLUCAODESTINO", rd1.isChecked() ? 0 : 1);
|
||||
parametros.put("USUARIO", UsuarioLogado.getUsuarioLogado().getUsuarioId().toString());
|
||||
|
||||
parametros.put("BASE_CALCULO_IMPOSTO", Integer.valueOf(cmbReceitaImposto.getSelectedItem().getValue().toString()));
|
||||
|
||||
lsNumPuntoVenta = new ArrayList(Arrays.asList(puntoVentaSelList.getData()));
|
||||
|
||||
filtro.append("Agência(s): ");
|
||||
if (lsNumPuntoVenta.size() > 0) {
|
||||
parametros.put("NUMPUNTOVENTA", lsNumPuntoVenta);
|
||||
parametros.put("ISNUMPUNTOVENTATODOS", "N");
|
||||
filtro.append(lsNumPuntoVenta.size() + " selecionada(s);");
|
||||
}
|
||||
else {
|
||||
parametros.put("ISNUMPUNTOVENTATODOS", "S");
|
||||
filtro.append("Todas ;");
|
||||
}
|
||||
|
||||
filtro.append("Estados(s): ");
|
||||
if (estadoList.getSelectedsItens().size() > 0) {
|
||||
parametros.put("ESTADO_ID", estadoList.getSelectedsItens());
|
||||
filtro.append(estadoList.getSelectedsItens().size() + " selecionado(s);");
|
||||
}
|
||||
else {
|
||||
filtro.append("Todos ;");
|
||||
}
|
||||
|
||||
Comboitem itemEmpresa = cmbEmpresa.getSelectedItem();
|
||||
if (itemEmpresa != null) {
|
||||
Empresa empresa = (Empresa) itemEmpresa.getValue();
|
||||
parametros.put("EMPRESA_ID", empresa.getEmpresaId());
|
||||
parametros.put("EMPRESA_NOME", empresa.getNombempresa());
|
||||
}
|
||||
|
||||
filtro.append(" Tipo Agência: ");
|
||||
Comboitem itemTipoPunto = cmbTipoPuntoVenta.getSelectedItem();
|
||||
if (itemTipoPunto != null && ((TipoPuntoVenta) cmbTipoPuntoVenta.getSelectedItem().getValue()).getTipoptovtaId() != -1) {
|
||||
TipoPuntoVenta tipoPuntoVenta = (TipoPuntoVenta) itemTipoPunto.getValue();
|
||||
parametros.put("TIPOPTOVTA_ID", tipoPuntoVenta.getTipoptovtaId().intValue());
|
||||
filtro.append(tipoPuntoVenta.getDesctipo() + ";");
|
||||
}
|
||||
else
|
||||
filtro.append("Todos;");
|
||||
|
||||
if (chkContemplarGap.isChecked())
|
||||
filtro.append(" Contemplar GAP;");
|
||||
else
|
||||
filtro.append(" Desconsiderar GAP;");
|
||||
|
||||
if (chkExcessoBagagem.isChecked())
|
||||
filtro.append(" Exclui Excesso de Bagagem;");
|
||||
else
|
||||
filtro.append(" Inclui Excesso de Bagagem;");
|
||||
|
||||
filtro.append(" Devolução na agência: ");
|
||||
|
||||
if (rd1.isChecked())
|
||||
filtro.append("Origem;");
|
||||
else
|
||||
filtro.append("Destino;");
|
||||
|
||||
parametros.put("FILTROS", filtro.toString());
|
||||
|
||||
Relatorio relatorio = new RelatorioReceitaDiariaAgencia(parametros, dataSourceRead.getConnection());
|
||||
|
||||
Map args = new HashMap();
|
||||
args.put("relatorio", relatorio);
|
||||
|
||||
openWindow("/component/reportView.zul",
|
||||
Labels.getLabel("relatorioReceitaDiariaAgenciaController.window.title"), args, MODAL);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void doAfterCompose(Component comp) throws Exception {
|
||||
lsEstado = estadoService.obtenerTodos();
|
||||
lsEmpresa = empresaService.obtenerTodos();
|
||||
setLsTipoPuntoVenta(tipoPuntoVentaService.obtenerTodos());
|
||||
super.doAfterCompose(comp);
|
||||
|
||||
estadoList.setItemRenderer(new RenderEstadoSimple());
|
||||
puntoVentaList.setItemRenderer(new RenderPuntoVentaSimple());
|
||||
puntoVentaSelList.setItemRenderer(new RenderPuntoVentaSimple());
|
||||
|
||||
estadoList.setData(lsEstado);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@ public class ItemMenuRelatorioDevolucaoBilhetes extends DefaultItemMenuSistema {
|
|||
@Override
|
||||
public void ejecutar() {
|
||||
PantallaUtileria.openWindow("/gui/relatorios/filtroRelatorioDevolucaoBilhetes.zul",
|
||||
Labels.getLabel("relatorioDevolucaoBilhetesController.window.title"), getArgs(), desktop);
|
||||
Labels.getLabel("relatorioDevolucaoBilhetesAgenciaController.window.title"), getArgs(), desktop);
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -7,8 +7,7 @@
|
|||
<zk xmlns="http://www.zkoss.org/2005/zul">
|
||||
<window id="winFiltroRelatorioDevolucaoBilhetes"
|
||||
apply="${relatorioDevolucaoBilhetesController}"
|
||||
contentStyle="overflow:auto" height="324px" width="550px"
|
||||
border="normal">
|
||||
contentStyle="overflow:auto" width="750px" border="normal">
|
||||
<grid fixedLayout="true">
|
||||
<columns>
|
||||
<column width="20%" />
|
||||
|
@ -19,51 +18,28 @@
|
|||
<rows>
|
||||
<row>
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbDataIni.value')}" />
|
||||
value="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbDataIni.value')}" />
|
||||
<datebox id="datInicial" width="90%"
|
||||
format="dd/MM/yyyy" lenient="false" constraint="no empty"
|
||||
maxlength="10" />
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbDataFin.value')}" />
|
||||
value="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbDataFin.value')}" />
|
||||
<datebox id="datFinal" width="90%"
|
||||
format="dd/MM/yyyy" lenient="false" constraint="no empty"
|
||||
maxlength="10" />
|
||||
|
||||
</row>
|
||||
<row>
|
||||
|
||||
<row>
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbEmpresa.value')}" />
|
||||
value="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbEmpresa.value')}" />
|
||||
<combobox id="cmbEmpresa" width="90%" mold="rounded"
|
||||
buttonVisible="true"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||
model="@{winFiltroRelatorioDevolucaoBilhetes$composer.lsEmpresa}"
|
||||
/>
|
||||
model="@{winFiltroRelatorioDevolucaoBilhetes$composer.lsEmpresa}" />
|
||||
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbTipoPuntoVenta.value')}" />
|
||||
<combobox id="cmbTipoPuntoVenta" width="90%"
|
||||
mold="rounded" buttonVisible="true"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||
model="@{winFiltroRelatorioDevolucaoBilhetes$composer.lsTipoPuntoVenta}" />
|
||||
</row>
|
||||
|
||||
<row>
|
||||
<label value="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.label')}" />
|
||||
<combobox id="cmbReceitaImposto" width="90%"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||
mold="rounded" constraint="no empty">
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitas')}" value="1" />
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitaPassagem')}"
|
||||
value="2" />
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitaSeguro')}" value="3" />
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitaEmbarque')}"
|
||||
value="4" />
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitaPedagio')}" value="5" />
|
||||
<comboitem label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.cmbReceitaImposto.cmbItemReceitaBagagem')}" value="6" />
|
||||
</combobox>
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbPuntoVenta.value')}" />
|
||||
value="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbPuntoVenta.value')}" />
|
||||
<bandbox id="bbPesquisaPuntoVenta" width="90%"
|
||||
mold="rounded" readonly="true">
|
||||
<bandpopup height="150px">
|
||||
|
@ -72,10 +48,10 @@
|
|||
<textbox id="txtPalavraPesquisa" />
|
||||
<button id="btnPesquisa"
|
||||
image="/gui/img/find.png"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.btnPesquisa.label')}" />
|
||||
label="${c:l('relatorioDevolucaoBilhetesAgenciaController.btnPesquisa.label')}" />
|
||||
<button id="btnLimpar"
|
||||
image="/gui/img/eraser.png"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.btnLimpar.label')}" />
|
||||
label="${c:l('relatorioDevolucaoBilhetesAgenciaController.btnLimpar.label')}" />
|
||||
</hbox>
|
||||
|
||||
<listbox id="puntoVentaList"
|
||||
|
@ -84,9 +60,9 @@
|
|||
vflex="true" multiple="false" height="100%" width="360px">
|
||||
<listhead>
|
||||
<listheader
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.puntoVentaSelList.codigo')}" />
|
||||
label="${c:l('relatorioDevolucaoBilhetesAgenciaController.puntoVentaSelList.codigo')}" />
|
||||
<listheader
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.puntoVentaSelList.nome')}" />
|
||||
label="${c:l('relatorioDevolucaoBilhetesAgenciaController.puntoVentaSelList.nome')}" />
|
||||
</listhead>
|
||||
</listbox>
|
||||
<paging id="pagingPuntoVenta"
|
||||
|
@ -95,21 +71,21 @@
|
|||
</bandpopup>
|
||||
</bandbox>
|
||||
</row>
|
||||
<row>
|
||||
|
||||
<row>
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbEstado.value')}" />
|
||||
<listbox id="estadoList" mold="select" rows="3"
|
||||
value="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbEstado.value')}" />
|
||||
<listbox id="estadoList" mold="select" rows="8"
|
||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyListbox"
|
||||
vflex="true" multiple="true" width="90%">
|
||||
vflex="true" multiple="true" width="100%" >
|
||||
<listhead>
|
||||
<listheader
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.lbEstado.value')}" />
|
||||
label="${c:l('relatorioDevolucaoBilhetesAgenciaController.lbEstado.value')}" />
|
||||
</listhead>
|
||||
</listbox>
|
||||
|
||||
<cell colspan="2" rowspan="2">
|
||||
<borderlayout height="100px">
|
||||
<borderlayout height="150px">
|
||||
<center border="0">
|
||||
<listbox id="puntoVentaSelList"
|
||||
mold="paging"
|
||||
|
@ -127,31 +103,6 @@
|
|||
</borderlayout>
|
||||
</cell>
|
||||
</row>
|
||||
<row>
|
||||
<label
|
||||
value="${c:l('relatorioDevolucaoBilhetesController.lbDevolucao.value')}" />
|
||||
<cell>
|
||||
<radiogroup id="rdIndAgenciaDevol" />
|
||||
<radio id="rd1" checked="true"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.rd1.label')}"
|
||||
radiogroup="rdIndAgenciaDevol" />
|
||||
<radio id="rd2"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.rdIndAgenciaDevol.rd2.label')}"
|
||||
radiogroup="rdIndAgenciaDevol" />
|
||||
</cell>
|
||||
|
||||
|
||||
</row>
|
||||
<row>
|
||||
<cell colspan="2">
|
||||
<checkbox id="chkExcessoBagagem"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.chkExcessoBagagem.label')}" />
|
||||
</cell>
|
||||
<cell colspan="2">
|
||||
<checkbox id="chkContemplarGap"
|
||||
label="${c:l('relatorioDevolucaoBilhetesController.chkContemplarGap.label')}" />
|
||||
</cell>
|
||||
</row>
|
||||
|
||||
</rows>
|
||||
</grid>
|
||||
|
|
Loading…
Reference in New Issue