Num Corrida
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@22089 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
3c5310a512
commit
649ace9410
|
@ -42,6 +42,8 @@ public class EsquemaCorrida implements Serializable {
|
||||||
@Column(name = "HORASALIDA")
|
@Column(name = "HORASALIDA")
|
||||||
@Temporal(TemporalType.TIME)
|
@Temporal(TemporalType.TIME)
|
||||||
private Date horasalida;
|
private Date horasalida;
|
||||||
|
@Column(name = "NUMCORRIDA")
|
||||||
|
private Integer numCorrida;
|
||||||
@Column(name = "INDPISOEXTRA")
|
@Column(name = "INDPISOEXTRA")
|
||||||
private Boolean pisoExtra;
|
private Boolean pisoExtra;
|
||||||
@Column(name = "INDLUNES")
|
@Column(name = "INDLUNES")
|
||||||
|
@ -377,6 +379,14 @@ public class EsquemaCorrida implements Serializable {
|
||||||
this.rolOperativo2 = rolOperativo2;
|
this.rolOperativo2 = rolOperativo2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Integer getNumCorrida() {
|
||||||
|
return numCorrida;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setNumCorrida(Integer numCorrida) {
|
||||||
|
this.numCorrida = numCorrida;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
int hash = 0;
|
int hash = 0;
|
||||||
|
|
|
@ -323,6 +323,7 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
CorridaCtrl corridaCtrl = corridaCtrlService.buscar(ruta, claseServicio, marca, horario, isPisoExtra);
|
CorridaCtrl corridaCtrl = corridaCtrlService.buscar(ruta, claseServicio, marca, horario, isPisoExtra);
|
||||||
if (corridaCtrl == null) {
|
if (corridaCtrl == null) {
|
||||||
corridaCtrl = new CorridaCtrl();
|
corridaCtrl = new CorridaCtrl();
|
||||||
|
corridaCtrl.setCorridaId(esquemaCorrida.getNumCorrida());
|
||||||
corridaCtrl.setMarca(marca);
|
corridaCtrl.setMarca(marca);
|
||||||
corridaCtrl.setRuta(ruta);
|
corridaCtrl.setRuta(ruta);
|
||||||
corridaCtrl.setClaseServicio(claseServicio);
|
corridaCtrl.setClaseServicio(claseServicio);
|
||||||
|
@ -519,7 +520,7 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
Corrida corrida = generarCorrida(esquemaCorrida, dataGeracao, false);
|
Corrida corrida = generarCorrida(esquemaCorrida, dataGeracao, false);
|
||||||
Corrida corridaPisoExtra = null;
|
Corrida corridaPisoExtra = null;
|
||||||
|
|
||||||
if (corrida == null) {// Si no generó la corrida, no va a
|
if (corrida == null) {// Si no gener<EFBFBD> la corrida, no va a
|
||||||
// generar el rebote
|
// generar el rebote
|
||||||
log.info("No fue generado corrida. Esquema " + esquemaCorrida.getEsquemacorridaId() + " Data" + dataGeracao);
|
log.info("No fue generado corrida. Esquema " + esquemaCorrida.getEsquemacorridaId() + " Data" + dataGeracao);
|
||||||
continue;
|
continue;
|
||||||
|
@ -527,7 +528,7 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
|
|
||||||
// PISO EXTRA
|
// PISO EXTRA
|
||||||
if (esquemaCorrida.getPisoExtra() != null && esquemaCorrida.getPisoExtra()) {
|
if (esquemaCorrida.getPisoExtra() != null && esquemaCorrida.getPisoExtra()) {
|
||||||
// Invertendo RolOperativo e Classe de Serviço para o Piso
|
// Invertendo RolOperativo e Classe de Servi<EFBFBD>o para o Piso
|
||||||
// Extra
|
// Extra
|
||||||
RolOperativo ro = esquemaCorrida.getRolOperativo();
|
RolOperativo ro = esquemaCorrida.getRolOperativo();
|
||||||
ClaseServicio cs = esquemaCorrida.getClaseServicio();
|
ClaseServicio cs = esquemaCorrida.getClaseServicio();
|
||||||
|
@ -537,7 +538,7 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
|
|
||||||
corridaPisoExtra = generarCorrida(esquemaCorrida, dataGeracao, true);
|
corridaPisoExtra = generarCorrida(esquemaCorrida, dataGeracao, true);
|
||||||
if (corrida != null && corridaPisoExtra != null) {
|
if (corrida != null && corridaPisoExtra != null) {
|
||||||
// Voltando RolOperativo e Classe de Serviço
|
// Voltando RolOperativo e Classe de Servi<EFBFBD>o
|
||||||
esquemaCorrida.setRolOperativo(ro);
|
esquemaCorrida.setRolOperativo(ro);
|
||||||
esquemaCorrida.setClaseServicio(cs);
|
esquemaCorrida.setClaseServicio(cs);
|
||||||
|
|
||||||
|
@ -565,7 +566,7 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
if (corridaRebote != null) {
|
if (corridaRebote != null) {
|
||||||
EsquemaCorrida ecRebote = esquemaCorrida.getEsquemaCorridaRebote();
|
EsquemaCorrida ecRebote = esquemaCorrida.getEsquemaCorridaRebote();
|
||||||
if (ecRebote.getPisoExtra() != null && ecRebote.getPisoExtra()) {
|
if (ecRebote.getPisoExtra() != null && ecRebote.getPisoExtra()) {
|
||||||
// Invertendo RolOperativo e Classe de Serviço para
|
// Invertendo RolOperativo e Classe de Servi<EFBFBD>o para
|
||||||
// o Piso Extra
|
// o Piso Extra
|
||||||
RolOperativo ro = ecRebote.getRolOperativo();
|
RolOperativo ro = ecRebote.getRolOperativo();
|
||||||
ClaseServicio cs = ecRebote.getClaseServicio();
|
ClaseServicio cs = ecRebote.getClaseServicio();
|
||||||
|
@ -596,17 +597,17 @@ public class CorridaServiceImpl implements CorridaService {
|
||||||
// con una
|
// con una
|
||||||
// fechamenor tienes
|
// fechamenor tienes
|
||||||
// que generar para
|
// que generar para
|
||||||
// el día seguinte
|
// el d<EFBFBD>a seguinte
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
generaReboteDiaSeguinte = true;// si no fue encontrado
|
generaReboteDiaSeguinte = true;// si no fue encontrado
|
||||||
// para el día de
|
// para el d<EFBFBD>a de
|
||||||
// hoy,genera para
|
// hoy,genera para
|
||||||
// mañana
|
// ma<EFBFBD>ana
|
||||||
}
|
}
|
||||||
|
|
||||||
if (generaReboteDiaSeguinte) {
|
if (generaReboteDiaSeguinte) {
|
||||||
log.info("Haciendo la búsqueda por el esquema rebote para el dia seguiente pues ya existe al dia de hoy");
|
log.info("Haciendo la b<EFBFBD>squeda por el esquema rebote para el dia seguiente pues ya existe al dia de hoy");
|
||||||
|
|
||||||
corridaRebote = generarReboteDiaSeguinte(esquemaCorrida, dataGeracao);
|
corridaRebote = generarReboteDiaSeguinte(esquemaCorrida, dataGeracao);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue