From 35880a821dc67d1c1b7605dbd387cf9a6c4ae053 Mon Sep 17 00:00:00 2001 From: walace Date: Fri, 1 Sep 2017 22:48:09 +0000 Subject: [PATCH] fixes bug #9388 git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@73457 d1611594-4594-4d17-8e1d-87c2c4800839 --- .../impl/RelatorioDocumentosFiscais.java | 166 ++++++++++ ...elatorioDocumentosFiscais_pt_BR.properties | 23 ++ .../RelatorioDocumentosFiscais.jasper | Bin 0 -> 38835 bytes .../RelatorioDocumentosFiscais.jrxml | 312 ++++++++++++++++++ .../RelatorioDocumentosFiscaisBean.java | 170 ++++++++++ .../RelatorioDocumentosFiscaisController.java | 195 +++++++++++ .../ItemMenuRelatorioDocumentosFiscais.java | 26 ++ .../utilerias/menu/menu_original.properties | 1 + web/WEB-INF/i3-label_es_MX.label | 12 + web/WEB-INF/i3-label_pt_BR.label | 25 +- .../filtroRelatorioDocumentosFiscais.zul | 143 ++++++++ 11 files changed, 1071 insertions(+), 2 deletions(-) create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioDocumentosFiscais.java create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioDocumentosFiscais_pt_BR.properties create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jasper create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jrxml create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioDocumentosFiscaisBean.java create mode 100644 src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioDocumentosFiscaisController.java create mode 100644 src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioDocumentosFiscais.java create mode 100644 web/gui/relatorios/filtroRelatorioDocumentosFiscais.zul diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioDocumentosFiscais.java b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioDocumentosFiscais.java new file mode 100644 index 000000000..954963101 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioDocumentosFiscais.java @@ -0,0 +1,166 @@ +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.Aidf; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.DataSource; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.RelatorioDocumentosFiscaisBean; +import com.rjconsultores.ventaboletos.utilerias.DateUtil; +import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement; + +import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource; + +public class RelatorioDocumentosFiscais extends Relatorio { + + public RelatorioDocumentosFiscais(Map parametros, Connection conexao) { + super(parametros, conexao); + } + + private List lsDadosRelatorio; + + @Override + protected void processaParametros() throws Exception { + + this.setCustomDataSource(new DataSource(this) { + @Override + public void initDados() throws Exception { + + Connection conexao = this.relatorio.getConexao(); + + Map parametros = this.relatorio.getParametros(); + + Integer empresaId = (Integer) parametros.get("EMPRESA_ID"); + String agencia = (String) parametros.get("PUNTOVENTA"); + String tipoLinha = (String) parametros.get("TIPO_LINHA"); + Aidf aidf = (Aidf) parametros.get("AIDF"); + Boolean somenteCancelado = (Boolean) parametros.get("SOMENTE_CANCELADO"); + + String sql = getSql(empresaId, agencia, somenteCancelado, tipoLinha, aidf); + + NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql); + + stmt.setTimestamp("DATA_INICIAL", (Timestamp) parametros.get("DATA_INICIAL")); + stmt.setTimestamp("DATA_FINAL", (Timestamp) parametros.get("DATA_FINAL")); + + ResultSet rset = null; + rset = stmt.executeQuery(); + + lsDadosRelatorio = new ArrayList(); + BigDecimal saldo = BigDecimal.ZERO; + BigDecimal total = BigDecimal.ZERO; + + while (rset.next()) { + + RelatorioDocumentosFiscaisBean bean = new RelatorioDocumentosFiscaisBean(); + bean.setNumAIDF((String) (rset.getObject("numAIDF") == null ? "" : rset.getObject("numAIDF"))); + bean.setFormInicial((String) rset.getObject("formInicial")); + bean.setFormFinal((String) rset.getObject("formFinal")); + bean.setSerie((String) rset.getObject("serie")); + bean.setSubSerie((String) rset.getObject("subSerie")); + bean.setValorContabil((BigDecimal) rset.getObject("valorContabil")); + bean.setValorBaseCalculo((BigDecimal) rset.getObject("valorBaseCalculo")); + bean.setValorAliquiotaICMS((BigDecimal) rset.getObject("valorAliquiotaICMS")); + bean.setValorICMS((BigDecimal) rset.getObject("valorICMS")); + bean.setOutras((BigDecimal) rset.getObject("outras")); + bean.setValorCancelado((BigDecimal) rset.getObject("valorCancelado")); + bean.setEstadoId((Integer) Integer.parseInt(rset.getObject("estadoId").toString())); + + lsDadosRelatorio.add(bean); + } + + if (lsDadosRelatorio.size() > 0) { + setLsDadosRelatorio(lsDadosRelatorio); + parametros.put("SALDO", saldo.subtract(total)); + parametros.put("TOTAL", total); + } + } + }); + + } + + public void setLsDadosRelatorio(List lsDadosRelatorio) { + this.setCollectionDataSource(new JRBeanCollectionDataSource(lsDadosRelatorio)); + this.lsDadosRelatorio = lsDadosRelatorio; + } + + private String getSql(Integer empresaId, String agencia, Boolean somenteCancelado, String tipoLinha, Aidf aidf) { + + StringBuilder sql = new StringBuilder(); + sql.append("SELECT coalesce(tabela.numAidf, '') as numAidf, "); + sql.append(" tabela.formInicial as formInicial, "); + sql.append(" tabela.formFinal as formFinal, "); + sql.append(" tabela.serie as serie, "); + sql.append(" tabela.subSerie as subSerie , "); + sql.append(" coalesce(sum(tabela.valorContabil),0) AS valorContabil, "); + sql.append(" (sum(tabela.valorContabil) - (sum(tabela.valorContabil) * tabela.redBaseCalcIcms)) AS valorBaseCalculo, "); + sql.append(" tabela.ICMS AS valorAliquiotaICMS, "); + sql.append(" (sum(tabela.valorContabil) - (sum(tabela.valorContabil) * tabela.redBaseCalcIcms)) * tabela.ICMS AS valorICMS, "); + sql.append(" sum(tabela.valorContabil) - (sum(tabela.valorContabil) - (sum(tabela.valorContabil) * tabela.redBaseCalcIcms)) AS outras, "); + sql.append(" coalesce(sum(tabela.valorCancelado),0) AS valorCancelado, "); + sql.append(" tabela.estadoId as estadoId "); + sql.append("FROM "); + sql.append(" (SELECT a.ACFISCAL AS numAidf, "); + sql.append(" a.FORMINICIAL AS formInicial, "); + sql.append(" a.FORMFINAL AS formFinal, "); + sql.append(" a.SERIE AS serie, "); + sql.append(" a.SUBSERIE AS subSerie, "); + sql.append(" c.MOTIVOCANCELACION_ID AS motivoCancelacion, "); + sql.append(" c.PRECIOBASE AS tarifa, "); + sql.append(" ed.ICMS AS ICMS, "); + sql.append(" CASE WHEN c.MOTIVOCANCELACION_ID IS NULL THEN c.PRECIOPAGADO ELSE 0 END AS valorContabil, "); + sql.append(" CASE WHEN c.MOTIVOCANCELACION_ID IS NOT NULL THEN c.PRECIOPAGADO ELSE 0 "); + sql.append(" END AS valorCancelado, "); + sql.append(" coalesce(ei.PORCREDBASEICMS / 100,0) AS redBaseCalcIcms, "); + sql.append(" ei.estado_id AS estadoId, "); + sql.append(" po.DESCPARADA AS origem, "); + sql.append(" pd.DESCPARADA AS destino, "); + sql.append(" CASE WHEN((coalesce(eos.cveestado, eo.cveestado)) = (coalesce(eds.cveestado, ed.cveestado))) then 0 else 1 end as isInterEstadual "); + sql.append(" FROM caja c "); + sql.append(" INNER JOIN aidf a ON a.aidf_id = c.aidf_id "); + sql.append(" JOIN marca m ON c.marca_id = m.marca_id "); + sql.append(" JOIN empresa e ON e.empresa_id = m.empresa_id "); + sql.append(" JOIN parada po ON po.parada_id = c.origen_id "); + sql.append(" JOIN ciudad co ON co.ciudad_id = po.ciudad_id "); + sql.append(" JOIN estado eo ON eo.estado_id = co.estado_id "); + sql.append(" JOIN parada pd ON pd.parada_id = c.destino_id "); + sql.append(" JOIN ciudad cd ON cd.ciudad_id = pd.ciudad_id "); + sql.append(" JOIN estado ed ON ed.estado_id = cd.estado_id "); + sql.append(" LEFT JOIN alias_servico s ON s.origen_id = c.origen_id "); + sql.append(" AND s.destino_id = c.destino_id "); + sql.append(" AND (s.corrida_id = c.corrida_id "); + sql.append(" OR s.corrida_id IS NULL) "); + sql.append(" AND s.ruta_id = c.ruta_id "); + sql.append(" LEFT JOIN parada pos ON pos.parada_id = s.aliasorigen_id "); + sql.append(" LEFT JOIN ciudad cos ON cos.ciudad_id = pos.ciudad_id "); + sql.append(" LEFT JOIN estado eos ON eos.estado_id = cos.estado_id "); + sql.append(" LEFT JOIN parada pds ON pds.parada_id = s.aliasdestino_id "); + sql.append(" LEFT JOIN ciudad cds ON cds.ciudad_id = pds.ciudad_id "); + sql.append(" LEFT JOIN estado eds ON eds.estado_id = cds.estado_id "); + sql.append(" INNER JOIN empresa_imposto ei ON ei.empresa_id = e.empresa_id "); + + sql.append(" WHERE c.feccreacion between :DATA_INICIAL and :DATA_FINAL "); + sql.append("AND c.EMPRESACORRIDA_ID =" + empresaId + " "); + sql.append(somenteCancelado == true ? " AND c.INDCANCELACION = 1" : " "); + sql.append("AND a.AIDF_ID = " + aidf.getAidfId() + " "); + sql.append(" AND coalesce(eos.cveestado, eo.cveestado) IN ('BA') )tabela "); + sql.append(tipoLinha.equals("INTERMUNICIPAL") ? " where tabela.isInterEstadual = 1" : tipoLinha.equals("INTERESTADUAL") ? " where tabela.isInterEstadual = 0" : " "); + sql.append("GROUP BY tabela.numAidf, "); + sql.append(" tabela.formInicial, "); + sql.append(" tabela.formFinal, "); + sql.append(" tabela.serie, "); + sql.append(" tabela.subSerie, "); + sql.append(" tabela.ICMS, "); + sql.append(" tabela.redBaseCalcIcms, "); + sql.append(" tabela.estadoId"); + + return sql.toString(); + } + +} diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioDocumentosFiscais_pt_BR.properties b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioDocumentosFiscais_pt_BR.properties new file mode 100644 index 000000000..be959e3f3 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioDocumentosFiscais_pt_BR.properties @@ -0,0 +1,23 @@ +#geral +msg.noData=Não foi possivel obter dados com os parâmetros informados. + +#Labels cabeçalho +cabecalho.nome=Relatório Documentos Fiscais +cabecalho.relatorio=Relatório +label.periodo=Período: +label.UF=UF +label.especie=Espécie +label.empresa=Empresa +label.formInicial=Nº Inicial +label.formFinal=Nº Final +label.numAIDF=AIDF +label.serie=Série +label.subSerie=SubSérie +label.valorContabil=Vlr Contábil +label.valorBaseCalculo=Vlr Base Cálc. +label.valorAliquiotaICMS=Alíquota ICMS +label.valorICMS=Valor ICMS +label.isentas=Isentas +label.outras=Outras +label.valorCancelado=Qtd. Cancec +header.data=Período diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jasper b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jasper new file mode 100644 index 0000000000000000000000000000000000000000..4ee4bb4ff53283bc0f16fe36a4004c83c50b97d5 GIT binary patch literal 38835 zcmeHw3w&Hf_5aLl+H8|e`fi~VXiI^ut_$_(oHt(ZrZeB zrMwkTl%jwN@=z41fC!bRD9THGfII}1hfoj{6chws{J&>r?!7a~&F;p2KEKcB|NH#% z$kx05~WSiWGoVo?TEC+qbtK~ynd`M z(i3g!@9c~Xq}c@Za6Ho6RoawJ#(KN(V3B?>SrLzvE^ z37l8M4s2+uT3=b;+Emq8QxA_S}e@{;&xxFsB4Ub1#*bEo6F_!Ko*xG2MBbqGh?Ql{R$5PF)bUdol)Ubkhv@@*; zEoX&^WGvbXhNE1d`eY8Vu5M60hHfN{G~wH2Kh;Pz^Uq(bfVA6t$15^w6`un z5^Uby7Y(z5wn+Pyt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AFv15N0>+w>>)miJ%VQPC?AiRooVc6{9yJZn#)ssE~Z`__8T;t-|`bM z2hze`;is~FXg;sQ=D&p|^hdsx{Ta>ZFMJo~AFgHZ^Xu71Xion?AMhVEsgL;s7=k{A zq5l&Y+&|67@aK3De~B0K-(#%(7N5x9=2Q9m7&3pzr^D4eSOoY?QOIYBVt#~}!jBXO z^7&#WUm#}lg<=6;gsq`V#d5w(9LtXt<$R^6;wOk&zFIW!N^vr;5}SFA=;Z4}jMs@Y zuNT{RlQ@Sri}U%(;xfKTT+UAw*YMNCb-Yd7!rR5Iyi44}yT$!HE*|AQ;-~yf@hne@ z=lNFg8s8?~;GYoh@w3GH{A@JcU4Z~UKTyaog=sqN{|uEfPX7ajDzbluN+>2(I%)H(N6Z37DmRs1{Fd-lC+hI=b#AM=Kd=$S2X5(JW*!=)g zYY*~+`H%S#{3n>CdWK z7K>VOv}geIWO0nxELMq5ah!;WGLgm;+eEcEN30R&ixb6VA}lV)lh=ro#C2l5xJ7Ib zw~7{V4^rJPTE(N{bn#QsA)Xac@jP;PO`IX#5WV6(kr3~T6b5POKtK!x3dPwlRPFy~ zsQ$+cRp1 zTK2ZMfqfuuWFLudav{FOM~OYWSbT?%7vJU6#2xTy_QIF>KA$V@ga2|rUm||USBW3N zZ+V!vh)3X${FFz<6YxQP$y4G<_#Myio$x_+i5K{_;y3(y@eo<2 z;=sUoF*7hh%nnQu3j$L`Y2YBSJTP4x8<-)=12aWc;BZkJI6^c8=82O7^Tp;sspt$W z6tTb(n3bhsTVRDaCvdDdKXAObEO3IjJWwI72~>*f0&B%Bff{jZpjO-ys1x@G8pWf5 zCh^n2M)7RmWbu696!BW%RPjb2BHjzMiT4AY7}a$J0)Z`o!axd!s*A>242%3H`>r9w W*QYb>Vs%&8t;5UbcD)WR`TqcsI+#WP literal 0 HcmV?d00001 diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jrxml b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jrxml new file mode 100644 index 000000000..8edbd1591 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioDocumentosFiscais.jrxml @@ -0,0 +1,312 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioDocumentosFiscaisBean.java b/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioDocumentosFiscaisBean.java new file mode 100644 index 000000000..69337a5a2 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioDocumentosFiscaisBean.java @@ -0,0 +1,170 @@ +package com.rjconsultores.ventaboletos.relatorios.utilitarios; + +import java.math.BigDecimal; + +public class RelatorioDocumentosFiscaisBean { + + private String numAIDF; + private String formInicial; + private String formFinal; + private String serie; + private String subSerie; + private BigDecimal valorContabil; + private BigDecimal valorBaseCalculo; + private BigDecimal valorAliquiotaICMS; + private BigDecimal valorICMS; + private BigDecimal outras; + private BigDecimal isentas; + private BigDecimal valorCancelado; + private String nomeEstado; + private Integer estadoId; + private String nomeOrigem; + private String nomeDestino; + private String codOrigem; + private String codDestino; + + public String getNumAIDF() { + return numAIDF; + } + + public void setNumAIDF(String numAIDF) { + this.numAIDF = numAIDF; + } + + public String getFormInicial() { + return formInicial; + } + + public void setFormInicial(String formInicial) { + this.formInicial = formInicial; + } + + public String getFormFinal() { + return formFinal; + } + + public void setFormFinal(String formFinal) { + this.formFinal = formFinal; + } + + public String getSerie() { + return serie; + } + + public void setSerie(String serie) { + this.serie = serie; + } + + public String getSubSerie() { + return subSerie; + } + + public void setSubSerie(String subSerie) { + this.subSerie = subSerie; + } + + public BigDecimal getValorContabil() { + return valorContabil; + } + + public void setValorContabil(BigDecimal valorContabil) { + this.valorContabil = valorContabil; + } + + public BigDecimal getValorBaseCalculo() { + return valorBaseCalculo; + } + + public void setValorBaseCalculo(BigDecimal valorBaseCalculo) { + this.valorBaseCalculo = valorBaseCalculo; + } + + public BigDecimal getValorICMS() { + return valorICMS; + } + + public void setValorICMS(BigDecimal valorICMS) { + this.valorICMS = valorICMS; + } + + public BigDecimal getOutras() { + return outras; + } + + public void setOutras(BigDecimal outras) { + this.outras = outras; + } + + public BigDecimal getValorCancelado() { + return valorCancelado; + } + + public void setValorCancelado(BigDecimal valorCancelado) { + this.valorCancelado = valorCancelado; + } + + public String getNomeEstado() { + return nomeEstado; + } + + public void setNomeEstado(String nomeEstado) { + this.nomeEstado = nomeEstado; + } + + public String getNomeOrigem() { + return nomeOrigem; + } + + public void setNomeOrigem(String nomeOrigem) { + this.nomeOrigem = nomeOrigem; + } + + public String getNomeDestino() { + return nomeDestino; + } + + public void setNomeDestino(String nomeDestino) { + this.nomeDestino = nomeDestino; + } + + public String getCodOrigem() { + return codOrigem; + } + + public void setCodOrigem(String codOrigem) { + this.codOrigem = codOrigem; + } + + public String getCodDestino() { + return codDestino; + } + + public void setCodDestino(String codDestino) { + this.codDestino = codDestino; + } + + public BigDecimal getValorAliquiotaICMS() { + return valorAliquiotaICMS; + } + + public void setValorAliquiotaICMS(BigDecimal valorAliquiotaICMS) { + this.valorAliquiotaICMS = valorAliquiotaICMS; + } + + public BigDecimal getIsentas() { + return isentas; + } + + public void setIsentas(BigDecimal isentas) { + this.isentas = isentas; + } + + public Integer getEstadoId() { + return estadoId; + } + + public void setEstadoId(Integer estadoId) { + this.estadoId = estadoId; + } + +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioDocumentosFiscaisController.java b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioDocumentosFiscaisController.java new file mode 100644 index 000000000..6e7dd677b --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioDocumentosFiscaisController.java @@ -0,0 +1,195 @@ +package com.rjconsultores.ventaboletos.web.gui.controladores.relatorios; + +import java.sql.Timestamp; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.sql.DataSource; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Scope; +import org.springframework.stereotype.Controller; +import org.zkoss.lang.Objects; +import org.zkoss.util.resource.Labels; +import org.zkoss.zk.ui.Component; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zkplus.databind.BindingListModelList; +import org.zkoss.zul.Checkbox; +import org.zkoss.zul.Comboitem; +import org.zkoss.zul.ComboitemRenderer; +import org.zkoss.zul.Datebox; +import org.zkoss.zul.Radio; +import org.zkoss.zul.Radiogroup; + +import com.rjconsultores.ventaboletos.entidad.Aidf; +import com.rjconsultores.ventaboletos.entidad.Empresa; +import com.rjconsultores.ventaboletos.entidad.Estado; +import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioDocumentosFiscais; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio; +import com.rjconsultores.ventaboletos.service.AidfService; +import com.rjconsultores.ventaboletos.service.EmpresaService; +import com.rjconsultores.ventaboletos.service.EstadoService; +import com.rjconsultores.ventaboletos.utilerias.DateUtil; +import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar; +import com.rjconsultores.ventaboletos.web.utilerias.MyGenericForwardComposer; +import com.rjconsultores.ventaboletos.web.utilerias.MyListbox; +import com.rjconsultores.ventaboletos.web.utilerias.render.RenderEstadoUf; + +@Controller("relatorioDocumentosFiscaisController") +@Scope("prototype") +public class RelatorioDocumentosFiscaisController extends MyGenericForwardComposer { + + /** + * + */ + private static final long serialVersionUID = 1L; + private static final String TODOS_VALUE = new Integer(-1).toString(); + private static final String TODOS = "TODAS"; + @Autowired + private EmpresaService empresaService; + @Autowired + private EstadoService estadoService; + private List lsEmpresa; + private List lsEstado; + private MyComboboxEstandar cmbEmpresa; + private MyComboboxEstandar cmbEstado; + private MyComboboxEstandar cmbAidf; + private Datebox datInicial; + private Datebox datFinal; + @Autowired + private DataSource dataSourceRead; + private List aidfList; + private Checkbox ckbSomenteCancelado; + private Radiogroup rdgInterestadualMunicial; + @Autowired + private AidfService aidfService; + private List lsAidf; + + @Override + public void doAfterCompose(Component comp) throws Exception { + super.doAfterCompose(comp); + lsEmpresa = empresaService.obtenerTodos(); + lsEstado = estadoService.obtenerTodos(); + } + + @SuppressWarnings({ "rawtypes", "unchecked" }) + private void executarRelatorio() throws Exception { + Relatorio relatorio; + + Map parametros = new HashMap(); + + Timestamp dataInicio = new Timestamp((DateUtil.inicioFecha((java.util.Date) this.datInicial.getValue()).getTime())); + Timestamp dataFinal = new Timestamp((DateUtil.fimFecha((java.util.Date) this.datFinal.getValue()).getTime())); + + parametros.put("DATA_INICIAL", dataInicio); + parametros.put("DATA_FINAL", dataFinal); + + Empresa empresa = (Empresa) cmbEmpresa.getSelectedItem().getValue(); + Aidf aidf = (Aidf) cmbAidf.getSelectedItem().getValue(); + Boolean somenteCancelado = ckbSomenteCancelado.isChecked(); + + Radio radio = rdgInterestadualMunicial.getSelectedItem(); + String tipoLinha; + if (radio.getValue().equals("1")) { + tipoLinha = "INTERMUNICIPAL"; + } + if (radio.getValue().equals("2")) { + tipoLinha = "INTERESTADUAL"; + } else { + tipoLinha = "TODOS"; + } + + parametros.put("AIDF", aidf); + parametros.put("TIPO_LINHA", tipoLinha); + parametros.put("SOMENTE_CANCELADO", somenteCancelado); + if (empresa != null) { + parametros.put("EMPRESA", empresa.getNombempresa()); + parametros.put("EMPRESA_ID", empresa.getEmpresaId()); + } else { + parametros.put("EMPRESA", "TODOS"); + } + parametros.put("TITULO", Labels.getLabel("relatorioDocumentosFiscaisController.window.title")); + + relatorio = new RelatorioDocumentosFiscais(parametros, dataSourceRead.getConnection()); + + Map args = new HashMap(); + args.put("relatorio", relatorio); + + openWindow("/component/reportView.zul", + Labels.getLabel("relatorioDocumentosFiscaisController.window.title"), args, MODAL); + } + + private void buscaAidf() { + Empresa empresa = null; + Estado estado = null; + + Comboitem itemEmpresa = cmbEmpresa.getSelectedItem(); + Comboitem itemEstado = cmbEstado.getSelectedItem(); + + if (itemEmpresa != null) { + empresa = (Empresa) itemEmpresa.getValue(); + } + if (itemEstado != null) { + estado = (Estado) itemEstado.getValue(); + } + + if (itemEmpresa != null && itemEstado != null) { + lsAidf = aidfService.buscaAidfRMD(empresa.getEmpresaId(), estado.getEstadoId()); + + ComboitemRenderer aidfRenderer = new ComboitemRenderer() { + public void render(Comboitem item, Object data) { + if (data instanceof Aidf) { + Aidf aidf = (Aidf) data; + item.setLabel(aidf.getDocfiscal() + " = " + aidf.getForminicial() + "-" + aidf.getFormfinal()); + } else { + item.setLabel(Objects.toString(data)); + } + item.setValue(data); + } + }; + cmbAidf.setItemRenderer(aidfRenderer); + cmbAidf.setModel(new BindingListModelList(lsAidf, true)); + } + } + + public void onClick$btnExecutarRelatorio(Event ev) throws Exception { + executarRelatorio(); + } + + public void onSelect$cmbEstado(Event ev) { + buscaAidf(); + } + + public List getLsEmpresa() { + return lsEmpresa; + } + + public void setLsEmpresa(List lsEmpresa) { + this.lsEmpresa = lsEmpresa; + } + + public List getLsEstado() { + return lsEstado; + } + + public void setLsEstado(List lsEstado) { + this.lsEstado = lsEstado; + } + + public List getLsAidf() { + return lsAidf; + } + + public void setLsAidf(List lsAidf) { + this.lsAidf = lsAidf; + } + + public List getAidfList() { + return aidfList; + } + + public void setAidfList(List aidfList) { + this.aidfList = aidfList; + } +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioDocumentosFiscais.java b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioDocumentosFiscais.java new file mode 100644 index 000000000..046b0566e --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioDocumentosFiscais.java @@ -0,0 +1,26 @@ + +package com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios; + +import org.zkoss.util.resource.Labels; + +import com.rjconsultores.ventaboletos.web.utilerias.PantallaUtileria; +import com.rjconsultores.ventaboletos.web.utilerias.menu.DefaultItemMenuSistema; + +public class ItemMenuRelatorioDocumentosFiscais extends DefaultItemMenuSistema { + + public ItemMenuRelatorioDocumentosFiscais() { + super("indexController.mniRelatorioDocumentosFiscais.label"); + } + + @Override + public String getClaveMenu() { + return "COM.RJCONSULTORES.ADMINISTRACION.GUI.RELATORIOS.MENU.RELATORIODOCUMENTOSFISCAIS"; + } + + @Override + public void ejecutar() { + PantallaUtileria.openWindow("/gui/relatorios/filtroRelatorioDocumentosFiscais.zul", + Labels.getLabel("relatorioRemarcacaoPassagensTransferenciaController.window.title"), getArgs(), desktop); + } + +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/menu_original.properties b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/menu_original.properties index 1e0241774..e4c972919 100644 --- a/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/menu_original.properties +++ b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/menu_original.properties @@ -180,6 +180,7 @@ analitico.gerenciais.financeiro.relatorioFormaPagamentoAgencia=com.rjconsultores analitico.gerenciais.financeiro.relatorioFinanceiroGrupoLinhas=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioFinanceiroGrupoLinhas analitico.gerenciais.financeiro.relatorioVendasPTA=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioVendasPTA analitico.gerenciais.financeiro.relatorioServicoBloqueadoVendaInternet=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioServicoBloqueadoVendaInternet +analitico.gerenciais.financeiro.relatorioDocumentosFiscais=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioDocumentosFiscais analitico.gerenciais.pacote=com.rjconsultores.ventaboletos.web.utilerias.menu.item.analitico.gerenciais.pacote.SubMenuRelatorioPacote analitico.gerenciais.pacote.boletos=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioVendasPacotesBoletos analitico.gerenciais.pacote.detalhado=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioVendasPacotesDetalhado diff --git a/web/WEB-INF/i3-label_es_MX.label b/web/WEB-INF/i3-label_es_MX.label index dbe717108..3ecbafcdb 100644 --- a/web/WEB-INF/i3-label_es_MX.label +++ b/web/WEB-INF/i3-label_es_MX.label @@ -288,6 +288,7 @@ indexController.mniRelatorioObservacaoConferenciaMovimento.label = Observación indexController.mniRelatorioErrosIntegracaoBGMController.label = Listar errores BGM indexController.mniRelatorioVendasPTAController.label = Ventas PTA indexController.mniRelatorioServicoBloqueadoVendaInternet.label = Corrida bloqueada en venta internet +indexController.mniRelatorioDocumentosFiscais.label = Report Documentos Fiscais indexController.mnSubMenuImpressaoFiscal.label=Impresión fiscal indexController.mnSubMenuRelatorioImpressaoFiscal.label=Importación fiscal @@ -706,6 +707,17 @@ relatorioServicoBloqueadoVendaInternetController.lbDatFinal.value = Fecha final relatorioServicoBloqueadoVendaInternetController.lbEmpresa.value = Empresa relatorioServicoBloqueadoVendaInternetController.lbAgencia.value = Agencia +#Relatório Documentos Fiscais +relatorioDocumentosFiscaisController.window.title = Reporte Documentos Fiscais +relatorioDocumentosFiscaisController.lbDatInicial.value = Fecha Inicial +relatorioDocumentosFiscaisController.lbDatFinal.value = Fecha Final +relatorioDocumentosFiscaisController.lbEmpresa.value = Empresa +relatorioDocumentosFiscaisController.lbAgencia.value = Punto Venta +relatorioDocumentosFiscaisController.lbEspecie.label = Especies +relatorioDocumentosFiscaisController.lbAgruparPor.label = Agrupar por: +relatorioDocumentosFiscaisController.lbInterestadual.label = Interés +relatorioDocumentosFiscaisController.lbIntermunicipal.label = Intermunicipal + #Relatorio Tripulacao relatorioTripulacao.label=Informe Tripulación relatorioTripulacaoController.lbDataInicial=Fecha Inicial diff --git a/web/WEB-INF/i3-label_pt_BR.label b/web/WEB-INF/i3-label_pt_BR.label index d21ab058e..80d10ba22 100644 --- a/web/WEB-INF/i3-label_pt_BR.label +++ b/web/WEB-INF/i3-label_pt_BR.label @@ -305,6 +305,7 @@ indexController.mniRelatorioObservacaoConferenciaMovimento.label = Movimentos co indexController.mniRelatorioErrosIntegracaoBGMController.label = Listar Erros BGM indexController.mniRelatorioVendasPTA.label = Vendas PTA indexController.mniRelatorioServicoBloqueadoVendaInternet.label = Serviço Bloqueado na Venda Internet +indexController.mniRelatorioDocumentosFiscais.label = Relatório Documentos Fiscais indexController.mnSubMenuImpressaoFiscal.label=Impressão Fiscal indexController.mnSubMenuRelatorioImpressaoFiscal.label=Importação Fiscal @@ -774,8 +775,7 @@ relatorioAidfDetalhadoController.window.title = Relatório Aidf Detalhado relatorioAidfDetalhadoController.datainicial.value = Data Inicial relatorioAidfDetalhadoController.dataFinal.value = Data Final relatorioAidfDetalhadoController.lbEmpresa.value = Empresa -relatorioAidfDetalhadoController.lbSerie.value = Série -relatorioAidfDetalhadoController.lbAidf.value = AIDF +relatorioAidfDetalhadoController.lbAidf.value = AIDF/Série/SubSerie relatorioAidfDetalhadoController.lbFormInicial.value = Form. Inicial relatorioAidfDetalhadoController.lbFormFinal.value = Form. Final relatorioAidfDetalhadoController.msg.agencia.obrigatorio = Uma Agência deve ser selecionada @@ -793,6 +793,27 @@ relatorioVendasPTAController.btnLimpar.label = Limpar Seleção relatorioVendasPTAController.puntoVentaSelList.codigo = Código relatorioVendasPTAController.puntoVentaSelList.nome = Nome +#Relatório Documentos Fiscais +relatorioDocumentosFiscaisController.window.title = Relatório Documentos Fiscais +relatorioDocumentosFiscaisController.lbDatInicial.value = Data Inicial +relatorioDocumentosFiscaisController.lbDatFinal.value = Data Final +relatorioDocumentosFiscaisController.lbEmpresa.value = Empresa +relatorioDocumentosFiscaisController.lbAgencia.value = Agência +relatorioDocumentosFiscaisController.lbEspecie.label = Espécie +relatorioDocumentosFiscaisController.lbAgruparPor.label = Agrupar por: +relatorioDocumentosFiscaisController.lbInterestadual.label = Interestadual +relatorioDocumentosFiscaisController.lbIntermunicipal.label = Intermunicipal +relatorioDocumentosFiscaisController.lbTodosIntermunicipalInterestadual.label = Todos +relatorioDocumentosFiscaisController.lbUF.label = UF +relatorioDocumentosFiscaisController.lbLocalidade.label = Localidade +relatorioDocumentosFiscaisController.lbTrazerDados.label = Trazer Dados +relatorioDocumentosFiscaisController.lbSomenteBilhetesCancelados.label = Somente Bilhetes Cancelados +relatorioDocumentosFiscaisController.lbBilhetesBPR.label = Bilhetes BPR +relatorioDocumentosFiscaisController.lbBilhetesEB.label = Excesso de Bagagem(EB) +relatorioDocumentosFiscaisController.lbAIDF.label = AIDF +relatorioDocumentosFiscaisController.lbSerie.label = Série +relatorioDocumentosFiscaisController.lbSubserie.label = Subsérie + #Relatório de Serviço Bloqueado na Venda Internet relatorioServicoBloqueadoVendaInternetController.window.title = Relatório de Serviço Bloqueado na Venda Internet relatorioServicoBloqueadoVendaInternetController.lbDatInicial.value = Data Inicial diff --git a/web/gui/relatorios/filtroRelatorioDocumentosFiscais.zul b/web/gui/relatorios/filtroRelatorioDocumentosFiscais.zul new file mode 100644 index 000000000..bbe71797e --- /dev/null +++ b/web/gui/relatorios/filtroRelatorioDocumentosFiscais.zul @@ -0,0 +1,143 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +