fixes bug#19396
dev:wallace qua: git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@101914 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
7e5ec5bb68
commit
c79ddb22fa
|
@ -2,7 +2,6 @@ package com.rjconsultores.ventaboletos.relatorios.impl;
|
|||
|
||||
import java.sql.Connection;
|
||||
import java.sql.ResultSet;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
|
@ -10,7 +9,6 @@ import java.util.Map;
|
|||
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.ArrayDataSource;
|
||||
import com.rjconsultores.ventaboletos.relatorios.utilitarios.Relatorio;
|
||||
import com.rjconsultores.ventaboletos.utilerias.DateUtil;
|
||||
import com.rjconsultores.ventaboletos.web.utilerias.NamedParameterStatement;
|
||||
|
||||
public class RelatorioMovimentoPorOrgaoConcedente extends Relatorio {
|
||||
|
@ -44,6 +42,9 @@ public class RelatorioMovimentoPorOrgaoConcedente extends Relatorio {
|
|||
stmt.setInt("tiposervicio_id", Integer.parseInt((String)parametros.get("TIPOSERVICIO_ID")));
|
||||
}
|
||||
|
||||
stmt.setDate("DATA_DE", (java.sql.Date) parametros.get("DATA_DE"));
|
||||
stmt.setDate("DATA_ATE", (java.sql.Date) parametros.get("DATA_ATE"));
|
||||
|
||||
ResultSet rset = stmt.executeQuery();
|
||||
|
||||
while (rset.next()) {
|
||||
|
@ -70,9 +71,6 @@ public class RelatorioMovimentoPorOrgaoConcedente extends Relatorio {
|
|||
}
|
||||
|
||||
private String getSql() {
|
||||
|
||||
SimpleDateFormat format = new SimpleDateFormat("dd/MM/yyyy");
|
||||
|
||||
StringBuilder sql = new StringBuilder();
|
||||
|
||||
sql.append(" WITH boletos AS ");
|
||||
|
@ -98,7 +96,7 @@ public class RelatorioMovimentoPorOrgaoConcedente extends Relatorio {
|
|||
sql.append(" INNER JOIN corrida c ");
|
||||
sql.append(" ON c.corrida_id = b.corrida_id AND b.FECCORRIDA = c.FECCORRIDA ");
|
||||
|
||||
sql.append(" WHERE b.FECCORRIDA BETWEEN to_date('" +format.format(DateUtil.inicioFecha((Date) parametros.get("DATA_DE")).getTime())+"') AND to_date('" +format.format( DateUtil.fimFecha((Date) parametros.get("DATA_ATE")).getTime())+"') ");
|
||||
sql.append(" WHERE b.FECCORRIDA BETWEEN :DATA_DE AND :DATA_ATE ");
|
||||
sql.append(" AND b.MOTIVOCANCELACION_ID IS NULL ");
|
||||
|
||||
if(parametros.get("SERVICO_ID") != null ){
|
||||
|
|
Loading…
Reference in New Issue