fixes bug#20486
dev:valdir qua: git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@104193 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
6dadffaa65
commit
e13be9b031
|
@ -104,6 +104,10 @@ public class RelatorioLinhasHorarioController extends MyGenericForwardComposer {
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.debug(e.getMessage());
|
log.debug(e.getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!verificarFiltrosRelatorio()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
parametros.put("TIPOSERVICIO_ID", tipoServico);
|
parametros.put("TIPOSERVICIO_ID", tipoServico);
|
||||||
|
|
||||||
|
@ -113,13 +117,13 @@ public class RelatorioLinhasHorarioController extends MyGenericForwardComposer {
|
||||||
parametros.put("DATA_INICIO", dataInicio);
|
parametros.put("DATA_INICIO", dataInicio);
|
||||||
parametros.put("DATA_FINAL", dataFinal);
|
parametros.put("DATA_FINAL", dataFinal);
|
||||||
|
|
||||||
Empresa empresa = null;
|
if(cmbEmpresa.getSelectedItem() != null && cmbEmpresa.getSelectedItem().getValue() != null) {
|
||||||
try {
|
Empresa empresa = (Empresa) cmbEmpresa.getSelectedItem().getValue();
|
||||||
empresa = (Empresa) cmbEmpresa.getSelectedItem().getValue();
|
parametros.put("EMPRESA", empresa);
|
||||||
} catch (Exception e) {
|
parametros.put("NOMBEMPRESA", empresa.getNombempresa());
|
||||||
log.debug(e.getMessage());
|
} else {
|
||||||
|
parametros.put("NOMBEMPRESA", "TODOS");
|
||||||
}
|
}
|
||||||
parametros.put("EMPRESA", empresa);
|
|
||||||
|
|
||||||
GrupoRuta grupoRuta = null;
|
GrupoRuta grupoRuta = null;
|
||||||
try {
|
try {
|
||||||
|
@ -135,11 +139,6 @@ public class RelatorioLinhasHorarioController extends MyGenericForwardComposer {
|
||||||
parametros.put("DESCGRUPO", "TODOS");
|
parametros.put("DESCGRUPO", "TODOS");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empresa != null) {
|
|
||||||
parametros.put("NOMBEMPRESA", empresa.getNombempresa());
|
|
||||||
} else {
|
|
||||||
parametros.put("NOMBEMPRESA", "TODOS");
|
|
||||||
}
|
|
||||||
|
|
||||||
lsNumLinha = new ArrayList(Arrays.asList(linhaListSelList.getData()));
|
lsNumLinha = new ArrayList(Arrays.asList(linhaListSelList.getData()));
|
||||||
lsNumServico = new ArrayList(Arrays.asList(servicoListSelList.getData()));
|
lsNumServico = new ArrayList(Arrays.asList(servicoListSelList.getData()));
|
||||||
|
@ -157,6 +156,17 @@ public class RelatorioLinhasHorarioController extends MyGenericForwardComposer {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean verificarFiltrosRelatorio() throws InterruptedException {
|
||||||
|
cmbEmpresa.getValue();
|
||||||
|
if(cmbEmpresa.getSelectedItem() == null || cmbEmpresa.getSelectedItem().getValue() == null) {
|
||||||
|
Messagebox.show(Labels.getLabel("MSG.Error.empresa.naoinformado"),
|
||||||
|
Labels.getLabel("relatorioLinhasHorarioController.window.title"),
|
||||||
|
Messagebox.OK, Messagebox.EXCLAMATION);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
public void onClick$btnExecutarRelatorio(Event ev) throws Exception {
|
public void onClick$btnExecutarRelatorio(Event ev) throws Exception {
|
||||||
executarRelatorio();
|
executarRelatorio();
|
||||||
}
|
}
|
||||||
|
|
|
@ -190,7 +190,8 @@
|
||||||
<combobox id="cmbEmpresa"
|
<combobox id="cmbEmpresa"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyComboboxEstandar"
|
||||||
mold="rounded" buttonVisible="true" width="100%"
|
mold="rounded" buttonVisible="true" width="100%"
|
||||||
model="@{winFiltroRelatorioLinhasHorario$composer.lsEmpresa}" />
|
model="@{winFiltroRelatorioLinhasHorario$composer.lsEmpresa}"
|
||||||
|
constraint="no empty" />
|
||||||
|
|
||||||
</row>
|
</row>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue