From 610b734e6f76940bb214cc8054466e3b3fcfddd6 Mon Sep 17 00:00:00 2001 From: walace Date: Wed, 23 Dec 2020 19:50:02 +0000 Subject: [PATCH] fixes bug#20985 qua:juliane dev:fabio git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@104845 d1611594-4594-4d17-8e1d-87c2c4800839 --- .../RelatorioResumoVendaOrgaoConcedente.java | 158 +++++++ ...ioResumoVendaOrgaoConcedente_es.properties | 26 ++ ...esumoVendaOrgaoConcedente_pt_BR.properties | 26 ++ ...RelatorioResumoVendaOrgaoConcedente.jasper | Bin 0 -> 47401 bytes .../RelatorioResumoVendaOrgaoConcedente.jrxml | 386 ++++++++++++++++++ ...latorioResumoVendaOrgaoConcedenteBean.java | 97 +++++ ...oResumoVendaOrgaoConcedenteController.java | 339 +++++++++++++++ ...nuRelatorioResumoVendaOrgaoConcedente.java | 24 ++ .../utilerias/menu/menu_original.properties | 1 + web/WEB-INF/i3-label_es_MX.label | 13 + web/WEB-INF/i3-label_pt_BR.label | 16 + ...troRelatorioResumoVendaOrgaoConcedente.zul | 122 ++++++ 12 files changed, 1208 insertions(+) create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioResumoVendaOrgaoConcedente.java create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_es.properties create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_pt_BR.properties create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioResumoVendaOrgaoConcedente.jasper create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioResumoVendaOrgaoConcedente.jrxml create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioResumoVendaOrgaoConcedenteBean.java create mode 100644 src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioResumoVendaOrgaoConcedenteController.java create mode 100644 src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioResumoVendaOrgaoConcedente.java create mode 100644 web/gui/relatorios/filtroRelatorioResumoVendaOrgaoConcedente.zul diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioResumoVendaOrgaoConcedente.java b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioResumoVendaOrgaoConcedente.java new file mode 100644 index 000000000..5c7d73dff --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioResumoVendaOrgaoConcedente.java @@ -0,0 +1,158 @@ +/** + * + */ +package com.rjconsultores.ventaboletos.relatorios.impl; + +import java.math.BigDecimal; +import java.math.RoundingMode; +import java.sql.Connection; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.text.DecimalFormat; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.Map; + +import org.apache.commons.lang.StringUtils; + +import com.rjconsultores.ventaboletos.relatorios.utilitarios.ArrayDataSource; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.RelatorioResumoVendaOrgaoConcedenteBean; +import com.rjconsultores.ventaboletos.utilerias.DateUtil; +import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement; + +import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource; + +/** + * @author Wallace + * + */ +public class RelatorioResumoVendaOrgaoConcedente extends Relatorio { + + public RelatorioResumoVendaOrgaoConcedente(Map parametros, Connection conexao) throws Exception { + super(parametros, conexao); + } + + private List lsDadosRelatorio; + + @Override + protected void processaParametros() throws Exception { + + this.setCustomDataSource(new ArrayDataSource(this) { + @Override + public void initDados() throws Exception { + + Connection conexao = this.relatorio.getConexao(); + Map parametros = this.relatorio.getParametros(); + + StringBuilder sb = new StringBuilder(); + + sb.append("SELECT "); + sb.append(" CAJA.PONTOVENTA,"); + sb.append(" COALESCE(SUM(CASE WHEN CAJA.ORGAOCONCEDENTEID IN(3) THEN CAJA.IMPORTE END), 0) AS ANTT,"); + sb.append(" COALESCE(SUM(CASE WHEN CAJA.ORGAOCONCEDENTEID IN(27) THEN CAJA.IMPORTE END), 0) AS AGERBA, "); + sb.append(" COALESCE(SUM(CASE WHEN CAJA.FORMAPAGO IN(2) THEN CAJA.IMPORTE END), 0) AS CARTAO,"); + sb.append(" COALESCE(SUM(CASE WHEN CAJA.FORMAPAGO IN(1, 3) THEN CAJA.IMPORTE END), 0) AS AVISTA,"); + sb.append(" COALESCE(SUM(CAJA.IMPORTE - (CAJA.IMPORTE * COALESCE(CAJA.porcredbaseicms / 100,0))) , 0) AS VALORBASECALCULO, "); + sb.append(" SUM(CAJA.IMPORTE) AS ISENTO, "); + sb.append(" CAJA.NOMECLASSE AS NOMECLASSE, "); + sb.append(" CAJA.NOMEESTADO AS NOMEESTADO "); + sb.append("FROM "); + sb.append(" (SELECT PV.NOMBPUNTOVENTA AS PONTOVENTA,"); + sb.append(" OC.DESCORGAO AS ORGAO,"); + sb.append(" OC.ORGAOCONCEDENTE_ID AS ORGAOCONCEDENTEID,"); + sb.append(" CASE WHEN C.MOTIVOCANCELACION_ID IS NULL THEN CFP.IMPORTE ELSE 0 END AS IMPORTE, "); + sb.append(" FP.FORMAPAGO_ID AS FORMAPAGO,"); + sb.append(" EI.porcredbaseicms,"); + sb.append(" EST.NOMBESTADO AS NOMEESTADO, "); + sb.append(" CS.DESCCLASE AS NOMECLASSE "); + sb.append(" "); + sb.append(" FROM CAJA C"); + sb.append(" INNER JOIN CAJA_FORMAPAGO CFP ON (C.CAJA_ID = CFP.CAJA_ID AND CFP.ACTIVO = 1)"); + sb.append(" INNER JOIN FORMA_PAGO FP ON (FP.FORMAPAGO_ID = CFP.FORMAPAGO_ID)"); + sb.append(" INNER JOIN PUNTO_VENTA PV ON C.PUNTOVENTA_ID = PV.PUNTOVENTA_ID"); + sb.append(" INNER JOIN MARCA M ON M.MARCA_ID = C.MARCA_ID"); + sb.append(" INNER JOIN RUTA R ON (C.RUTA_ID = R.RUTA_ID)"); + sb.append(" INNER JOIN ORGAO_CONCEDENTE OC ON (R.ORGAOCONCEDENTE_ID = OC.ORGAOCONCEDENTE_ID)"); + sb.append(" INNER JOIN empresa_imposto ei on ei.empresa_id = c.empresacorrida_id"); + sb.append(" "); + sb.append(" INNER JOIN PARADA ORI ON C.ORIGEN_ID = ORI.PARADA_ID"); + sb.append(" INNER JOIN CIUDAD CO ON CO.CIUDAD_ID = ORI.CIUDAD_ID"); + sb.append(" INNER JOIN ESTADO EST ON EST.ESTADO_ID = CO.ESTADO_ID "); + sb.append(" INNER JOIN CLASE_SERVICIO CS ON (C.CLASESERVICIO_ID = CS.CLASESERVICIO_ID ) "); + sb.append(" WHERE C.ACTIVO = 1"); + sb.append(" and C.FECHORVENTA >= :DATA_INICIAL "); + sb.append(" and C.FECHORVENTA <= :DATA_FINAL "); + sb.append(" AND C.TIPOVENTA_ID <> 6"); + sb.append(" AND C.INDREIMPRESION = 0"); + + if (parametros.get("NUMPUNTOVENTA") != null && !parametros.get("NUMPUNTOVENTA").equals("-1")) { + sb.append(" and C.PUNTOVENTA_ID IN (" + parametros.get("NUMPUNTOVENTA").toString() + ")"); + } + if (parametros.get("ESTADOS_ID") != null && !parametros.get("ESTADOS_ID").equals("-1")) { + sb.append(" and EST.estado_id in (" + parametros.get("ESTADOS_ID").toString() + ")"); + } + if (parametros.get("EMPRESA_ID") != null && !parametros.get("EMPRESA_ID").equals("-1")) { + sb.append(" and M.EMPRESA_ID IN (" + parametros.get("EMPRESA_ID").toString() + ")"); + } + if (parametros.get("CLASESERVICIO_ID") != null && !parametros.get("CLASESERVICIO_ID").toString().equals("-1")) { + sb.append(" AND C.CLASESERVICIO_ID = " + parametros.get("CLASESERVICIO_ID").toString() + " "); + } + sb.append(" ) CAJA "); + sb.append(" GROUP BY CAJA.PONTOVENTA, CAJA.NOMEESTADO, CAJA.NOMECLASSE "); + sb.append(" ORDER BY CAJA.NOMEESTADO, CAJA.PONTOVENTA, CAJA.NOMECLASSE "); + + NamedParameterStatement stmt = new NamedParameterStatement(conexao, sb.toString()); + + + stmt.setTimestamp("DATA_INICIAL", new Timestamp(DateUtil.inicioFecha((Date) parametros.get("DATA_INICIAL")).getTime())); + stmt.setTimestamp("DATA_FINAL", new Timestamp(DateUtil.fimFecha((Date) parametros.get("DATA_FINAL")).getTime())); + + ResultSet rset = stmt.executeQuery(); + rset.setFetchSize(1000); + + lsDadosRelatorio = new ArrayList(); + DecimalFormat df = new DecimalFormat("0.00"); + df.setMaximumFractionDigits(2); + df.setRoundingMode(RoundingMode.DOWN); + + while (rset.next()) { + + RelatorioResumoVendaOrgaoConcedenteBean bean = new RelatorioResumoVendaOrgaoConcedenteBean(); + + bean.setAgencia(StringUtils.defaultString(rset.getString("PONTOVENTA"))); + bean.setANTT(getValor("ANTT", rset)); + bean.setAGERBA(getValor("AGERBA", rset)); + bean.setCartao(getValor("CARTAO", rset)); + bean.setAVista(getValor("AVISTA", rset)); + bean.setIsento(getValor("ISENTO", rset)); + bean.setValorBaseCalculo(getValor("VALORBASECALCULO", rset)); + bean.setNomeEstado(StringUtils.defaultString(rset.getString("NOMEESTADO"))); + bean.setNomeClasse(StringUtils.defaultString(rset.getString("NOMECLASSE"))); + + lsDadosRelatorio.add(bean); + + } + + if (lsDadosRelatorio.size() > 0) { + setLsDadosRelatorio(lsDadosRelatorio); + } + } + }); + } + + private BigDecimal getValor(String campo, ResultSet resultSet) throws SQLException { + if (resultSet.getObject(campo) == null) { + return BigDecimal.ZERO; + } + return new BigDecimal(resultSet.getString(campo)); + } + + public void setLsDadosRelatorio(List lsDadosRelatorio) { + this.setCollectionDataSource(new JRBeanCollectionDataSource(lsDadosRelatorio)); + this.lsDadosRelatorio = lsDadosRelatorio; + } + +} diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_es.properties b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_es.properties new file mode 100644 index 000000000..84c1644ce --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_es.properties @@ -0,0 +1,26 @@ +#geral +msg.noData=Não foi possivel obter dados com os parâmetros informados. + +#Labels cabeçalho +label.titulo=Relatório Resumo Venda por Órgão Concedente +label.periodoVenda=Data Venda: +label.periodoA=à +label.periodo=Período +label.dataHora=Data/Hora: +label.impressorPor=Impressor por: +label.pagina=Página +label.de=de +label.filtros=Filtros: +header.filtro.total=Total Geral: + +label.agencia=Agência +label.ANTT=ANTT +label.AGERBA=AGERBA +label.cartao=Cartão +label.avista=À Vista +label.isento=Isento +label.valorBaseCalculo=Valor Base Cálculo +label.total=Total +label.nomeEstado=Estado: +label.nomeClasse=Classe +label.totalGeral=Total Geral diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_pt_BR.properties b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_pt_BR.properties new file mode 100644 index 000000000..84c1644ce --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioResumoVendaOrgaoConcedente_pt_BR.properties @@ -0,0 +1,26 @@ +#geral +msg.noData=Não foi possivel obter dados com os parâmetros informados. + +#Labels cabeçalho +label.titulo=Relatório Resumo Venda por Órgão Concedente +label.periodoVenda=Data Venda: +label.periodoA=à +label.periodo=Período +label.dataHora=Data/Hora: +label.impressorPor=Impressor por: +label.pagina=Página +label.de=de +label.filtros=Filtros: +header.filtro.total=Total Geral: + +label.agencia=Agência +label.ANTT=ANTT +label.AGERBA=AGERBA +label.cartao=Cartão +label.avista=À Vista +label.isento=Isento +label.valorBaseCalculo=Valor Base Cálculo +label.total=Total +label.nomeEstado=Estado: +label.nomeClasse=Classe +label.totalGeral=Total Geral diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioResumoVendaOrgaoConcedente.jasper b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioResumoVendaOrgaoConcedente.jasper new file mode 100644 index 0000000000000000000000000000000000000000..893cdb3d9b62046511e28d2feb72b22bbb77afad GIT binary patch literal 47401 zcmeHw34B!5_5Z!^4apD&2w_!35D{4ucBm*g2?SntL~Lmd8=<1rMLS|m-J3SW zdorvGTQg6lV3L*z8<&+Zauwf{o>P^{(KI2-~Nj zsdCMV`j)23#z?rPWo>0+Q>4DGWldy7goQRHGnr&ZZ8U{OMyM@`?vBoiWOrvKLN%eU zrmko!s^&tEjJIXl*R$gI=FVg))(}O?XeOTQT+c?v(^ZLNG*cncRV9;|Sc)R1o4PwX zqN(k5v2BPRThAuBK}W_j?G&~u7Hx~A!kukSs$ubTb3BuXsWcH*l!$H0$cmP;A<0xc z)(M28T!6Yn4)M+HsP$m_5OpjE07%W$r;s(OpP~p(QwL{~T~2PpwzbDP>ykvl=Ivdv z8dkJ1+PY@(Ia&Bp!(T0XIw{NrY`+!8TMk9m}LMY}$sLB~>?4%Mg`vZ;Ne;b|*4T zneB;Kh8@&TLJYom#7;A~#b)(W!Ld)%q0Dp=I0t72MWdsWtOk6TqybNerkv5u}pG(&lm^_Pc~H_a*q2sJ1}y;ikoq}j1l zs}}a(sw0gKDO%Rk#n=;7ki4Vta4CZA$?`1&ttQ6oY6_t!qZmZ`%sj;=^gwt3JOx?D|@<9v2pdxq4|Fc++dF(+sKf}2GfDMv|%6q}zX zRx1;+4oK;h5Tqa;{SkI8^yb#~c%m%@m{Uj5)obEuA){hix(u6@vxY#Q7JF$=7pOjx zbZ{wUSsG5IqT4Cop3|S1aOIQHui1=8SRftW5hI3TY+Ha_m$?}4>gqZr#Y%HEk+4!~ zV1@FazY=7XV#7rFB(X{fWfCNTplD%Jb7N(5#VV9Cx8G8FD+oO=>SPl#utAy|yM&=I zLb&@P&Jf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!35FGQ>agCmPOv_pFXjb(6i- zy4l`t-EN<0-C=*xy4$|Qy2rlM`i6bI^-cRG>p}Y->)ZDI*2DJ0*7xk)*7xlvt;g)2 zSU6${xih!2X_O@586t`|?@#{(PZ5kuR|i zym6nrI(qO}5*t*>=pDW5=zf_VLy- zyVI(&lUBq|TdVDi)ok}zM?+M%*e6?;+owQ`p8-+4(|Q78`ziYzh~V?B7wikHKiC&r zdmzSNwJ)>YwlBBdwXe25wy&}F+Sl8K_6>HCeT!XU-)fJxziv;k@3be`_uA9!`|O$a zx9s`$1NI{OJN7dByLQ-q#ICV-+x7P2_ImpV_A&O4>~{Od_7?jod#n9(d%OLNeWv|C z_80A6+n3nS+n3tELkYjPZ?gYr-(&yDzTe(sKWzU6IlOK^Y5&dsiT#%Soc%UpzGuH| z{}a#;@%54YuD#dZ8(;w|5C{wn3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioResumoVendaOrgaoConcedenteBean.java b/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioResumoVendaOrgaoConcedenteBean.java new file mode 100644 index 000000000..303144307 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/utilitarios/RelatorioResumoVendaOrgaoConcedenteBean.java @@ -0,0 +1,97 @@ +package com.rjconsultores.ventaboletos.relatorios.utilitarios; + +import java.math.BigDecimal; + +public class RelatorioResumoVendaOrgaoConcedenteBean { + + private BigDecimal aVista; + private BigDecimal cartao; + private BigDecimal AGERBA; + private BigDecimal valorBaseCalculo; + private BigDecimal isento; + private BigDecimal ANTT; + private String nomeEstado; + private String agencia; + private String nomeClasse; + + public BigDecimal getAVista() { + return aVista; + } + + public void setAVista(BigDecimal aVista) { + this.aVista = aVista; + } + + public BigDecimal getCartao() { + return cartao; + } + + public void setCartao(BigDecimal cartao) { + this.cartao = cartao; + } + + public BigDecimal getAGERBA() { + return AGERBA; + } + + public void setAGERBA(BigDecimal aGERBA) { + AGERBA = aGERBA; + } + + public BigDecimal getValorBaseCalculo() { + return valorBaseCalculo; + } + + public void setValorBaseCalculo(BigDecimal valorBaseCalculo) { + this.valorBaseCalculo = valorBaseCalculo; + } + + public BigDecimal getANTT() { + return ANTT; + } + + public void setANTT(BigDecimal aNTT) { + ANTT = aNTT; + } + + public String getNomeEstado() { + return nomeEstado; + } + + public void setNomeEstado(String nomeEstado) { + this.nomeEstado = nomeEstado; + } + + public String getAgencia() { + return agencia; + } + + public void setAgencia(String agencia) { + this.agencia = agencia; + } + + public BigDecimal getIsento() { + return isento; + } + + public void setIsento(BigDecimal isento) { + this.isento = isento; + } + + public BigDecimal getaVista() { + return aVista; + } + + public void setaVista(BigDecimal aVista) { + this.aVista = aVista; + } + + public String getNomeClasse() { + return nomeClasse; + } + + public void setNomeClasse(String nomeClasse) { + this.nomeClasse = nomeClasse; + } + +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioResumoVendaOrgaoConcedenteController.java b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioResumoVendaOrgaoConcedenteController.java new file mode 100644 index 000000000..59a207390 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/relatorios/RelatorioResumoVendaOrgaoConcedenteController.java @@ -0,0 +1,339 @@ +package com.rjconsultores.ventaboletos.web.gui.controladores.relatorios; + +import java.util.ArrayList; +import java.util.Arrays; +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.util.resource.Labels; +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.Combobox; +import org.zkoss.zul.Comboitem; +import org.zkoss.zul.Datebox; +import org.zkoss.zul.Paging; +import org.zkoss.zul.Textbox; + +import com.rjconsultores.ventaboletos.entidad.ClaseServicio; +import com.rjconsultores.ventaboletos.entidad.Empresa; +import com.rjconsultores.ventaboletos.entidad.Estado; +import com.rjconsultores.ventaboletos.entidad.PuntoVenta; +import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioResumoVendaOrgaoConcedente; +import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio; +import com.rjconsultores.ventaboletos.service.ClaseServicioService; +import com.rjconsultores.ventaboletos.service.EmpresaService; +import com.rjconsultores.ventaboletos.service.EstadoService; +import com.rjconsultores.ventaboletos.utilerias.DateUtil; +import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado; +import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar; +import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandarEmpresaUsuario; +import com.rjconsultores.ventaboletos.web.utilerias.MyGenericForwardComposer; +import com.rjconsultores.ventaboletos.web.utilerias.MyListbox; +import com.rjconsultores.ventaboletos.web.utilerias.paginacion.HibernateSearchObject; +import com.rjconsultores.ventaboletos.web.utilerias.paginacion.PagedListWrapper; +import com.rjconsultores.ventaboletos.web.utilerias.render.RenderEstadoUf; +import com.rjconsultores.ventaboletos.web.utilerias.render.RenderRelatorioVendasBilheteiro; +import com.rjconsultores.ventaboletos.web.utilerias.render.RenderRelatorioVendasBilheteiroSelecionados; + +@Controller("relatorioResumoVendaOrgaoConcedenteController") +@Scope("prototype") +public class RelatorioResumoVendaOrgaoConcedenteController extends MyGenericForwardComposer { + + private static final long serialVersionUID = 1L; + + private Datebox dtInicio; + private Datebox dtFim; + private MyComboboxEstandarEmpresaUsuario cmbEmpresa; + private Combobox cmbPuntoVenta; + private MyListbox estadoList; + private MyListbox puntoVentaList; + private Textbox txtNombrePuntoVenta; + private Paging pagingPuntoVenta; + private Bandbox bbPesquisaPuntoVenta; + private List lsEmpresa; + private List lsEstado; + @Autowired + private transient PagedListWrapper plwPuntoVenta; + private MyListbox puntoVentaSelList; + @Autowired + private DataSource dataSourceRead; + @Autowired + private EmpresaService empresaService; + @Autowired + private EstadoService estadoService; + @Autowired + private ClaseServicioService claseServicioService; + private MyComboboxEstandar cmbClasseServicio; + private List lsClasseServico; + + @Override + public void doAfterCompose(Component comp) throws Exception { + lsEmpresa = empresaService.obtenerTodos(); + lsEstado = estadoService.obtenerTodos(); + super.doAfterCompose(comp); + + estadoList.setItemRenderer(new RenderEstadoUf()); + estadoList.setData(lsEstado); + puntoVentaList.setItemRenderer(new RenderRelatorioVendasBilheteiro()); + puntoVentaSelList.setItemRenderer(new RenderRelatorioVendasBilheteiroSelecionados()); + lsClasseServico = claseServicioService.obtenerTodos(); + } + + @SuppressWarnings({ "rawtypes", "unchecked" }) + private void executarRelatorio() throws Exception { + Map parametros = new HashMap(); + StringBuilder filtro = new StringBuilder(); + + filtro.append("Agência: "); + String puntoVentaIds = ""; + String puntoVentas = ""; + List lsPuntoVentaSelecionados = new ArrayList(Arrays.asList(puntoVentaSelList.getData())); + if (lsPuntoVentaSelecionados.isEmpty()) { + puntoVentas = "Todas"; + } else { + for (int i = 0; i < lsPuntoVentaSelecionados.size(); i++) { + PuntoVenta puntoVenta = lsPuntoVentaSelecionados.get(i); + puntoVentas = puntoVentas + puntoVenta.getNombpuntoventa() + ","; + + puntoVentaIds = puntoVentaIds + puntoVenta.getPuntoventaId() + ","; + } + + // removendo ultima virgula + puntoVentaIds = puntoVentaIds.substring(0, puntoVentaIds.length() - 1); + puntoVentas = puntoVentas.substring(0, puntoVentas.length() - 1); + parametros.put("NUMPUNTOVENTA", puntoVentaIds); + } + filtro.append(puntoVentas).append(";"); + + if (!validar()) { + return; + } + + if (dtInicio.getValue() != null && dtFim.getValue() != null) { + filtro.append("Data: ") + .append(DateUtil.getStringDate(dtInicio.getValue(), "dd/MM/yyyy")) + .append(" - ") + .append(DateUtil.getStringDate(dtFim.getValue(), "dd/MM/yyyy")) + .append(";"); + parametros.put("DATA_INICIAL", (java.util.Date) dtInicio.getValue()); + parametros.put("DATA_FINAL", (java.util.Date) dtFim.getValue()); + } + + + parametros.put("NOME_RELATORIO", Labels.getLabel("relatorioResumoVendaOrgaoConcedenteController.window.title")); + parametros.put("USUARIO", UsuarioLogado.getUsuarioLogado().getUsuarioId().toString()); + parametros.put("USUARIO_NOME", UsuarioLogado.getUsuarioLogado().getNombusuario()); + + filtro.append("UF: "); + String estadosIds = ""; + String UFs = ""; + List lsEstadosSelecionados = estadoList.getItensSelecionados(); + + if (!lsEstadosSelecionados.isEmpty()) { + for (int i = 0; i < lsEstadosSelecionados.size(); i++) { + Estado estado = (Estado) lsEstadosSelecionados.get(i); + UFs = UFs + estado.getCveestado() + ","; + estadosIds = estadosIds + estado.getEstadoId() + ","; + } + + estadosIds = estadosIds.substring(0, estadosIds.length() - 1); + UFs = UFs.substring(0, UFs.length() - 1); + parametros.put("ESTADOS_ID", estadosIds); + } else { + filtro.append("Todos "); + } + + filtro.append(UFs).append(";"); + + filtro.append("Empresa: "); + Comboitem itemEmpresa = cmbEmpresa.getSelectedItem(); + if (itemEmpresa != null) { + Empresa empresa = (Empresa) itemEmpresa.getValue(); + parametros.put("EMPRESA_ID", empresa.getEmpresaId()); + filtro.append(empresa.getNombempresa()).append(";"); + } else { + filtro.append(" Todas; "); + } + + Comboitem itemClasseServico = cmbClasseServicio.getSelectedItem(); + if (itemClasseServico != null) { + ClaseServicio claseServicio = (ClaseServicio) itemClasseServico.getValue(); + parametros.put("CLASESERVICIO_ID", claseServicio.getClaseservicioId()); + filtro.append(claseServicio.getDescclase()).append(";"); + } else { + filtro.append(" Todas; "); + } + + parametros.put("FILTROS", filtro.toString()); + + Relatorio relatorio = new RelatorioResumoVendaOrgaoConcedente(parametros, dataSourceRead.getConnection()); + + Map args = new HashMap(); + args.put("relatorio", relatorio); + + openWindow("/component/reportView.zul", + Labels.getLabel("relatorioBPeController.window.title"), args, MODAL); + } + + private boolean validar() { + try { + + if (dtInicio.getValue() == null || dtFim.getValue() == null) { + Messagebox.show(Labels.getLabel("relatorioBPeController.MSG.informarData"), + Labels.getLabel("relatorioBPeController.window.title"), + Messagebox.OK, Messagebox.INFORMATION); + return false; + } + + if(dtInicio.getValue().after(dtFim.getValue())){ + Messagebox.show(Labels.getLabel("relatorioBPeController.MSG.dataInicialMaiorQueFinal"), + Labels.getLabel("relatorioBPeController.window.title"), + Messagebox.OK, Messagebox.INFORMATION); + return false; + } + + + } catch (InterruptedException ex) { + return false; + } + return true; + } + + public void onClick$btnExecutarRelatorio(Event ev) throws Exception { + executarRelatorio(); + } + + private void executarPesquisa() { + HibernateSearchObject puntoVentaBusqueda = + new HibernateSearchObject(PuntoVenta.class, pagingPuntoVenta.getPageSize()); + + puntoVentaBusqueda.addFilterILike("nombpuntoventa", "%" + txtNombrePuntoVenta.getValue() + "%"); + puntoVentaBusqueda.addFilterEqual("activo", Boolean.TRUE); + + 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("relatorioVendasBilheteiroController.window.title"), + Messagebox.OK, Messagebox.INFORMATION); + } catch (InterruptedException ex) { + } + } + } + + public void onClick$btnPesquisa(Event ev) { + executarPesquisa(); + } + + public void onDoubleClick$puntoVentaSelList(Event ev) { + PuntoVenta puntoVenta = (PuntoVenta) puntoVentaSelList.getSelected(); + puntoVentaSelList.removeItem(puntoVenta); + } + + public void onDoubleClick$puntoVentaList(Event ev) { + PuntoVenta puntoVenta = (PuntoVenta) puntoVentaList.getSelected(); + puntoVentaSelList.addItemNovo(puntoVenta); + } + + public void onClick$btnLimpar(Event ev) { + puntoVentaList.setData(new ArrayList()); + + bbPesquisaPuntoVenta.setText(""); + } + public Datebox getDtInicio() { + return dtInicio; + } + + public void setDtInicio(Datebox dtInicio) { + this.dtInicio = dtInicio; + } + + public Datebox getDtFim() { + return dtFim; + } + + public void setDtFim(Datebox dtFim) { + this.dtFim = dtFim; + } + + public MyComboboxEstandar getCmbEmpresa() { + return cmbEmpresa; + } + + public void setCmbEmpresa(MyComboboxEstandarEmpresaUsuario cmbEmpresa) { + this.cmbEmpresa = cmbEmpresa; + } + + public Combobox getCmbPuntoVenta() { + return cmbPuntoVenta; + } + + public void setCmbPuntoVenta(Combobox cmbPuntoVenta) { + this.cmbPuntoVenta = cmbPuntoVenta; + } + + + public MyListbox getEstadoList() { + return estadoList; + } + + public void setEstadoList(MyListbox estadoList) { + this.estadoList = estadoList; + } + + 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 EmpresaService getEmpresaService() { + return empresaService; + } + + public void setEmpresaService(EmpresaService empresaService) { + this.empresaService = empresaService; + } + + public DataSource getDataSourceRead() { + return dataSourceRead; + } + + public void setDataSourceRead(DataSource dataSourceRead) { + this.dataSourceRead = dataSourceRead; + } + + public EstadoService getEstadoService() { + return estadoService; + } + + public void setEstadoService(EstadoService estadoService) { + this.estadoService = estadoService; + } + public List getLsClasseServico() { + return lsClasseServico; + } +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioResumoVendaOrgaoConcedente.java b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioResumoVendaOrgaoConcedente.java new file mode 100644 index 000000000..3cf06c11b --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioResumoVendaOrgaoConcedente.java @@ -0,0 +1,24 @@ +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 ItemMenuRelatorioResumoVendaOrgaoConcedente extends DefaultItemMenuSistema { + + public ItemMenuRelatorioResumoVendaOrgaoConcedente() { + super("indexController.mniRelatorioResumoVendaOrgaoConcedente.label"); + } + + @Override + public String getClaveMenu() { + return "COM.RJCONSULTORES.ADMINISTRACION.GUI.RELATORIOS.MENU.RESUMOVENDAORGAOCONCEDENTE"; + } + + @Override + public void ejecutar() { + PantallaUtileria.openWindow("/gui/relatorios/filtroRelatorioResumoVendaOrgaoConcedente.zul", Labels.getLabel("relatorioResumoVendaOrgaoConcedenteController.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 01b645fe3..4395f5230 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 @@ -220,6 +220,7 @@ analitico.gerenciais.financeiro.vendasConexao=com.rjconsultores.ventaboletos.web analitico.gerenciais.financeiro.vendasRequisicao=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioVendasRequisicao analitico.gerenciais.financeiro.aproveitamentoFinanceiro=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioAproveitamentoFinanceiro analitico.gerenciais.financeiro.relatorioOperacionalFinanceiro=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioCaixaOrgaoConcedente +analitico.gerenciais.financeiro.relatorioResumoVendaOrgaoConcedente=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioResumoVendaOrgaoConcedente 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 8f3e6a1c1..6379b789d 100644 --- a/web/WEB-INF/i3-label_es_MX.label +++ b/web/WEB-INF/i3-label_es_MX.label @@ -8242,6 +8242,19 @@ relatorioBPeController.lbAlias.value = ALIAS Origen / Destino de boletos relatorioBPeController.MSG.informarData = Favor informar data inicial e final. relatorioBPeController.MSG.dataInicialMaiorQueFinal = Data de inicio não pode ser maior do que a final. + +#Relatorio Resumo Venda por Orgao Concedente +relatorioResumoVendaOrgaoConcedenteController.window.title = Relatorio Resumo Venda por Orgao Concedente +relatorioResumoVendaOrgaoConcedenteController.lbEmpresa.value = Empresa +relatorioResumoVendaOrgaoConcedenteController.lbDtInicio.value = Data Inicio Venda +relatorioResumoVendaOrgaoConcedenteController.lbDtFim.value = Data Fim Venda +relatorioResumoVendaOrgaoConcedenteController.lbUF.value = UF +indexController.mniRelatorioResumoVendaOrgaoConcedente.label= Relatorio Resumo Venda Órgao Concedente +relatorioResumoVendaOrgaoConcedenteController.lbPuntoVenta.value=Agência +relatorioResumoVendaOrgaoConcedenteController.btnPesquisa.label=Pesquisar +relatorioResumoVendaOrgaoConcedenteController.btnLimpar.label=Limpar +relatorioResumoVendaOrgaoConcedenteController.lbClasse.value = Classe + # Dispositivo Venda Embarcada dispositivoVendaEmbarcadaController.window.title = Dispositivo Venda Embarcada editarDispositivoVendaEmbarcadaController.window.title = Cadastro de Dispositivo Venda Embarcada diff --git a/web/WEB-INF/i3-label_pt_BR.label b/web/WEB-INF/i3-label_pt_BR.label index a6043219b..5082034c4 100644 --- a/web/WEB-INF/i3-label_pt_BR.label +++ b/web/WEB-INF/i3-label_pt_BR.label @@ -8812,6 +8812,22 @@ relatorioBPeController.lbAlias.value = ALIAS Origen / Destino de boletos relatorioBPeController.MSG.informarData = Favor informar data inicial e final. relatorioBPeController.MSG.dataInicialMaiorQueFinal = Data de inicio não pode ser maior do que a final. +#Relatorio Resumo Venda por Orgao Concedente +relatorioResumoVendaOrgaoConcedenteController.window.title = Relatorio Resumo Venda por Orgao Concedente +relatorioResumoVendaOrgaoConcedenteController.lbEmpresa.value = Empresa +relatorioResumoVendaOrgaoConcedenteController.lbDtInicio.value = Data Inicio Venda +relatorioResumoVendaOrgaoConcedenteController.lbDtFim.value = Data Fim Venda +relatorioResumoVendaOrgaoConcedenteController.lbUF.value = UF +indexController.mniRelatorioResumoVendaOrgaoConcedente.label= Relatorio Resumo Venda Órgao Concedente +relatorioResumoVendaOrgaoConcedenteController.lbPuntoVenta.value=Agência +relatorioResumoVendaOrgaoConcedenteController.btnPesquisa.label=Pesquisar +relatorioResumoVendaOrgaoConcedenteController.btnLimpar.label=Limpar +relatorioResumoVendaOrgaoConcedenteController.lbClasse.value = Classe + + +relatorioResumoVendaOrgaoConcedenteController.MSG.informarData = Favor informar data inicial e final. +relatorioResumoVendaOrgaoConcedenteController.MSG.dataInicialMaiorQueFinal = Data de inicio não pode ser maior do que a final. + # Dispositivo Venda Embarcada dispositivoVendaEmbarcadaController.window.title = Dispositivo Venda Embarcada painelVendaEmbarcadaController.window.title = Painel Venda Embarcada diff --git a/web/gui/relatorios/filtroRelatorioResumoVendaOrgaoConcedente.zul b/web/gui/relatorios/filtroRelatorioResumoVendaOrgaoConcedente.zul new file mode 100644 index 000000000..db80cb11d --- /dev/null +++ b/web/gui/relatorios/filtroRelatorioResumoVendaOrgaoConcedente.zul @@ -0,0 +1,122 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + +