fixes bug #9856
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@75648 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
4e74a32840
commit
4f769991e9
|
@ -1,94 +0,0 @@
|
|||
package com.rjconsultores.ventaboletos.relatorios.impl;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.ArrayDataSource;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
|
||||
|
||||
public class RelatorioAidfDetalhado extends Relatorio {
|
||||
|
||||
public RelatorioAidfDetalhado(Map<String, Object> parametros, Connection conexao) throws Exception
|
||||
{
|
||||
super(parametros, conexao);
|
||||
|
||||
this.setCustomDataSource(new ArrayDataSource(this) {
|
||||
|
||||
public void initDados() throws Exception {
|
||||
Connection conexao = this.relatorio.getConexao();
|
||||
Map<String, Object> parametros = this.relatorio.getParametros();
|
||||
String sql = getSql();
|
||||
|
||||
NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql);
|
||||
|
||||
ResultSet rset = stmt.executeQuery();
|
||||
|
||||
while (rset.next()) {
|
||||
Map<String, Object> dataResult = new HashMap<String, Object>();
|
||||
dataResult.put("aidf", rset.getString("aidf"));
|
||||
dataResult.put("empresa", rset.getString("nombempresa"));
|
||||
dataResult.put("estacao", rset.getString("estacao"));
|
||||
dataResult.put("agencia", rset.getString("nombpuntoventa"));
|
||||
dataResult.put("serie", rset.getString("serie"));
|
||||
dataResult.put("subserie", rset.getString("subserie"));
|
||||
dataResult.put("numeracao", rset.getString("numeracao"));
|
||||
dataResult.put("folios", rset.getString("folios"));
|
||||
dataResult.put("forminicio", rset.getString("forminicial"));
|
||||
dataResult.put("formfinal", rset.getString("formfinal"));
|
||||
this.dados.add(dataResult);
|
||||
}
|
||||
|
||||
this.resultSet = rset;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void processaParametros() throws Exception {
|
||||
}
|
||||
|
||||
private String getSql() {
|
||||
StringBuilder sql = new StringBuilder();
|
||||
sql.append(" select a.aidf_id as aidf, e.nombempresa, p.nombpuntoventa, a.serie, ab.estacion_id as estacao, a.subserie, a.forminicial, a.formfinal,");
|
||||
sql.append(" concat(a.forminicial, concat('-',a.formfinal)) as numeracao,");
|
||||
sql.append(" concat(fp.foliopreimpreso,concat('-',dab.numfoliofinal)) as folios ");
|
||||
sql.append(" from aidf a ");
|
||||
sql.append(" inner join empresa e on e.empresa_id = a.empresa_id ");
|
||||
sql.append(" inner join abasto_boleto ab on a.empresa_id = ab.empresa_id and ab.ACTIVO = 1 ");
|
||||
sql.append(" inner join det_abasto_boleto dab on dab.abastoboleto_id = ab.abastoboleto_id and dab.ACTIVO = 1 ");
|
||||
sql.append(" inner join punto_venta p on p.puntoventa_id = ab.puntoventa_id and p.ACTIVO = 1");
|
||||
sql.append(" inner join folio_preimpreso fp on (a.serie=fp.numeserie or concat(a.aidf_id, concat(a.serie,a.subserie))=fp.numeserie OR concat(a.serie,concat('-',a.subserie))=fp.numeserie) and fp.ACTIVO = 1");
|
||||
sql.append(" where ");
|
||||
sql.append(" a.ACTIVO = 1");
|
||||
if(parametros.get("EMPRESA_ID") != null){
|
||||
sql.append(" and a.empresa_id = ").append(parametros.get("EMPRESA_ID"));
|
||||
}
|
||||
if(parametros.get("SERIE") != null){
|
||||
sql.append(" and (a.serie ='").append(parametros.get("SERIE")).append("'");
|
||||
sql.append(" or concat(a.aidf_id, concat(a.SERIE,a.SUBSERIE))='").append(parametros.get("SERIE")).append("')");
|
||||
}
|
||||
if(parametros.get("AIDF") != null){
|
||||
sql.append(" and a.aidf_id like'%").append(parametros.get("AIDF")).append("%'");
|
||||
}
|
||||
if(parametros.get("INICIOFORM") != null){
|
||||
sql.append(" and a.forminicial >= ").append(parametros.get("INICIOFORM"));
|
||||
}
|
||||
if(parametros.get("FIMFORM") != null){
|
||||
sql.append(" and a.formfinal <= ").append(parametros.get("FIMFORM"));
|
||||
}
|
||||
if(parametros.get("NUMPUNTOVENTA") != null){
|
||||
sql.append(" and ab.puntoventa_id in(").append(parametros.get("NUMPUNTOVENTA")).append(") ");
|
||||
}
|
||||
sql.append(" group by a.aidf_id, e.nombempresa, p.nombpuntoventa, a.serie, ab.estacion_id , a.subserie,concat(a.forminicial, concat('-',a.formfinal)), a.forminicial, a.formfinal, ");
|
||||
sql.append(" concat(fp.foliopreimpreso,concat('-',dab.numfoliofinal)) ");
|
||||
sql.append(" order by a.aidf_id");
|
||||
|
||||
return sql.toString();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,82 @@
|
|||
package com.rjconsultores.ventaboletos.relatorios.impl;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.ResultSet;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.ArrayDataSource;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
|
||||
|
||||
public class RelatorioEstoque extends Relatorio {
|
||||
|
||||
public RelatorioEstoque(Map<String, Object> parametros, Connection conexao) throws Exception
|
||||
{
|
||||
super(parametros, conexao);
|
||||
|
||||
this.setCustomDataSource(new ArrayDataSource(this) {
|
||||
|
||||
public void initDados() throws Exception {
|
||||
Connection conexao = this.relatorio.getConexao();
|
||||
Map<String, Object> parametros = this.relatorio.getParametros();
|
||||
String sql = getSql();
|
||||
|
||||
NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql);
|
||||
|
||||
ResultSet rset = stmt.executeQuery();
|
||||
|
||||
while (rset.next()) {
|
||||
Map<String, Object> dataResult = new HashMap<String, Object>();
|
||||
dataResult.put("aidf", rset.getString("aidf"));
|
||||
dataResult.put("empresa", rset.getString("nombempresa"));
|
||||
dataResult.put("estacao", rset.getString("estacao"));
|
||||
dataResult.put("agencia", rset.getString("nombpuntoventa"));
|
||||
dataResult.put("serie", rset.getString("serie"));
|
||||
dataResult.put("forminicio", rset.getString("forminicial"));
|
||||
dataResult.put("formfinal", rset.getString("formfinal"));
|
||||
dataResult.put("estado", rset.getString("nombestado"));
|
||||
dataResult.put("descestacion", rset.getString("estacao"));
|
||||
this.dados.add(dataResult);
|
||||
}
|
||||
|
||||
this.resultSet = rset;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void processaParametros() throws Exception {
|
||||
}
|
||||
|
||||
private String getSql() {
|
||||
StringBuilder sql = new StringBuilder();
|
||||
sql.append(" select dab.aidf_id as aidf, e.nombempresa, p.nombpuntoventa, dab.NUMSERIEPREIMPRESA as serie, es.descestacion as estacao, ");
|
||||
sql.append(" case when dab.STATUSOPERACION = 0 then dab.NUMFOLIOINICIAL else coalesce(fp.FOLIOPREIMPRESO,dab.NUMFOLIOINICIAL) end as forminicial, dab.NUMFOLIOFINAL as formfinal, ");
|
||||
sql.append(" est.nombestado, ar.descarticulo ");
|
||||
sql.append(" from abasto_boleto ab ");
|
||||
sql.append(" inner join empresa e on e.empresa_id = ab.empresa_id and ab.ACTIVO = 1 ");
|
||||
sql.append(" inner join det_abasto_boleto dab on dab.abastoboleto_id = ab.abastoboleto_id and dab.ACTIVO = 1 ");
|
||||
sql.append(" inner join punto_venta p on p.puntoventa_id = ab.puntoventa_id and p.ACTIVO = 1 ");
|
||||
sql.append(" inner join estacion es on es.ESTACION_ID = ab.ESTACION_ID ");
|
||||
sql.append(" inner join ARTICULO ar on ar.ARTICULO_ID = ab.ARTICULO_ID ");
|
||||
sql.append(" left join FOLIO_PREIMPRESO fp on fp.AIDF_ID = dab.AIDF_ID and fp.EMPRESA_ID = e.EMPRESA_ID and fp.ESTACION_ID = ab.ESTACION_ID and fp.activo = 1 ");
|
||||
sql.append(" inner join aidf ai on ai.aidf_id =dab.aidf_id ");
|
||||
sql.append(" inner join estado est on est.estado_id = ai.ESTADO_ID ");
|
||||
|
||||
sql.append(" where ");
|
||||
sql.append(" dab.statusoperacion in (0,1) and dab.activo = 1 and ab.activo = 1 ");
|
||||
if(parametros.get("EMPRESA_ID") != null){
|
||||
sql.append(" and e.empresa_id = ").append(parametros.get("EMPRESA_ID"));
|
||||
}
|
||||
if(parametros.get("NUMPUNTOVENTA") != null){
|
||||
sql.append(" and ab.puntoventa_id in(").append(parametros.get("NUMPUNTOVENTA")).append(") ");
|
||||
}
|
||||
sql.append(" order by e.nombempresa, p.nombpuntoventa,es.descestacion, ar.descarticulo, forminicial");
|
||||
|
||||
return sql.toString();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
Binary file not shown.
Binary file not shown.
|
@ -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="RelatorioAidfDetalhado" pageWidth="842" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" resourceBundle="/ventaboletosadm/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioAidfDetalhado_es_BR" uuid="c092ef85-9334-4225-93d7-1acb7cf4d021">
|
||||
<property name="ireport.zoom" value="1.0"/>
|
||||
<property name="ireport.x" value="0"/>
|
||||
<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="RelatorioEstoque" pageWidth="842" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" resourceBundle="/ventaboletosadm/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioAidfDetalhado_es_BR" uuid="c092ef85-9334-4225-93d7-1acb7cf4d021">
|
||||
<property name="ireport.zoom" value="1.6105100000000032"/>
|
||||
<property name="ireport.x" value="684"/>
|
||||
<property name="ireport.y" value="0"/>
|
||||
<property name="net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.2" value="pageHeader"/>
|
||||
<property name="net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.1" value="columnHeader"/>
|
||||
|
@ -23,13 +23,15 @@
|
|||
<field name="forminicio" class="java.lang.String"/>
|
||||
<field name="formfinal" class="java.lang.String"/>
|
||||
<field name="estacao" class="java.lang.String"/>
|
||||
<field name="descestacion" class="java.lang.String"/>
|
||||
<field name="estado" class="java.lang.String"/>
|
||||
<background>
|
||||
<band splitType="Stretch"/>
|
||||
</background>
|
||||
<pageHeader>
|
||||
<band height="82" splitType="Stretch">
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="0" y="0" width="457" height="35" forecolor="#000000" backcolor="#FFFFFF" uuid="136a5066-d141-4362-af36-0780f0d16542"/>
|
||||
<reportElement mode="Transparent" x="0" y="0" width="457" height="41" forecolor="#000000" backcolor="#FFFFFF" uuid="136a5066-d141-4362-af36-0780f0d16542"/>
|
||||
<textElement textAlignment="Left" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="14" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
|
@ -37,14 +39,14 @@
|
|||
<textFieldExpression><![CDATA[$P{NOME_RELATORIO}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="628" y="0" width="100" height="25" uuid="a9d471fb-1e1d-4d9a-9783-bbf988931192"/>
|
||||
<reportElement x="513" y="0" width="185" height="25" uuid="a9d471fb-1e1d-4d9a-9783-bbf988931192"/>
|
||||
<textElement textAlignment="Right">
|
||||
<font size="9" isBold="true"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.dataHora}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy HH:mm" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="728" y="0" width="73" height="25" forecolor="#000000" backcolor="#FFFFFF" uuid="0d200750-aabf-4c7e-b27b-c0e7af4802a9"/>
|
||||
<reportElement mode="Transparent" x="698" y="0" width="104" height="25" forecolor="#000000" backcolor="#FFFFFF" uuid="0d200750-aabf-4c7e-b27b-c0e7af4802a9"/>
|
||||
<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"/>
|
||||
|
@ -55,7 +57,7 @@
|
|||
<reportElement x="0" y="57" width="802" height="1" uuid="bbf33a72-515f-42fc-8c79-e859aebca31d"/>
|
||||
</line>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="668" y="26" width="112" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="bae9bec6-8c42-4bee-a070-34b0a7f1aee4"/>
|
||||
<reportElement mode="Transparent" x="513" y="25" width="267" height="16" forecolor="#000000" backcolor="#FFFFFF" uuid="bae9bec6-8c42-4bee-a070-34b0a7f1aee4"/>
|
||||
<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"/>
|
||||
|
@ -63,7 +65,7 @@
|
|||
<textFieldExpression><![CDATA[$R{cabecalho.pagina}+" "+$V{PAGE_NUMBER}+" "+$R{cabecalho.de}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField evaluationTime="Report" pattern="" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="781" y="26" width="20" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="314e312c-8f24-42de-8354-3c1f7241a985"/>
|
||||
<reportElement mode="Transparent" x="781" y="25" width="21" height="16" forecolor="#000000" backcolor="#FFFFFF" uuid="314e312c-8f24-42de-8354-3c1f7241a985"/>
|
||||
<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"/>
|
||||
|
@ -71,9 +73,9 @@
|
|||
<textFieldExpression><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="" isBlankWhenNull="false">
|
||||
<reportElement mode="Transparent" x="698" y="42" width="100" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="4e030613-9cee-443e-9eaa-b19fa3090976"/>
|
||||
<reportElement mode="Transparent" x="698" y="42" width="104" height="15" forecolor="#000000" backcolor="#FFFFFF" uuid="4e030613-9cee-443e-9eaa-b19fa3090976"/>
|
||||
<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"/>
|
||||
<font fontName="SansSerif" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$R{cabecalho.impressorPor}+" "+$P{USUARIO}]]></textFieldExpression>
|
||||
|
@ -82,9 +84,9 @@
|
|||
<reportElement x="0" y="77" width="802" height="1" uuid="6ca45088-a58d-43b3-b196-8fc26e128fbf"/>
|
||||
</line>
|
||||
<textField>
|
||||
<reportElement x="0" y="59" width="802" height="14" uuid="b29d0494-2695-420b-bdc1-b13c08bdbcda"/>
|
||||
<reportElement x="0" y="58" width="803" height="15" uuid="b29d0494-2695-420b-bdc1-b13c08bdbcda"/>
|
||||
<textElement verticalAlignment="Middle">
|
||||
<font size="8"/>
|
||||
<font size="10"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$P{FILTROS}]]></textFieldExpression>
|
||||
</textField>
|
||||
|
@ -93,120 +95,141 @@
|
|||
<columnHeader>
|
||||
<band height="35" splitType="Stretch">
|
||||
<line>
|
||||
<reportElement x="1" y="34" width="802" height="1" uuid="a11636cc-5ee1-44cc-8cd1-cbe2ebc47abb"/>
|
||||
<reportElement x="1" y="34" width="801" height="1" uuid="a11636cc-5ee1-44cc-8cd1-cbe2ebc47abb"/>
|
||||
</line>
|
||||
<staticText>
|
||||
<reportElement x="1" y="15" width="65" height="20" uuid="ed0c0a45-151a-400e-a30c-fd8afa88438b"/>
|
||||
<reportElement x="131" y="15" width="139" height="19" uuid="d60cb698-201c-4315-bec2-498effeea474"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[AIDF]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="429" y="14" width="75" height="20" uuid="0bc3df3b-544b-4e68-ace9-f725d4541781"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Serie]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="66" y="15" width="130" height="20" uuid="6db7e341-bc01-4843-8be5-fe74d78b7529"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Empresa]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="196" y="14" width="139" height="20" uuid="d60cb698-201c-4315-bec2-498effeea474"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Agência]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="501" y="14" width="75" height="20" uuid="cac5eac8-5b7f-49e9-a9eb-772fed9c238f"/>
|
||||
<reportElement x="380" y="15" width="77" height="20" uuid="a26b9060-8bd5-4586-af31-e01b0ccf88f9"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Subserie]]></text>
|
||||
<text><![CDATA[De]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="576" y="14" width="105" height="20" uuid="a26b9060-8bd5-4586-af31-e01b0ccf88f9"/>
|
||||
<reportElement x="513" y="15" width="102" height="20" uuid="fcf366c0-0f13-44f7-84de-38ae1122b647"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Numeração]]></text>
|
||||
<text><![CDATA[Tipo]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="681" y="14" width="122" height="20" uuid="fcf366c0-0f13-44f7-84de-38ae1122b647"/>
|
||||
<reportElement x="1" y="15" width="130" height="19" uuid="6db7e341-bc01-4843-8be5-fe74d78b7529"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Folios]]></text>
|
||||
<text><![CDATA[Empresa]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="335" y="14" width="100" height="20" uuid="ea11f3f2-8b0d-4fc9-a87b-c190b8dab51f"/>
|
||||
<reportElement x="270" y="15" width="65" height="19" uuid="ed0c0a45-151a-400e-a30c-fd8afa88438b"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="12" isBold="true"/>
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[AIDF]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="336" y="15" width="44" height="19" uuid="0bc3df3b-544b-4e68-ace9-f725d4541781"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Série]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="457" y="15" width="56" height="20" uuid="dbf9b898-7cb2-4271-84f3-32aa65056b5d"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Até]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="615" y="15" width="83" height="20" uuid="ea11f3f2-8b0d-4fc9-a87b-c190b8dab51f"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Estação]]></text>
|
||||
</staticText>
|
||||
<staticText>
|
||||
<reportElement x="698" y="15" width="104" height="20" uuid="e8f84740-2a73-4631-a584-349b7c263496"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Middle">
|
||||
<font size="10" isBold="true"/>
|
||||
</textElement>
|
||||
<text><![CDATA[Estado]]></text>
|
||||
</staticText>
|
||||
</band>
|
||||
</columnHeader>
|
||||
<detail>
|
||||
<band height="22" splitType="Stretch">
|
||||
<textField>
|
||||
<reportElement x="196" y="0" width="139" height="20" uuid="c35afacb-b160-4ace-b7be-c2e2f54ac1c0"/>
|
||||
<reportElement x="131" y="2" width="139" height="18" uuid="c35afacb-b160-4ace-b7be-c2e2f54ac1c0"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="10" isBold="false" isItalic="false"/>
|
||||
<font size="8" isBold="false" isItalic="false"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{agencia}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="66" y="0" width="130" height="20" uuid="73582b2a-b21b-4637-990c-aff7423a8e27"/>
|
||||
<textField isStretchWithOverflow="true" pattern="¤ #,##0.00" isBlankWhenNull="true">
|
||||
<reportElement mode="Transparent" x="380" y="2" width="77" height="18" forecolor="#000000" backcolor="#FFFFFF" uuid="3dbaaef7-dae9-402d-89d4-a8055462f563"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="8" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{forminicio}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="513" y="2" width="102" height="18" uuid="f1e52aa0-f61d-4c94-bb09-e51cde37f2cc"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="10" isBold="false" isItalic="false"/>
|
||||
<font size="8"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{descestacion}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="1" y="2" width="130" height="18" uuid="73582b2a-b21b-4637-990c-aff7423a8e27"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="8" isBold="false" isItalic="false"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{empresa}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy">
|
||||
<reportElement x="270" y="2" width="66" height="18" uuid="bfb9d635-bbc1-4e92-890a-df8299bc8daa"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="8" isBold="false" isItalic="false"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{aidf}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isStretchWithOverflow="true" pattern="dd/MM/yyyy" isBlankWhenNull="true">
|
||||
<reportElement mode="Transparent" x="429" y="0" width="75" height="20" forecolor="#000000" backcolor="#FFFFFF" uuid="29ae3fa8-9db1-46c8-bcf7-cb9aa7bc6eb3"/>
|
||||
<reportElement mode="Transparent" x="336" y="2" width="44" height="18" forecolor="#000000" backcolor="#FFFFFF" uuid="29ae3fa8-9db1-46c8-bcf7-cb9aa7bc6eb3"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<font fontName="SansSerif" size="8" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{serie}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField pattern="dd/MM/yyyy">
|
||||
<reportElement x="0" y="1" width="66" height="20" uuid="bfb9d635-bbc1-4e92-890a-df8299bc8daa"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="10" isBold="false" isItalic="false"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{aidf}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isStretchWithOverflow="true" pattern="¤ #,##0.00" isBlankWhenNull="true">
|
||||
<reportElement mode="Transparent" x="576" y="0" width="105" height="20" forecolor="#000000" backcolor="#FFFFFF" uuid="3dbaaef7-dae9-402d-89d4-a8055462f563"/>
|
||||
<reportElement mode="Transparent" x="457" y="2" width="56" height="18" forecolor="#000000" backcolor="#FFFFFF" uuid="117054b3-9ee6-488b-ae15-0de5362e939e"/>
|
||||
<textElement textAlignment="Center" verticalAlignment="Top" rotation="None" markup="none">
|
||||
<font fontName="SansSerif" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<font fontName="SansSerif" size="8" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfEncoding="Cp1252" isPdfEmbedded="false"/>
|
||||
<paragraph lineSpacing="Single"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{numeracao}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField isBlankWhenNull="true">
|
||||
<reportElement x="504" y="0" width="72" height="20" uuid="3fab32db-2b16-4bb6-bfbd-ba3941f4040f"/>
|
||||
<textElement textAlignment="Center"/>
|
||||
<textFieldExpression><![CDATA[$F{subserie}]]></textFieldExpression>
|
||||
<textFieldExpression><![CDATA[$F{formfinal}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="681" y="0" width="122" height="20" uuid="f1e52aa0-f61d-4c94-bb09-e51cde37f2cc"/>
|
||||
<textElement textAlignment="Center"/>
|
||||
<textFieldExpression><![CDATA[$F{folios}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="335" y="2" width="94" height="20" uuid="a0ee8a4d-39ef-458a-895d-b12b794876d9"/>
|
||||
<textElement textAlignment="Center"/>
|
||||
<reportElement x="615" y="2" width="83" height="18" uuid="a0ee8a4d-39ef-458a-895d-b12b794876d9"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="8"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{estacao}]]></textFieldExpression>
|
||||
</textField>
|
||||
<textField>
|
||||
<reportElement x="698" y="2" width="104" height="18" uuid="ecc06a2b-2970-4bd0-abf0-e4f4ad0063fd"/>
|
||||
<textElement textAlignment="Center">
|
||||
<font size="8"/>
|
||||
</textElement>
|
||||
<textFieldExpression><![CDATA[$F{estado}]]></textFieldExpression>
|
||||
</textField>
|
||||
</band>
|
||||
</detail>
|
||||
<summary>
|
||||
|
@ -215,7 +238,7 @@
|
|||
<noData>
|
||||
<band height="50">
|
||||
<textField>
|
||||
<reportElement x="46" y="24" width="530" height="26" uuid="6f13c961-dd50-4e44-ba73-65e0752b8b83"/>
|
||||
<reportElement x="1" y="24" width="575" height="26" uuid="6f13c961-dd50-4e44-ba73-65e0752b8b83"/>
|
||||
<textElement markup="none">
|
||||
<font size="11" isBold="true"/>
|
||||
</textElement>
|
|
@ -23,7 +23,7 @@ import org.zkoss.zul.Textbox;
|
|||
|
||||
import com.rjconsultores.ventaboletos.entidad.Empresa;
|
||||
import com.rjconsultores.ventaboletos.entidad.PuntoVenta;
|
||||
import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioAidfDetalhado;
|
||||
import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioEstoque;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.service.EmpresaService;
|
||||
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
|
||||
|
@ -91,22 +91,10 @@ public class RelatorioAidfDetalhadoController extends MyGenericForwardComposer {
|
|||
String puntoVentaIds = "";
|
||||
String puntoVentas = "";
|
||||
List<PuntoVenta> lsPuntoVentaSelecionados = new ArrayList(Arrays.asList(puntoVentaSelList.getData()));
|
||||
if (lsPuntoVentaSelecionados.isEmpty()) {
|
||||
if (puntoVentaList.getData().length == 0) {
|
||||
try {
|
||||
Messagebox.show(Labels.getLabel("relatorioAidfDetalhadoController.msg.agencia.obrigatorio"),
|
||||
Labels.getLabel("relatorioVendasBilheteiroController.window.title"),
|
||||
Messagebox.OK, Messagebox.INFORMATION);
|
||||
return;
|
||||
} catch (InterruptedException ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (lsPuntoVentaSelecionados.size() > 0) {
|
||||
for (int i = 0; i < lsPuntoVentaSelecionados.size(); i++) {
|
||||
PuntoVenta puntoVenta = lsPuntoVentaSelecionados.get(i);
|
||||
puntoVentas = puntoVentas + puntoVenta.getNombpuntoventa() + ",";
|
||||
|
||||
puntoVentaIds = puntoVentaIds + puntoVenta.getPuntoventaId() + ",";
|
||||
}
|
||||
|
||||
|
@ -114,7 +102,10 @@ public class RelatorioAidfDetalhadoController extends MyGenericForwardComposer {
|
|||
puntoVentaIds = puntoVentaIds.substring(0, puntoVentaIds.length() - 1);
|
||||
puntoVentas = puntoVentas.substring(0, puntoVentas.length() - 1);
|
||||
parametros.put("NUMPUNTOVENTA", puntoVentaIds);
|
||||
}else{
|
||||
filtro.append("Todas ");
|
||||
}
|
||||
|
||||
filtro.append(puntoVentas).append(";");
|
||||
|
||||
parametros.put("NOME_RELATORIO", Labels.getLabel("relatorioAidfDetalhadoController.window.title"));
|
||||
|
@ -130,37 +121,9 @@ public class RelatorioAidfDetalhadoController extends MyGenericForwardComposer {
|
|||
} else {
|
||||
filtro.append(" Todas; ");
|
||||
}
|
||||
filtro.append("AIDF: ");
|
||||
if(!txtAIDF.getValue().equals("")){
|
||||
parametros.put("AIDF", txtAIDF.getValue());
|
||||
filtro.append(txtAIDF.getValue() + ";");
|
||||
}else{
|
||||
filtro.append(" Todas;");
|
||||
}
|
||||
filtro.append("Inicio Form: ");
|
||||
if(!txtInicioForm.getValue().equals("")){
|
||||
parametros.put("INICIOFORM", txtInicioForm.getValue());
|
||||
filtro.append(txtInicioForm.getValue() + ";");
|
||||
}else{
|
||||
filtro.append(" Todas;");
|
||||
}
|
||||
filtro.append("Final Form: ");
|
||||
if(!txtFimForm.getValue().equals("")){
|
||||
parametros.put("FIMFORM", txtFimForm.getValue());
|
||||
filtro.append(txtFimForm.getValue() + ";");
|
||||
}else{
|
||||
filtro.append(" Todas;");
|
||||
}
|
||||
filtro.append("Serie: ");
|
||||
if(!txtSerie.getValue().equals("")){
|
||||
parametros.put("SERIE", txtSerie.getValue());
|
||||
filtro.append(txtSerie.getValue() + ";");
|
||||
}else{
|
||||
filtro.append(" Todas;");
|
||||
}
|
||||
|
||||
parametros.put("FILTROS", filtro.toString());
|
||||
relatorio = new RelatorioAidfDetalhado(parametros, dataSourceRead.getConnection());
|
||||
relatorio = new RelatorioEstoque(parametros, dataSourceRead.getConnection());
|
||||
|
||||
Map args = new HashMap();
|
||||
args.put("relatorio", relatorio);
|
||||
|
|
|
@ -273,7 +273,7 @@ indexController.mniRelatorioCancelamentoVendaCartao.label = Cancelación de vent
|
|||
indexController.mniRelatorioCancelamentoTransacao.label = Cancelamento J3
|
||||
indexController.mniRelatorioTabelaPreco.label = Reporte de tabla de precios
|
||||
indexController.mniRelatorioAIDF.label = Reporte AIDF
|
||||
indexController.mniRelatorioAIDFDetalhado.label = AIDF detallado
|
||||
indexController.mniRelatorioAIDFDetalhado.label = Reporte Estoque
|
||||
indexController.mniRelatorioSegundaVia.label = Segunda Via
|
||||
indexController.mniPrecoApanhe.label = Precio Apanhe
|
||||
indexController.mniRelatorioVendasPacotesResumido.label = Ventas de paquetes - Resumido
|
||||
|
|
|
@ -290,7 +290,7 @@ indexController.mniRelatorioEstornoCartao.label=Estorno Cartão
|
|||
indexController.mniRelatorioCancelamentoTransacao.label = Cancelamento J3
|
||||
indexController.mniRelatorioTabelaPreco.label = Tabela de Preços
|
||||
indexController.mniRelatorioAIDF.label = AIDF
|
||||
indexController.mniRelatorioAIDFDetalhado.label = AIDF Detalhado
|
||||
indexController.mniRelatorioAIDFDetalhado.label = Relatório Estoque
|
||||
indexController.mniRelatorioConsultaAntt.label= Consulta ANTT
|
||||
indexController.mniRelatorioSegundaVia.label = Segunda Via
|
||||
indexController.mniPrecoApanhe.label = Preço Apanhe
|
||||
|
@ -785,7 +785,7 @@ relatorioAidfController.lbEmpresa.value = Empresa
|
|||
relatorioAidfController.lbSerie.value = Série
|
||||
|
||||
#Relatorio Aidf Detalhado
|
||||
relatorioAidfDetalhadoController.window.title = Relatório Aidf Detalhado
|
||||
relatorioAidfDetalhadoController.window.title = Relatório Estoque
|
||||
relatorioAidfDetalhadoController.datainicial.value = Data Inicial
|
||||
relatorioAidfDetalhadoController.dataFinal.value = Data Final
|
||||
relatorioAidfDetalhadoController.lbEmpresa.value = Empresa
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<zk xmlns="http://www.zkoss.org/2005/zul">
|
||||
<window id="winFiltroRelatorioAidfDetalhado" apply="${relatorioAidfDetalhadoController}"
|
||||
contentStyle="overflow:auto"
|
||||
height="340px" width="538px" border="normal">
|
||||
height="280px" width="538px" border="normal">
|
||||
<grid fixedLayout="true">
|
||||
<columns>
|
||||
<column width="25%" />
|
||||
|
@ -16,10 +16,6 @@
|
|||
<column width="30%" />
|
||||
</columns>
|
||||
<rows>
|
||||
<row spans="1,3">
|
||||
<label value="${c:l('relatorioAidfDetalhadoController.lbAidf.value')}"/>
|
||||
<textbox id="txtAIDF" maxlength="10" width="100px" use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox"/>
|
||||
</row>
|
||||
<row spans="1,3">
|
||||
<label
|
||||
value="${c:l('relatorioAidfDetalhadoController.lbEmpresa.value')}" />
|
||||
|
@ -29,16 +25,6 @@
|
|||
model="@{winFiltroRelatorioAidfDetalhado$composer.lsEmpresa}"
|
||||
width="100%" />
|
||||
</row>
|
||||
<row spans="1,3">
|
||||
<label value="${c:l('relatorioAidfDetalhadoController.lbSerie.value')}"/>
|
||||
<textbox id="txtSerie" maxlength="10" width="100px" use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox"/>
|
||||
</row>
|
||||
<row>
|
||||
<label value="${c:l('relatorioAidfDetalhadoController.lbFormInicial.value')}"/>
|
||||
<textbox id="txtInicioForm" maxlength="10" width="100px" use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox"/>
|
||||
<label value="${c:l('relatorioAidfDetalhadoController.lbFormFinal.value')}"/>
|
||||
<textbox id="txtFimForm" maxlength="10" width="100px" use="com.rjconsultores.ventaboletos.web.utilerias.MyTextbox"/>
|
||||
</row>
|
||||
<row spans="1,3">
|
||||
<label
|
||||
value="Agencia" />
|
||||
|
@ -89,7 +75,7 @@
|
|||
label="${c:l('relatorioVendasBilheteiroController.lbEmpresa.value')}" />
|
||||
<listheader width="20%"
|
||||
label="${c:l('relatorioVendasBilheteiroController.lbNumero.value')}" />
|
||||
<listheader width="5%" />
|
||||
<listheader width="15%" />
|
||||
</listhead>
|
||||
</listbox>
|
||||
<paging id="pagingSelPuntoVenta" pageSize="10" />
|
||||
|
|
Loading…
Reference in New Issue