OCD - Relatório de perfil restrito com as OCD's não resgatadas (por empresa) (fixed bug #5432)

git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@36280 d1611594-4594-4d17-8e1d-87c2c4800839
master
leonardo 2014-06-30 15:02:06 +00:00
parent 152b848ce6
commit 0e1702e876
10 changed files with 708 additions and 0 deletions

View File

@ -0,0 +1,110 @@
package com.rjconsultores.ventaboletos.relatorios.impl;
import java.sql.Connection;
import java.sql.ResultSet;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.DataSource;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.RelatorioOCDBean;
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
public class RelatorioOCDNaoResgatadaEmpresa extends Relatorio {
private List<RelatorioOCDBean> lsDadosRelatorio;
public RelatorioOCDNaoResgatadaEmpresa(Map<String, Object> parametros, Connection conexao) throws Exception {
super(parametros, conexao);
this.setCustomDataSource(new DataSource(this) {
@Override
public void initDados() throws Exception {
Connection conexao = this.relatorio.getConexao();
Map<String, Object> parametros = this.relatorio.getParametros();
String fecInicio = parametros.get("fecInicio").toString() + " 00:00:00";
String fecFinal = parametros.get("fecFinal").toString() + " 23:59:59";
Integer empresaId = parametros.get("empresa") != null ? Integer.parseInt(parametros.get("empresa").toString()) : null;
String sql = getSql(fecInicio, fecFinal, empresaId);
NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql);
ResultSet rset = null;
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy hh:mm:ss");
stmt.setDate("fecInicio", new java.sql.Date(sdf.parse(fecInicio).getTime()));
stmt.setDate("fecFinal", new java.sql.Date(sdf.parse(fecFinal).getTime()));
if (empresaId != null){
stmt.setInt("empresaId", empresaId);
}
rset = stmt.executeQuery();
lsDadosRelatorio = new ArrayList<RelatorioOCDBean>();
while (rset.next()) {
RelatorioOCDBean ocdBean = new RelatorioOCDBean();
ocdBean.setBoletoId(rset.getLong("boleto_Id"));
ocdBean.setFecinc(rset.getDate("fecinc"));
ocdBean.setFecpagar(rset.getDate("fecpagar"));
ocdBean.setFecpago(rset.getDate("fecpago"));
ocdBean.setIndpago(rset.getBoolean("indpago"));
ocdBean.setEmpresa(rset.getString("nombempresa"));
ocdBean.setNombpuntoventa(rset.getString("nombpuntoventa") != null ? rset.getString("nombpuntoventa") : "");
ocdBean.setNombpuntoventapago(rset.getString("nombpuntoventapago") != null ? rset.getString("nombpuntoventapago") : "");
ocdBean.setNombusuario(rset.getString("nombusuario") != null ? rset.getString("nombusuario") : "");
ocdBean.setNombusuarioinc(rset.getString("nombusuarioinc") != null ? rset.getString("nombusuarioinc") : "");
ocdBean.setNombusuariopago(rset.getString("nombusuariopago") != null ? rset.getString("nombusuariopago") : "");
ocdBean.setNumoperacion(rset.getString("numoperacion"));
ocdBean.setPenalizacion(rset.getBigDecimal("penalizacion"));
ocdBean.setValorPagar(rset.getBigDecimal("valor_Pagar"));
lsDadosRelatorio.add(ocdBean);
}
if (lsDadosRelatorio.size() > 0) {
setLsDadosRelatorio(lsDadosRelatorio);
}
}
});
}
public void setLsDadosRelatorio(List<RelatorioOCDBean> lsDadosRelatorio) {
this.setCollectionDataSource(new JRBeanCollectionDataSource(lsDadosRelatorio));
this.lsDadosRelatorio = lsDadosRelatorio;
}
@Override
protected void processaParametros() throws Exception {
}
private String getSql(String fecInicio, String fecFinal, Integer empresaId) {
StringBuffer sql = new StringBuffer();
sql.append("select nombempresa, o.*, ui.nombusuario nombusuarioinc, ");
sql.append("up.nombusuario nombusuariopago, u.nombusuario nombusuario, ");
sql.append("p.nombpuntoventa nombpuntoventa, pp.nombpuntoventa nombpuntoventapago ");
sql.append("from ocd o ");
sql.append("join boleto b on b.boleto_id = o.boleto_id ");
sql.append("join empresa e on b.empresacorrida_id = e.empresa_id ");
sql.append("join usuario u on u.usuario_id = o.usuario_id ");
sql.append("join usuario ui on ui.usuario_id = o.usuarioinc_id ");
sql.append("left join usuario up on up.usuario_id = o.usuariopago_id ");
sql.append("join punto_venta p on p.puntoventa_id = o.puntoventa_id ");
sql.append("left join punto_venta pp on pp.puntoventa_id = o.puntoventapago_id ");
sql.append("where o.fecpago is null and o.fecpagar between :fecInicio and :fecFinal ");
if (empresaId != null){
sql.append("and e.empresa_id = :empresaId ");
}
return sql.toString();
}
}

View File

@ -0,0 +1,32 @@
#geral
msg.noData=Não foi possivel obter dados com os parâmetros informados.
msg.a=à
#Labels header
header.periodo=Período:
header.data.hora=Data/Hora\:
header.pagina=Página\:
header.filtro=Filtro\:
header.filtro.servico=Serviço\:
header.filtro.linha=Linha\:
header.filtro.grupo=Grupo de Linhas\:
#Labels detail
detail.boletoId=Boleto
detail.nombpuntoventa=Ponto de Venda
detail.numoperacion=Num. Operação
detail.fecpagar=Data Pag.
detail.valorPagar=Vr. Pagar
detail.penalizacion=Penalização
detail.nombusuarioinc=Usuário Inc.
detail.fecinc=Data Inc.
detail.nombempresa=Empresa
detail.nombusuario=Usuário
detail.nombusuariopago=Usuário Pag.
detail.nombpuntoventapago=Ponto Venda Pag.
linhas=Linhas

View File

@ -0,0 +1,266 @@
<?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="RelatorioOCDNaoResgatadaEmpresa" pageWidth="842" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" resourceBundle="RelatorioOCDNaoResgatadaEmpresa" whenResourceMissingType="Empty" uuid="94834362-0ecc-46da-b0a2-5cdee355da3e">
<property name="ireport.zoom" value="1.0"/>
<property name="ireport.x" value="131"/>
<property name="ireport.y" value="0"/>
<parameter name="fecInicio" class="java.lang.String">
<defaultValueExpression><![CDATA[]]></defaultValueExpression>
</parameter>
<parameter name="fecFinal" class="java.lang.String"/>
<parameter name="TITULO" class="java.lang.String"/>
<queryString>
<![CDATA[]]>
</queryString>
<field name="boletoId" class="java.lang.Long"/>
<field name="nombpuntoventa" class="java.lang.String"/>
<field name="numoperacion" class="java.lang.String"/>
<field name="fecpagar" class="java.util.Date"/>
<field name="valorPagar" class="java.math.BigDecimal"/>
<field name="penalizacion" class="java.math.BigDecimal"/>
<field name="nombusuarioinc" class="java.lang.String"/>
<field name="fecinc" class="java.util.Date"/>
<field name="empresa" class="java.lang.String"/>
<field name="nombusuario" class="java.lang.String"/>
<field name="nombusuariopago" class="java.lang.String"/>
<field name="nombpuntoventapago" class="java.lang.String"/>
<group name="empresa">
<groupExpression><![CDATA[$F{empresa}]]></groupExpression>
<groupHeader>
<band height="70">
<textField>
<reportElement uuid="09306494-79f1-44dd-9eed-c39684384bbf" x="0" y="0" width="231" height="20"/>
<textElement>
<font size="10" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$F{empresa}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="e8355048-a037-4837-866b-e6cf7a3e90ed" x="175" y="51" width="61" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.numoperacion}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="edd89ef1-92d6-4b5f-b249-851532fad9df" x="335" y="51" width="52" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.penalizacion}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="73c02335-4bbe-44ba-9c73-1201ed6b3967" x="387" y="51" width="82" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.nombusuarioinc}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="d88253ec-b6d4-4e99-b677-3c1a0b273a81" x="76" y="51" width="99" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.nombpuntoventa}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="569add1e-cb73-4278-b800-fa44631527f6" x="289" y="51" width="46" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.valorPagar}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="31387dbf-1cdc-4c27-992f-2e439abea576" x="236" y="51" width="43" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.fecpagar}]]></textFieldExpression>
</textField>
<line>
<reportElement uuid="76104c33-e003-4a38-98bb-9db4d0f8636b" x="0" y="20" width="801" height="1"/>
</line>
<line>
<reportElement uuid="97639de4-d619-4f05-9b3e-e615b643b778" x="0" y="68" width="801" height="1"/>
</line>
<textField>
<reportElement uuid="12ef050d-3938-4dd6-8e82-bfeca7adaa2a" x="0" y="51" width="76" height="18"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.boletoId}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="ee67d732-f227-43e9-ae81-bf7e0148bd10" x="713" y="51" width="88" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.nombpuntoventapago}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="958109bc-c1cc-4e09-bafd-a6213b6850e9" x="537" y="51" width="85" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.nombusuario}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="a6d90199-4c64-42e7-abd2-7538664fb203" x="469" y="51" width="68" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.fecinc}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="632ff254-23c5-49d5-9745-a71991042c8c" x="622" y="51" width="91" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$R{detail.nombusuariopago}]]></textFieldExpression>
</textField>
</band>
</groupHeader>
<groupFooter>
<band height="48"/>
</groupFooter>
</group>
<background>
<band splitType="Stretch"/>
</background>
<pageHeader>
<band height="60" splitType="Stretch">
<textField>
<reportElement uuid="e5d4714c-07cc-42ff-a7a8-76d6f6d3e716" x="0" y="20" width="49" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$R{header.periodo}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="66b2d0f6-2bf1-4bc7-9ec0-a34444e04d60" x="647" y="0" width="56" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$R{header.data.hora}]]></textFieldExpression>
</textField>
<textField evaluationTime="Report">
<reportElement uuid="8ca68351-fc00-4f19-b94f-f2fd1f41964f" x="779" y="20" width="22" height="20"/>
<textElement textAlignment="Right"/>
<textFieldExpression><![CDATA[" " + $V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="be1692e9-f130-4d08-9173-6ca3e4699030" x="713" y="20" width="42" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$R{header.pagina}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="4914d9e7-6ce8-4512-b1f8-13f3b572ac50" x="49" y="20" width="182" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$P{fecInicio} + " à " + $P{fecFinal}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="652312bd-292a-424d-a234-5f157e3699c6" x="0" y="0" width="231" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$P{TITULO}]]></textFieldExpression>
</textField>
<textField pattern="dd/MM/yyyy HH:mm">
<reportElement uuid="6f671365-868e-41a6-81ee-a308d1d91e1d" x="703" y="0" width="98" height="20"/>
<textElement textAlignment="Left"/>
<textFieldExpression><![CDATA[new java.util.Date()]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="7548d623-fb6c-48d4-b8b7-504f5437a79a" x="755" y="20" width="24" height="20"/>
<textElement textAlignment="Right"/>
<textFieldExpression><![CDATA[$V{PAGE_NUMBER}+" de"]]></textFieldExpression>
</textField>
</band>
</pageHeader>
<columnHeader>
<band splitType="Stretch"/>
</columnHeader>
<detail>
<band height="26" splitType="Stretch">
<textField>
<reportElement uuid="0581d767-ed09-4cfd-aad4-47f62bec1404" x="0" y="0" width="76" height="18"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{boletoId}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="f008db4d-9791-4c96-aa15-1c9f0e73f11a" x="622" y="0" width="91" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{nombusuariopago}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="c328f3f3-1a66-4982-93b4-b0e362cb61b5" x="279" y="0" width="46" height="17"/>
<textElement textAlignment="Right" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{valorPagar}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="2f865730-6cab-430a-8964-d294773464f6" x="387" y="0" width="82" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{nombusuarioinc}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="2002ee08-18dd-478b-939a-05cd1174b364" x="469" y="0" width="68" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{fecinc}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="d4894786-20fc-45c7-8fe6-a336a8736d24" x="325" y="0" width="42" height="17"/>
<textElement textAlignment="Right" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{penalizacion}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="35602dab-1999-4ae5-a7d1-e38665a9f994" x="713" y="0" width="88" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{nombpuntoventapago}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="89eb3ac5-6fb8-4554-acaa-a9fd499cde57" x="236" y="0" width="43" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{fecpagar}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="3f2de0d3-e1e1-4c38-abe4-539529605c34" x="175" y="0" width="61" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{numoperacion}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="a1875870-b2d4-403d-abd0-2a4bc9a68e63" x="76" y="0" width="99" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{nombpuntoventa}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="2cb4de67-a11c-45d0-a0a8-24f1e9a605c1" x="537" y="0" width="85" height="17"/>
<textElement textAlignment="Left" markup="none">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{nombusuario}]]></textFieldExpression>
</textField>
</band>
</detail>
<noData>
<band height="20">
<textField>
<reportElement uuid="5a6c1b7b-2242-4cf1-b957-723b906ee620" x="0" y="0" width="803" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$R{msg.noData}]]></textFieldExpression>
</textField>
</band>
</noData>
</jasperReport>

View File

@ -0,0 +1,120 @@
package com.rjconsultores.ventaboletos.relatorios.utilitarios;
import java.math.BigDecimal;
import java.util.Date;
public class RelatorioOCDBean {
private Long ocdId;
private Long boletoId;
private String numoperacion;
private Date fecpagar;
private BigDecimal valorPagar;
private BigDecimal penalizacion;
private Date fecinc;
private Boolean indpago;
private Date fecpago;
private String empresa;
private String nombusuario;
private String nombusuarioinc;
private String nombusuariopago;
private String nombpuntoventa;
private String nombpuntoventapago;
public Long getOcdId() {
return ocdId;
}
public void setOcdId(Long ocdId) {
this.ocdId = ocdId;
}
public Long getBoletoId() {
return boletoId;
}
public void setBoletoId(Long boletoId) {
this.boletoId = boletoId;
}
public String getNumoperacion() {
return numoperacion;
}
public void setNumoperacion(String numoperacion) {
this.numoperacion = numoperacion;
}
public Date getFecpagar() {
return fecpagar;
}
public void setFecpagar(Date fecpagar) {
this.fecpagar = fecpagar;
}
public BigDecimal getValorPagar() {
return valorPagar;
}
public void setValorPagar(BigDecimal valorPagar) {
this.valorPagar = valorPagar;
}
public BigDecimal getPenalizacion() {
return penalizacion;
}
public void setPenalizacion(BigDecimal penalizacion) {
this.penalizacion = penalizacion;
}
public Date getFecinc() {
return fecinc;
}
public void setFecinc(Date fecinc) {
this.fecinc = fecinc;
}
public Boolean getIndpago() {
return indpago;
}
public void setIndpago(Boolean indpago) {
this.indpago = indpago;
}
public Date getFecpago() {
return fecpago;
}
public void setFecpago(Date fecpago) {
this.fecpago = fecpago;
}
public String getEmpresa() {
return empresa;
}
public void setEmpresa(String empresa) {
this.empresa = empresa;
}
public String getNombusuario() {
return nombusuario;
}
public void setNombusuario(String nombusuario) {
this.nombusuario = nombusuario;
}
public String getNombusuarioinc() {
return nombusuarioinc;
}
public void setNombusuarioinc(String nombusuarioinc) {
this.nombusuarioinc = nombusuarioinc;
}
public String getNombusuariopago() {
return nombusuariopago;
}
public void setNombusuariopago(String nombusuariopago) {
this.nombusuariopago = nombusuariopago;
}
public String getNombpuntoventa() {
return nombpuntoventa;
}
public void setNombpuntoventa(String nombpuntoventa) {
this.nombpuntoventa = nombpuntoventa;
}
public String getNombpuntoventapago() {
return nombpuntoventapago;
}
public void setNombpuntoventapago(String nombpuntoventapago) {
this.nombpuntoventapago = nombpuntoventapago;
}
}

View File

@ -0,0 +1,93 @@
package com.rjconsultores.ventaboletos.web.gui.controladores.relatorios;
import java.text.SimpleDateFormat;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.sql.DataSource;
import org.apache.log4j.Logger;
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.Combobox;
import org.zkoss.zul.Datebox;
import com.rjconsultores.ventaboletos.entidad.Empresa;
import com.rjconsultores.ventaboletos.relatorios.impl.RelatorioOCDNaoResgatadaEmpresa;
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
import com.rjconsultores.ventaboletos.service.EmpresaService;
import com.rjconsultores.ventaboletos.web.utilerias.MyGenericForwardComposer;
@Controller("relatorioOCDController")
@Scope("prototype")
public class RelatorioOCDController extends MyGenericForwardComposer {
private static final long serialVersionUID = 1L;
private static Logger log = Logger.getLogger(RelatorioOCDController.class);
@Autowired
private DataSource dataSource;
@Autowired
private EmpresaService empresaService;
private Datebox datInicial;
private Datebox datFinal;
private Combobox cmbEmpresa;
private List<Empresa> lsEmpresas;
private void executarRelatorio() throws Exception {
Map<String, Object> parametros = new HashMap<String, Object>();
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy");
parametros.put("fecInicio", sdf.format(this.datInicial.getValue()));
parametros.put("fecFinal", sdf.format(this.datFinal.getValue()));
if (cmbEmpresa.getSelectedIndex() != -1){
parametros.put("empresa", ((Empresa)cmbEmpresa.getSelectedItem().getValue()).getEmpresaId());
}
parametros.put("TITULO", Labels.getLabel("relatorioOCDController.window.title"));
Relatorio relatorio = new RelatorioOCDNaoResgatadaEmpresa(parametros, dataSource.getConnection());
Map<String, Object> args = new HashMap<String, Object>();
args.put("relatorio", relatorio);
openWindow("/component/reportView.zul",
Labels.getLabel("relatorioOCDController.window.title"), args, MODAL);
}
public void onClick$btnExecutarRelatorio(Event ev) throws Exception {
executarRelatorio();
}
@Override
public void doAfterCompose(Component comp) throws Exception {
lsEmpresas = empresaService.obtenerTodos();
super.doAfterCompose(comp);
}
public Combobox getCmbEmpresa() {
return cmbEmpresa;
}
public void setCmbEmpresa(Combobox cmbEmpresa) {
this.cmbEmpresa = cmbEmpresa;
}
public List<Empresa> getLsEmpresas() {
return lsEmpresas;
}
public void setLsEmpresas(List<Empresa> lsEmpresas) {
this.lsEmpresas = lsEmpresas;
}
}

View File

@ -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 ItemMenuRelatorioOCD extends DefaultItemMenuSistema {
public ItemMenuRelatorioOCD() {
super("indexController.mniRelatorioOCD.label");
}
@Override
public String getClaveMenu() {
return "COM.RJCONSULTORES.ADMINISTRACION.GUI.RELATORIOS.MENU.RELATORIOOCDNAORESGATADAS";
}
@Override
public void ejecutar() {
PantallaUtileria.openWindow("/gui/relatorios/filtroRelatorioOCD.zul",
Labels.getLabel("relatorioOCDController.window.title"), null, desktop);
}
}

View File

@ -225,6 +225,7 @@ indexController.mniRelatorioTaxasLinha.label = Reporte de tasas por linea
indexController.mniRelatorioSisdap.label=SISDAP
indexController.mniRelatorioEmpresaCorrida.label = Reporte de la Empresa Corrida
indexController.mniRelatorioEmpresaOnibus.label = Reporte de la Empresa Onibus
indexController.mniRelatorioOCD.label = Reporte OCD por la Empresa
#PARTE REALIZADA POR MANUEL
indexController.mnCortesias.label = Cortesias para empleados
@ -304,6 +305,12 @@ relatorioEmpresaOnibusController.window.title=Reporte Empresa Onibus
relatorioEmpresaOnibusController.lbDataIni.value=Fecha Inicio
relatorioEmpresaOnibusController.lbDataFin.value=Fecha Final
# Relatorio OCD Empresa
relatorioOCDController.window.title=Reporte OCD por la Empresa
relatorioOCDController.lbEmpresa.value=Empresa
relatorioOCDController.lbDataIni.value=Fecha Inicio
relatorioOCDController.lbDataFin.value=Fecha Final
#Relatorio rutas Horario
relatorioLinhasHorarioController.window.title = Reporte de rutas por horário
relatorioLinhasHorarioController.lbDataIni.value = Fecha inicial

View File

@ -229,6 +229,7 @@ indexController.mniRelatorioDevolucaoBilhetes.label = Relatório de Devolução
indexController.mniRelatorioSisdap.label=SISDAP
indexController.mniRelatorioEmpresaCorrida.label = Relatório por Empresa Corrida
indexController.mniRelatorioEmpresaOnibus.label = Relatório por Empresa Ônibus
indexController.mniRelatorioOCD.label = Relatório OCD por Empresa
#PARTE REALIZADA POR MANUEL
indexController.mnCortesias.label = Cortesias Para Funcionários
@ -310,6 +311,12 @@ relatorioEmpresaOnibusController.window.title=Relatório Empresa Ônibus
relatorioEmpresaOnibusController.lbDataIni.value=Data Inicial
relatorioEmpresaOnibusController.lbDataFin.value=Data Final
# Relatorio OCD Empresa
relatorioOCDController.window.title=Relatório OCD por Empresa
relatorioOCDController.lbEmpresa.value=Empresa
relatorioOCDController.lbDataIni.value=Data Inicial
relatorioOCDController.lbDataFin.value=Data Final
#Relatorio Linhas Horario
relatorioLinhasHorarioController.window.title = Relatório de Linhas por Horário
relatorioLinhasHorarioController.lbDataIni.value = Data Inicial

View File

@ -0,0 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<?page contentType="text/html;charset=UTF-8"?>
<?variable-resolver class="org.zkoss.zkplus.spring.DelegatingVariableResolver"?>
<?init class="org.zkoss.zkplus.databind.AnnotateDataBinderInit" arg0="winFiltroRelatorioOCD"?>
<?taglib uri="http://www.zkoss.org/dsp/web/core" prefix="c"?>
<zk xmlns="http://www.zkoss.org/2005/zul">
<window id="winFiltroRelatorioOCD"
apply="${relatorioOCDController}"
contentStyle="overflow:auto" height="264px" width="550px"
border="normal">
<grid fixedLayout="true">
<columns>
<column width="50%" />
<column width="50%" />
</columns>
<rows>
<row>
<label
value="${c:l('relatorioOCDController.lbDataIni.value')}" />
<datebox id="datInicial" width="90%"
format="dd/MM/yyyy" lenient="false" constraint="no empty"
maxlength="10" />
</row>
<row>
<label
value="${c:l('relatorioOCDController.lbDataFin.value')}" />
<datebox id="datFinal" width="90%"
format="dd/MM/yyyy" lenient="false" constraint="no empty"
maxlength="10" />
</row>
<row>
<label
value="${c:l('relatorioOCDController.lbEmpresa.value')}" />
<combobox id="cmbEmpresa" width="70%"
maxlength="60" mold="rounded" buttonVisible="true"
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
model="@{winFiltroRelatorioOCD$composer.lsEmpresas}" />
</row>
</rows>
</grid>
<toolbar>
<button id="btnExecutarRelatorio" image="/gui/img/find.png"
label="${c:l('relatorio.lb.btnExecutarRelatorio')}" />
</toolbar>
</window>
</zk>