From a994c4aa41d3f51e85f8c0f3dd2bb4fe4b71b166 Mon Sep 17 00:00:00 2001 From: "alexandre.lima" Date: Wed, 26 Jul 2017 19:59:40 +0000 Subject: [PATCH] Fixes Bug #0009359 git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@71926 d1611594-4594-4d17-8e1d-87c2c4800839 --- .../impl/RelatorioFinanceiroGrupoLinhas.java | 97 ++++++++++ ...orioFinanceiroGrupoLinhas_pt_BR.properties | 1 + .../RelatorioFinanceiroGrupoLinhas.jasper | Bin 0 -> 27432 bytes .../RelatorioFinanceiroGrupoLinhas.jrxml | 181 ++++++++++++++++++ .../RelatorioFormaPagamentoAgencia.jasper | Bin 32046 -> 32098 bytes .../RelatorioFormaPagamentoAgencia.jrxml | 66 +++---- .../FinanceiroGrupoLinhasController.java | 161 ++++++++++++++++ ...temMenuRelatorioFinanceiroGrupoLinhas.java | 25 +++ .../utilerias/menu/menu_original.properties | 3 +- web/WEB-INF/i3-label_pt_BR.label | 9 + 10 files changed, 509 insertions(+), 34 deletions(-) create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioFinanceiroGrupoLinhas.java create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioFinanceiroGrupoLinhas_pt_BR.properties create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jasper create mode 100644 src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jrxml create mode 100644 src/java/com/rjconsultores/ventaboletos/web/gui/controladores/financeiro/FinanceiroGrupoLinhasController.java create mode 100644 src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioFinanceiroGrupoLinhas.java diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioFinanceiroGrupoLinhas.java b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioFinanceiroGrupoLinhas.java new file mode 100644 index 000000000..3e0c92351 --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/impl/RelatorioFinanceiroGrupoLinhas.java @@ -0,0 +1,97 @@ +/** + * + */ +package com.rjconsultores.ventaboletos.relatorios.impl; + +import java.sql.Connection; +import java.sql.ResultSet; +import java.text.SimpleDateFormat; +import java.util.Date; +import java.util.HashMap; +import java.util.Map; + +import com.rjconsultores.ventaboletos.relatorios.utilitarios.ArrayDataSource; +import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement; + +/** + * @author Thiago + * + */ +public class RelatorioFinanceiroGrupoLinhas extends RelatorioDemandas { + public RelatorioFinanceiroGrupoLinhas(Map parametros, Connection conexao) throws Exception { + super(parametros, conexao); + this.setCustomDataSource(new ArrayDataSource(this) { + @Override + public void initDados() throws Exception { + SimpleDateFormat format = new SimpleDateFormat("dd/MM/yyyy"); + Connection conexao = this.relatorio.getConexao(); + Map parametros = this.relatorio.getParametros(); + + Date dataIncial = (Date) parametros.get("DATA_INICIAL"); + + Date dataFinal = (Date) parametros.get("DATA_FINAL"); + + Integer empresa = (Integer) parametros.get("EMPRESA"); + + Integer agencia = (Integer) parametros.get("AGENCIA"); + + Boolean somenteCancelados = (Boolean) parametros.get("SOMENTE_CANCELADOS"); + + StringBuilder where = new StringBuilder(); + where.append(" WHERE 1 = 1 "); + + if (dataIncial != null) { + where.append(" AND caja.fechorventa >= to_date('" + format.format(dataIncial) + "','dd/MM/yyyy') "); + } + + if (dataFinal != null) { + where.append(" AND caja.fechorventa <= to_date('" + format.format(dataFinal) + "','dd/MM/yyyy') "); + } + + if (empresa != null) { + where.append(" AND caja.EMPRESAPUNTOVENTA_ID = " + empresa + " "); + } + + if (agencia != null) { + where.append(" AND pv.PUNTOVENTA_ID = " + agencia + " "); + } + + if (somenteCancelados) { + where.append(" AND caja.MOTIVOCANCELACION_ID is not null "); + } + + StringBuilder sql = new StringBuilder(); + sql.append(" select to_date(caja.FECHORVENTA, 'dd/MM/yyyy') as FECHORVENTA,MC.DESCMOTIVO,pv.NOMBPUNTOVENTA,EMPRESA.NOMBEMPRESA,gr.DESCGRUPO,sum(caja.PRECIOPAGADO) as PRECIOPAGADO "); + sql.append(" from caja join ruta on caja.RUTA_ID = ruta.RUTA_ID "); + sql.append(" join grupo_ruta gr on ruta.GRUPORUTA_ID = gr.GRUPORUTA_ID "); + sql.append(" join PUNTO_VENTA pv on pv.PUNTOVENTA_ID = caja.PUNTOVENTA_ID "); + sql.append(" join MARCA on caja.MARCA_ID = MARCA.MARCA_ID "); + sql.append(" join EMPRESA on EMPRESA.EMPRESA_ID = MARCA.EMPRESA_ID "); + sql.append(" LEFT JOIN MOTIVO_CANCELACION MC ON MC.MOTIVOCANCELACION_ID = caja.MOTIVOCANCELACION_ID "); + sql.append(where); + sql.append(" group by to_date(caja.FECHORVENTA, 'dd/MM/yyyy'),MC.DESCMOTIVO,pv.NOMBPUNTOVENTA,EMPRESA.NOMBEMPRESA,gr.DESCGRUPO "); + sql.append(" order by pv.NOMBPUNTOVENTA, to_date(caja.FECHORVENTA,'dd/MM/yyyy') "); + + NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql.toString()); + + ResultSet rset = stmt.executeQuery(); + + while (rset.next()) { + Map dataResult = new HashMap(); + + dataResult.put("FECHORVENTA", format.format(rset.getDate("FECHORVENTA"))); + dataResult.put("DESCMOTIVO", rset.getString("DESCMOTIVO")); + dataResult.put("NOMBPUNTOVENTA", rset.getString("NOMBPUNTOVENTA")); + dataResult.put("NOMBEMPRESA", rset.getString("NOMBEMPRESA")); + dataResult.put("DESCGRUPO", rset.getString("DESCGRUPO")); + dataResult.put("NOMBEMPRESA", rset.getString("NOMBEMPRESA")); + dataResult.put("PRECIOPAGADO", rset.getDouble("PRECIOPAGADO")); + + this.dados.add(dataResult); + } + + this.resultSet = rset; + } + }); + } +} diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioFinanceiroGrupoLinhas_pt_BR.properties b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioFinanceiroGrupoLinhas_pt_BR.properties new file mode 100644 index 000000000..4c7dfdb6a --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/internacionalizacao/RelatorioFinanceiroGrupoLinhas_pt_BR.properties @@ -0,0 +1 @@ +msg.noData=Năo foi possivel obter dados com os parâmetros informados. \ No newline at end of file diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jasper b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jasper new file mode 100644 index 0000000000000000000000000000000000000000..7f7097aab22a06158f31ea57f26b3e4d6cddbc29 GIT binary patch literal 27432 zcmd^ndz>6qmH(-Ec4j)0$>d1_A@VZMnLG&30O^_O$#l~5pt~m_6JhAgR5DF^x|{Br zWCAP@L0pY!Twxaw1tq$ufNOXwxPc(JE-L8avWUu0S3rKk=i@HFMStp#-}l^mtLj#F zrMu%_`}yo7eXHu+*SY7Od(OG%o~rxarussjmSjw;y|AY=JRGQo3{$>W@c9^ zW43P+z?cA%`1|0?HB=j==F#j#E|oUBlUCBAxzQ_}j|}vW3`M#l6x@-utn5TzGLJzPe1T+5A42!$I=YgjjEJ z)3RuWTo{v9Dvfo-cn5fqOk!rmf{0QJ7Kg=*maCrC3AWo4kg(A`wgV#_~e5VccX% zGE9(B@mxA(h0^KlUUMu;v&0NC^5Lmm-YgV^99UL%yqjWfS6gxZ7OSBaCtFR%sFBM4X4csNa>9b zq?kOLx;0qMqvNUcSRQ#cj$)}tQw1TTOs$?pE6QRB@@b{dpUPp@XR!`$=O)`j`FwI8 zw>!1}MT=H|ZWJIX0kh;obh9cTqhos42E;4et+_iaXFE>P{O1pB;N3T2Y%P#Ojjv%f-jzE74~gJ+fHaIpq^z3qyX z2!f;vo!K;O6dl{nY&LBsGmLGj5CJBsQAS|}#+WJ$j_nLj>@dg1%rOO=0U-w4b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&W}FA}B22$Fdg(VtoZiA>e8;$y{tFnt{y&b;o^;8ARsFI3h z)RSTv^`uw^Pa4apykoM=`&45XkeKz9G8!mtG-3bSOjE`T+K-97(U^_R-yAwaSpw1tf$`@7tp&# zh~76kjT)oJm~Lz|T8+)dLL+J{G6s#M#>K`8W5_t$*kYV#3>#qt{`Nw0#Er`V88a?5 z(qNgl{^zpHe={j#OoC7`Q2f#9i!7>kmWgZ2~JO-9|0xa_+ zSmr6P%+p|*XTdVhfo1*~Eb}~A<^{0Ki(r|Tz%oAp%e(@X`6XE9e?ua|>b7XM->CpT U%2_V7$T>FI1YgdmI^4+re`H48PXGV_ literal 0 HcmV?d00001 diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jrxml b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jrxml new file mode 100644 index 000000000..c3813f08d --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFinanceiroGrupoLinhas.jrxml @@ -0,0 +1,181 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + <band height="62" splitType="Stretch"> + <staticText> + <reportElement uuid="7f9cea32-d0e7-4c05-9efc-233cdd5137ab" x="0" y="39" width="66" height="20"/> + <textElement> + <font isBold="true"/> + </textElement> + <text><![CDATA[PERÍODO:]]></text> + </staticText> + <staticText> + <reportElement uuid="367cee8b-2874-4078-b9c4-90285e81ec06" x="0" y="0" width="802" height="20"/> + <textElement textAlignment="Center"> + <font size="14" isBold="true"/> + </textElement> + <text><![CDATA[RelatĂłrio Financeiro por Grupo de Linhas]]></text> + </staticText> + <staticText> + <reportElement uuid="c45a1ecd-8b5e-4bd7-9139-56e0844cea7e" x="127" y="39" width="10" height="20"/> + <textElement> + <font isBold="true"/> + </textElement> + <text><![CDATA[ - ]]></text> + </staticText> + <textField pattern="dd/MM/yyyy"> + <reportElement uuid="07dfa225-148c-4de6-a428-3c91f83c4081" x="67" y="39" width="60" height="20"/> + <textElement/> + <textFieldExpression><![CDATA[$P{DATA_INICIAL}]]></textFieldExpression> + </textField> + <textField pattern="dd/MM/yyyy"> + <reportElement uuid="3948e59f-21d8-47c8-8077-a57af30605c5" x="137" y="39" width="60" height="20"/> + <textElement/> + <textFieldExpression><![CDATA[$P{DATA_FINAL}]]></textFieldExpression> + </textField> + </band> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jasper b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jasper index 3b8d9ded506b27140781fc5efafa85380e5cd9af..a7e233ea3d60908601e5ce74cf94a66a19eb0010 100644 GIT binary patch delta 4576 zcmb7|ZERCj7{~8z*HPFQ8|_%TbzLhR12?+9?2TYqCJ<;Dd*5ITfk_4gc^PBAd>D)P z0U~D$$sUViq8gjG#c`7sNyZ6FkrJoZEFhCo$ZFXa9Tu z=eg(ioOAE#xqS3czx7c6WYVf@@mtpQR+d{bFTNt@LAvF6jUViatC)2;rr6(0=CK>D z0(RKxVmtiJ>^C}+v`L-gG)Vy8MJe=QX z@g{oyFyCc?d+oyh`axpoQ}jnJ_9rCoFGNz&pD;KqqHi#;``CekO3Oe3;m3kxgh4>S zFrYvn7ZHR61d<8_VMquA9KpthT|Ublfl-$<3P%9}!x04nxriVnAdplb2tz_R!V&Cj zywGcDNsL6kJ9#8d0tSZT3Jh`)LrB0NslX71gmD~4;!k%mo7+BzU3a-yq$nBU6hL4Y zQb3T45JCb3Nd<&3B#0q|$n_MmfsXkIvCWeVaTXvjoKZlKix5Hr1W5&iFeHdG01>b8 zexO@)J|lK`F|&sref8+KdH%I(&uU9*eP07ShA{;^xd<;Lz>`$K3qyh*`*iW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5?9@uY-+VjHvwu1+yY~7|srinF@;H!rB+BoT6 zb1nCq9L=k_>W|EnA6Oo>-2~+rZlH3iO_XZ^opJ(DxmY79zhO{5UQ)ilBcMK-Jk`;l zj<;VNI(df6^{Zo4CCnzQ^iGJ>hN^3WHK7%eNbLiWNV0C_kIpIf6~UT7FkryCUTJi( X=!)!du~l1FJyO5%$;8_AYc~G}Y=aag diff --git a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jrxml b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jrxml index e10313bd5..08a6330f2 100644 --- a/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jrxml +++ b/src/java/com/rjconsultores/ventaboletos/relatorios/templates/RelatorioFormaPagamentoAgencia.jrxml @@ -1,8 +1,8 @@ - - - + + + @@ -36,9 +36,9 @@ - <band height="102" splitType="Stretch"> + <band height="68" splitType="Stretch"> <staticText> - <reportElement uuid="7f9cea32-d0e7-4c05-9efc-233cdd5137ab" x="1" y="39" width="51" height="20"/> + <reportElement uuid="7f9cea32-d0e7-4c05-9efc-233cdd5137ab" x="1" y="39" width="65" height="20"/> <textElement> <font isBold="true"/> </textElement> @@ -52,91 +52,91 @@ <text><![CDATA[RelatĂłrio de Forma de Pagamento por AgĂȘncia]]></text> </staticText> <staticText> - <reportElement uuid="c45a1ecd-8b5e-4bd7-9139-56e0844cea7e" x="165" y="39" width="10" height="20"/> + <reportElement uuid="c45a1ecd-8b5e-4bd7-9139-56e0844cea7e" x="125" y="39" width="10" height="20"/> <textElement> <font isBold="true"/> </textElement> <text><![CDATA[ - ]]></text> </staticText> <textField pattern="dd/MM/yyyy"> - <reportElement uuid="07dfa225-148c-4de6-a428-3c91f83c4081" x="80" y="39" width="85" height="20"/> + <reportElement uuid="07dfa225-148c-4de6-a428-3c91f83c4081" x="66" y="39" width="59" height="20"/> <textElement/> <textFieldExpression><![CDATA[$P{DATA_INICIAL}]]></textFieldExpression> </textField> <textField pattern="dd/MM/yyyy"> - <reportElement uuid="3948e59f-21d8-47c8-8077-a57af30605c5" x="175" y="39" width="100" height="20"/> + <reportElement uuid="3948e59f-21d8-47c8-8077-a57af30605c5" x="135" y="39" width="63" height="20"/> <textElement/> <textFieldExpression><![CDATA[$P{DATA_FINAL}]]></textFieldExpression> </textField> </band> - + - + - + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - + @@ -149,7 +149,7 @@ - + @@ -159,7 +159,7 @@ - + @@ -190,7 +190,7 @@ - + @@ -198,21 +198,21 @@ - - + + - + - + diff --git a/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/financeiro/FinanceiroGrupoLinhasController.java b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/financeiro/FinanceiroGrupoLinhasController.java new file mode 100644 index 000000000..0b4f947ed --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/gui/controladores/financeiro/FinanceiroGrupoLinhasController.java @@ -0,0 +1,161 @@ +/* + * To change this template, choose Tools | Templates + * and open the template in the editor. + */ +package com.rjconsultores.ventaboletos.web.gui.controladores.financeiro; + +import java.util.Date; +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.zk.ui.Component; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zul.Checkbox; +import org.zkoss.zul.Datebox; + +import com.rjconsultores.ventaboletos.entidad.PuntoVenta; +import com.rjconsultores.ventaboletos.entidad.Empresa; +import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioFinanceiroGrupoLinhas; +import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioFormaPagamentoAgencia; +import com.rjconsultores.ventaboletos.service.FormaPagamentoAgenciaService; +import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado; +import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar; +import com.rjconsultores.ventaboletos.web.utilerias.MyComboboxPuntoVenta; +import com.rjconsultores.ventaboletos.web.utilerias.MyGenericForwardComposer; + +/** + * + * @author Administrador + */ +@Controller("financeiroGrupoLinhasController") +@Scope("prototype") +public class FinanceiroGrupoLinhasController extends MyGenericForwardComposer { + + @Autowired + private FormaPagamentoAgenciaService financeiroService; + + @Autowired + private DataSource dataSourceRead; + + private Datebox fecInicio; + private Datebox fecFinal; + private Checkbox somenteCancelados; + + private MyComboboxEstandar cmbEmpresa; + private List lsEmpresas; + + private MyComboboxPuntoVenta cmbAgencia; + + @Override + public void doAfterCompose(Component comp) throws Exception { + + lsEmpresas = UsuarioLogado.getUsuarioLogado().getEmpresa(); + + super.doAfterCompose(comp); + } + + + public Checkbox getSomenteCancelados() { + return somenteCancelados; + } + + + public void setSomenteCancelados(Checkbox somenteCancelados) { + this.somenteCancelados = somenteCancelados; + } + + + public MyComboboxPuntoVenta getCmbAgencia() { + return cmbAgencia; + } + + + public void setCmbAgencia(MyComboboxPuntoVenta cmbAgencia) { + this.cmbAgencia = cmbAgencia; + } + + + public FormaPagamentoAgenciaService getFinanceiroService() { + return financeiroService; + } + + public void setFinanceiroService(FormaPagamentoAgenciaService financeiroService) { + this.financeiroService = financeiroService; + } + + public DataSource getDataSourceRead() { + return dataSourceRead; + } + + public void setDataSourceRead(DataSource dataSourceRead) { + this.dataSourceRead = dataSourceRead; + } + + public MyComboboxEstandar getCmbEmpresa() { + return cmbEmpresa; + } + + public void setCmbEmpresa(MyComboboxEstandar cmbEmpresa) { + this.cmbEmpresa = cmbEmpresa; + } + + public List getLsEmpresas() { + return lsEmpresas; + } + + public void setLsEmpresas(List lsEmpresas) { + this.lsEmpresas = lsEmpresas; + } + + public Datebox getFecFinal() { + return fecFinal; + } + + public void setFecFinal(Datebox fecFinal) { + this.fecFinal = fecFinal; + } + + public Datebox getFecInicio() { + return fecInicio; + } + + public void setFecInicio(Datebox fecInicio) { + this.fecInicio = fecInicio; + } + + public void onClick$btnInforme(Event e) throws Exception { + Date dataInicio = fecInicio.getValue(); + Date dataFinal = fecFinal.getValue(); + + Map argsInforme = new HashMap(); + argsInforme.put("DATA_INICIAL", dataInicio); + argsInforme.put("DATA_FINAL", dataFinal); + argsInforme.put("SOMENTE_CANCELADOS", somenteCancelados.isChecked()); + + if (cmbEmpresa.isValid() && cmbEmpresa.getSelectedItem() != null) { + Integer empresaId = ((Empresa)cmbEmpresa.getSelectedItem().getValue()).getEmpresaId(); + argsInforme.put("EMPRESA", empresaId); + } + + if (cmbAgencia.getSelectedItem() != null) { + Integer agencia = ((PuntoVenta) cmbAgencia.getSelectedItem().getValue()).getPuntoventaId(); + argsInforme.put("AGENCIA", agencia); + } + + RelatorioFinanceiroGrupoLinhas relatorio = new RelatorioFinanceiroGrupoLinhas(argsInforme, dataSourceRead.getConnection()); + + Map args = new HashMap(); + args.put("relatorio", relatorio); + + openWindow("/component/reportView.zul", + Labels.getLabel("financeiroGrupoLinhasController.window.title"), args, MODAL); + + } +} diff --git a/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioFinanceiroGrupoLinhas.java b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioFinanceiroGrupoLinhas.java new file mode 100644 index 000000000..5204567ac --- /dev/null +++ b/src/java/com/rjconsultores/ventaboletos/web/utilerias/menu/item/relatorios/ItemMenuRelatorioFinanceiroGrupoLinhas.java @@ -0,0 +1,25 @@ +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 ItemMenuRelatorioFinanceiroGrupoLinhas extends DefaultItemMenuSistema { + + public ItemMenuRelatorioFinanceiroGrupoLinhas() { + super("financeiroGrupoLinhasController.mniRelatorioFinanceiro.label"); + } + + @Override + public String getClaveMenu() { + return "COM.RJCONSULTORES.ADMINISTRACION.GUI.RELATORIOS.MENU.RELATORIOFINANCEIROGRUPOLINHASCONTROLLER"; + } + + @Override + public void ejecutar() { + PantallaUtileria.openWindow("/gui/informes/formaPagamentoAgencia/financeiroGrupoLinhas.zul", + Labels.getLabel("financeiroGrupoLinhasController.mniRelatorioFinanceiro.label"), getArgs(), desktop); + } + +} \ No newline at end of file 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 41c3229b9..05964d445 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 @@ -170,7 +170,8 @@ analitico.gerenciais.financeiro.relatorioFinanceiroReceitasDespesas=com.rjconsul analitico.gerenciais.financeiro.relatorioDepositos=com.rjconsultores.ventaboletos.web.utilerias.menu.item.contacorrente.ItemMenuRelatorioDepositos analitico.gerenciais.financeiro.relatorioDepositosDetalhados=com.rjconsultores.ventaboletos.web.utilerias.menu.item.contacorrente.ItemMenuRelatorioDepositosDetalhados analitico.gerenciais.financeiro.relatorioPosicaoCaixaAnalitico=com.rjconsultores.ventaboletos.web.utilerias.menu.item.contacorrente.ItemMenuRelatorioPosicaoCaixaAnalitico -analitico.gerenciais.financeiro.relatorioPosicaoCaixaAnalitico=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioFormaPagamentoAgencia +analitico.gerenciais.financeiro.relatorioFormaPagamentoAgencia=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioFormaPagamentoAgencia +analitico.gerenciais.financeiro.relatorioFinanceiroGrupoLinhas=com.rjconsultores.ventaboletos.web.utilerias.menu.item.relatorios.ItemMenuRelatorioFinanceiroGrupoLinhas 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_pt_BR.label b/web/WEB-INF/i3-label_pt_BR.label index d4fa6667b..364b1e589 100644 --- a/web/WEB-INF/i3-label_pt_BR.label +++ b/web/WEB-INF/i3-label_pt_BR.label @@ -374,6 +374,15 @@ formaPagamentoAgenciaController.lbDataIni.value = Data InĂ­cio formaPagamentoAgenciaController.lbDataFin.value = Data Fim formaPagamentoAgenciaController.lbEmpresa.value = Empresa +# RelatĂłrio Financeiro por Grupo de Linhas +financeiroGrupoLinhasController.mniRelatorioFinanceiro.label = Financeiro por Grupo de Linhas +financeiroGrupoLinhasController.window.title = Financeiro por Grupo de Linhas +financeiroGrupoLinhasController.lbAgencia.value = AgĂȘncia +financeiroGrupoLinhasController.lbDataIni.value = Data InĂ­cio +financeiroGrupoLinhasController.lbDataFin.value = Data Fim +financeiroGrupoLinhasController.lbEmpresa.value = Empresa +financeiroGrupoLinhasController.label.somenteCancelados = Somente Cancelados + # Muestra a Pesquisa Tipo Classe busquedaClaseServicioController.window.title = Tipo de Classe busquedaClaseServicioController.btnRefresh.tooltiptext = Atualizar