fixes bug#22413
fixes bug#22420 dev:wilian qua: git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@106906 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
5ab3f954c2
commit
9b330fdbb2
|
@ -9,5 +9,7 @@ public interface ConexionRutaConfDAO extends GenericDAO<ConexionRutaConf, Intege
|
||||||
List<ConexionRutaConf> buscarPorDescricao(String descricao);
|
List<ConexionRutaConf> buscarPorDescricao(String descricao);
|
||||||
|
|
||||||
List<ConexionRutaConf> obtenerTodosActivo();
|
List<ConexionRutaConf> obtenerTodosActivo();
|
||||||
|
|
||||||
|
public void excluirConfiguracao(ConexionRutaConf conexion, Integer usuarioId, boolean excluirConexionRutaConf);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,7 +6,7 @@ import com.rjconsultores.ventaboletos.entidad.ConexionRutaConf;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.vo.conexion.ConexionRutaVO;
|
import com.rjconsultores.ventaboletos.vo.conexion.ConexionRutaVO;
|
||||||
|
|
||||||
public interface ConexionRutaCtrlDAO extends GenericDAO<ConexionRutaCtrl, Integer> {
|
public interface ConexionRutaCtrlDAO extends GenericDAO<ConexionRutaCtrl, Long> {
|
||||||
|
|
||||||
List<ConexionRutaVO> buscarConexionesValidas();
|
List<ConexionRutaVO> buscarConexionesValidas();
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ import java.util.List;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
||||||
|
|
||||||
public interface ConexionRutaTramoCtrlDAO extends GenericDAO<ConexionRutaTramoCtrl, Integer> {
|
public interface ConexionRutaTramoCtrlDAO extends GenericDAO<ConexionRutaTramoCtrl, Long> {
|
||||||
|
|
||||||
boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId, Integer destinoTrechoId2);
|
boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId, Integer destinoTrechoId2);
|
||||||
|
|
||||||
|
|
|
@ -82,4 +82,6 @@ public interface RutaCombinacionDAO extends GenericDAO<RutaCombinacion, Integer>
|
||||||
public boolean existeTramo(Tramo tramo);
|
public boolean existeTramo(Tramo tramo);
|
||||||
|
|
||||||
public boolean existeTramo(Tramo tramo, ClaseServicio claseServicio);
|
public boolean existeTramo(Tramo tramo, ClaseServicio claseServicio);
|
||||||
|
|
||||||
|
boolean isRutaCombinacionVenda(Integer rutaId, Integer origenId, Integer destinoId);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,13 @@
|
||||||
package com.rjconsultores.ventaboletos.dao.hibernate;
|
package com.rjconsultores.ventaboletos.dao.hibernate;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Calendar;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.hibernate.Criteria;
|
import org.hibernate.Criteria;
|
||||||
|
import org.hibernate.Query;
|
||||||
import org.hibernate.SessionFactory;
|
import org.hibernate.SessionFactory;
|
||||||
|
import org.hibernate.criterion.MatchMode;
|
||||||
import org.hibernate.criterion.Restrictions;
|
import org.hibernate.criterion.Restrictions;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Qualifier;
|
import org.springframework.beans.factory.annotation.Qualifier;
|
||||||
|
@ -25,7 +29,7 @@ public class ConexionRutaConfHibernateDAO extends GenericHibernateDAO<ConexionRu
|
||||||
|
|
||||||
Criteria c = getSession().createCriteria(getPersistentClass());
|
Criteria c = getSession().createCriteria(getPersistentClass());
|
||||||
c.add(Restrictions.eq("activo", Boolean.TRUE));
|
c.add(Restrictions.eq("activo", Boolean.TRUE));
|
||||||
c.add(Restrictions.like("descricao", descricao));
|
c.add(Restrictions.ilike("descricao", descricao, MatchMode.ANYWHERE));
|
||||||
|
|
||||||
return c.list();
|
return c.list();
|
||||||
}
|
}
|
||||||
|
@ -37,4 +41,94 @@ public class ConexionRutaConfHibernateDAO extends GenericHibernateDAO<ConexionRu
|
||||||
return c.list();
|
return c.list();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void excluirConfiguracao(ConexionRutaConf conexion, Integer usuarioId, boolean excluirConexionRutaConf) {
|
||||||
|
List<String> comandos = carregarComandosInativarConfiguracao(excluirConexionRutaConf);
|
||||||
|
for (String comando : comandos) {
|
||||||
|
Query qr = getSession().createSQLQuery(comando);
|
||||||
|
qr.setParameter("usuarioId", usuarioId);
|
||||||
|
qr.setParameter("conexionrutaconfId", conexion.getConexionRutaConfId());
|
||||||
|
qr.setParameter("fecmodif", Calendar.getInstance().getTime());
|
||||||
|
qr.executeUpdate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<String> carregarComandosInativarConfiguracao(boolean excluirConexionRutaConf) {
|
||||||
|
List<String> comandos = new ArrayList<String>(0);
|
||||||
|
|
||||||
|
StringBuilder sb = new StringBuilder();
|
||||||
|
if(excluirConexionRutaConf) {
|
||||||
|
sb.append("update conexion_ruta_conf ")
|
||||||
|
.append("set activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ")
|
||||||
|
.append("where conexionrutaconf_id = :conexionrutaconfId");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
}
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("update conexion_ruta_ctrl ")
|
||||||
|
.append("set activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ")
|
||||||
|
.append("where conexionrutaconf_id = :conexionrutaconfId");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("update conexion_ruta_excepcion_ptovta ")
|
||||||
|
.append("set activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ")
|
||||||
|
.append("where conexionrutaconf_id = :conexionrutaconfId");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("update conexion_rutaexcepciontipopta ")
|
||||||
|
.append("set activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ")
|
||||||
|
.append("where conexionrutaconf_id = :conexionrutaconfId");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("merge into conexion_ruta_tramo_ctrl c ")
|
||||||
|
.append("using ( ")
|
||||||
|
.append("select c1.conexionrutatramoctrl_id ")
|
||||||
|
.append("from conexion_ruta_tramo_ctrl c1 ")
|
||||||
|
.append("join conexion_ruta_ctrl c2 on c1.conexionrutactrl_id = c2.conexionrutactrl_id ")
|
||||||
|
.append("where c2.conexionrutaconf_id = :conexionrutaconfId and c1.activo = 1) t on (t.conexionrutatramoctrl_id = c.conexionrutatramoctrl_id) ")
|
||||||
|
.append("when matched then update set c.activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("merge into conexion c ")
|
||||||
|
.append("using ( ")
|
||||||
|
.append("select c.conexion_id ")
|
||||||
|
.append("from conexion c ")
|
||||||
|
.append("join conexion_ruta_tramo_ctrl c1 on c.conexionrutatramoctrl_id = c1.conexionrutatramoctrl_id ")
|
||||||
|
.append("join conexion_ruta_ctrl c2 on c1.conexionrutactrl_id = c2.conexionrutactrl_id ")
|
||||||
|
.append("where c2.conexionrutaconf_id = :conexionrutaconfId and c.activo = 1) t on (t.conexion_id = c.conexion_id) ")
|
||||||
|
.append("when matched then update set c.activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("merge into conexion_ctrl c ")
|
||||||
|
.append("using ( ")
|
||||||
|
.append("select distinct c.conexionctrl_id ")
|
||||||
|
.append("from conexion_ctrl c ")
|
||||||
|
.append("join conexion c3 on c3.conexionctrl_id = c.conexionctrl_id ")
|
||||||
|
.append("join conexion_ruta_tramo_ctrl c1 on c3.conexionrutatramoctrl_id = c1.conexionrutatramoctrl_id ")
|
||||||
|
.append("join conexion_ruta_ctrl c2 on c1.conexionrutactrl_id = c2.conexionrutactrl_id ")
|
||||||
|
.append("where c2.conexionrutaconf_id = :conexionrutaconfId and c.activo = 1) t on (t.conexionctrl_id = c.conexionctrl_id) ")
|
||||||
|
.append("when matched then update set c.activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
sb = new StringBuilder();
|
||||||
|
sb.append("merge into conexion_conf c ")
|
||||||
|
.append("using ( ")
|
||||||
|
.append("select distinct c.conexionconf_id ")
|
||||||
|
.append("from conexion_conf c ")
|
||||||
|
.append("join conexion_ctrl c4 on c4.conexionctrl_id = c.conexionctrl_id ")
|
||||||
|
.append("join conexion c3 on c3.conexionctrl_id = c4.conexionctrl_id ")
|
||||||
|
.append("join conexion_ruta_tramo_ctrl c1 on c3.conexionrutatramoctrl_id = c1.conexionrutatramoctrl_id ")
|
||||||
|
.append("join conexion_ruta_ctrl c2 on c1.conexionrutactrl_id = c2.conexionrutactrl_id ")
|
||||||
|
.append("where c2.conexionrutaconf_id = :conexionrutaconfId and c.activo = 1) t on (t.conexionconf_id = c.conexionconf_id) ")
|
||||||
|
.append("when matched then update set c.activo = 0, usuario_id = :usuarioId, fecmodif = :fecmodif ");
|
||||||
|
comandos.add(sb.toString());
|
||||||
|
|
||||||
|
return comandos;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@ import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.vo.conexion.ConexionRutaVO;
|
import com.rjconsultores.ventaboletos.vo.conexion.ConexionRutaVO;
|
||||||
|
|
||||||
@Repository("conexionRutaCtrlDAO")
|
@Repository("conexionRutaCtrlDAO")
|
||||||
public class ConexionRutaCtrlHibernateDAO extends GenericHibernateDAO<ConexionRutaCtrl, Integer> implements ConexionRutaCtrlDAO {
|
public class ConexionRutaCtrlHibernateDAO extends GenericHibernateDAO<ConexionRutaCtrl, Long> implements ConexionRutaCtrlDAO {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
public ConexionRutaCtrlHibernateDAO(@Qualifier("sessionFactory") SessionFactory factory) {
|
public ConexionRutaCtrlHibernateDAO(@Qualifier("sessionFactory") SessionFactory factory) {
|
||||||
|
|
|
@ -15,7 +15,7 @@ import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
||||||
|
|
||||||
@Repository("conexionRutaTramoCtrlDAO")
|
@Repository("conexionRutaTramoCtrlDAO")
|
||||||
public class ConexionRutaTramoCtrlHibernateDAO extends GenericHibernateDAO<ConexionRutaTramoCtrl, Integer> implements ConexionRutaTramoCtrlDAO {
|
public class ConexionRutaTramoCtrlHibernateDAO extends GenericHibernateDAO<ConexionRutaTramoCtrl, Long> implements ConexionRutaTramoCtrlDAO {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
public ConexionRutaTramoCtrlHibernateDAO(@Qualifier("sessionFactory") SessionFactory factory) {
|
public ConexionRutaTramoCtrlHibernateDAO(@Qualifier("sessionFactory") SessionFactory factory) {
|
||||||
|
|
|
@ -842,4 +842,30 @@ public class RutaCombinacionHibernateDAO extends GenericHibernateDAO<RutaCombina
|
||||||
return HibernateFix.count(c.list()) > 0l;
|
return HibernateFix.count(c.list()) > 0l;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isRutaCombinacionVenda(Integer rutaId, Integer origenId, Integer destinoId) {
|
||||||
|
if(rutaId == null || origenId == null || destinoId == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
StringBuilder sQuery = new StringBuilder();
|
||||||
|
sQuery.append("select rc.rutacombinacion_id ")
|
||||||
|
.append("from ruta_combinacion rc ")
|
||||||
|
.append("join tramo t on t.tramo_id = rc.tramo_id ")
|
||||||
|
.append("where rc.activo = 1 ")
|
||||||
|
.append("and rc.indventa = 1 ")
|
||||||
|
.append("and t.activo = 1 ")
|
||||||
|
.append("and rc.ruta_id = :rutaId ")
|
||||||
|
.append("and t.origen_id = :origenId ")
|
||||||
|
.append("and t.destino_id = :destinoId ");
|
||||||
|
|
||||||
|
Query qr = getSession().createSQLQuery(sQuery.toString());
|
||||||
|
qr.setParameter("rutaId", rutaId);
|
||||||
|
qr.setParameter("origenId", origenId);
|
||||||
|
qr.setParameter("destinoId", destinoId);
|
||||||
|
|
||||||
|
return !qr.list().isEmpty();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -59,7 +59,7 @@ public class Conexion implements Serializable {
|
||||||
@Column(name = "RUTA_ID")
|
@Column(name = "RUTA_ID")
|
||||||
private Integer rutaId;
|
private Integer rutaId;
|
||||||
@Column(name = "CONEXIONRUTATRAMOCTRL_ID")
|
@Column(name = "CONEXIONRUTATRAMOCTRL_ID")
|
||||||
private Integer conexionRutaTramoId;
|
private Long conexionRutaTramoId;
|
||||||
|
|
||||||
public Long getCorridaId() {
|
public Long getCorridaId() {
|
||||||
return corridaId;
|
return corridaId;
|
||||||
|
@ -194,11 +194,11 @@ public class Conexion implements Serializable {
|
||||||
this.rutaId = rutaId;
|
this.rutaId = rutaId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getConexionRutaTramoId() {
|
public Long getConexionRutaTramoId() {
|
||||||
return conexionRutaTramoId;
|
return conexionRutaTramoId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setConexionRutaTramoId(Integer conexionRutaTramoId) {
|
public void setConexionRutaTramoId(Long conexionRutaTramoId) {
|
||||||
this.conexionRutaTramoId = conexionRutaTramoId;
|
this.conexionRutaTramoId = conexionRutaTramoId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,6 +16,7 @@ import javax.persistence.SequenceGenerator;
|
||||||
import javax.persistence.Table;
|
import javax.persistence.Table;
|
||||||
import javax.persistence.Temporal;
|
import javax.persistence.Temporal;
|
||||||
import javax.persistence.TemporalType;
|
import javax.persistence.TemporalType;
|
||||||
|
import javax.persistence.Transient;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -41,18 +42,20 @@ public class ConexionCtrl implements Serializable {
|
||||||
private Integer origenId;
|
private Integer origenId;
|
||||||
@Column(name = "DESTINO_ID")
|
@Column(name = "DESTINO_ID")
|
||||||
private Integer destinoId;
|
private Integer destinoId;
|
||||||
|
|
||||||
|
@Transient
|
||||||
|
private Integer grupos;
|
||||||
|
|
||||||
public ConexionCtrl() {
|
public ConexionCtrl() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public ConexionCtrl(Integer origenId, Integer destinoId) {
|
public ConexionCtrl(Integer origenId, Integer destinoId, Integer grupos) {
|
||||||
super();
|
this();
|
||||||
this.origenId = origenId;
|
this.origenId = origenId;
|
||||||
this.destinoId = destinoId;
|
this.destinoId = destinoId;
|
||||||
|
this.grupos = grupos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public ConexionCtrl(Long conexionctrlId) {
|
public ConexionCtrl(Long conexionctrlId) {
|
||||||
this.conexionctrlId = conexionctrlId;
|
this.conexionctrlId = conexionctrlId;
|
||||||
}
|
}
|
||||||
|
@ -128,4 +131,17 @@ public class ConexionCtrl implements Serializable {
|
||||||
public void setDestinoId(Integer destinoId) {
|
public void setDestinoId(Integer destinoId) {
|
||||||
this.destinoId = destinoId;
|
this.destinoId = destinoId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Integer getGrupos() {
|
||||||
|
return grupos;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setGrupos(Integer grupos) {
|
||||||
|
this.grupos = grupos;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isOrigemDestinoIgual(Integer origemConexaoCtrl, Integer destinoConexaoCtrl) {
|
||||||
|
return getOrigenId().equals(origemConexaoCtrl) && getDestinoId().equals(destinoConexaoCtrl);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,25 +2,18 @@ package com.rjconsultores.ventaboletos.entidad;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import javax.persistence.Basic;
|
import javax.persistence.Basic;
|
||||||
import javax.persistence.CascadeType;
|
|
||||||
import javax.persistence.Column;
|
import javax.persistence.Column;
|
||||||
import javax.persistence.Entity;
|
import javax.persistence.Entity;
|
||||||
import javax.persistence.GeneratedValue;
|
import javax.persistence.GeneratedValue;
|
||||||
import javax.persistence.GenerationType;
|
import javax.persistence.GenerationType;
|
||||||
import javax.persistence.Id;
|
import javax.persistence.Id;
|
||||||
import javax.persistence.OneToMany;
|
|
||||||
import javax.persistence.SequenceGenerator;
|
import javax.persistence.SequenceGenerator;
|
||||||
import javax.persistence.Table;
|
import javax.persistence.Table;
|
||||||
import javax.persistence.Temporal;
|
import javax.persistence.Temporal;
|
||||||
import javax.persistence.TemporalType;
|
import javax.persistence.TemporalType;
|
||||||
|
|
||||||
import org.hibernate.annotations.LazyCollection;
|
|
||||||
import org.hibernate.annotations.LazyCollectionOption;
|
|
||||||
import org.hibernate.annotations.Where;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author wallace
|
* @author wallace
|
||||||
|
@ -48,16 +41,6 @@ public class ConexionRutaConf implements Serializable {
|
||||||
private Integer tiempoMin;
|
private Integer tiempoMin;
|
||||||
@Column(name = "TIEMPOMAX")
|
@Column(name = "TIEMPOMAX")
|
||||||
private Integer tiempoMax;
|
private Integer tiempoMax;
|
||||||
@OneToMany(mappedBy = "conexionRutaConf", cascade = CascadeType.ALL)
|
|
||||||
@LazyCollection(LazyCollectionOption.FALSE)
|
|
||||||
@Where(clause = "ACTIVO=1")
|
|
||||||
private List<ConexionRutaExcepcionTipoPtoVta> conexionRutaCanalVendasList;
|
|
||||||
|
|
||||||
@OneToMany(mappedBy = "conexionRutaConf", cascade = CascadeType.ALL)
|
|
||||||
@LazyCollection(LazyCollectionOption.FALSE)
|
|
||||||
@Where(clause = "ACTIVO=1")
|
|
||||||
private List<ConexionRutaExcepcionPtoVta> conexionRutaPuntoVendaList;
|
|
||||||
|
|
||||||
|
|
||||||
public ConexionRutaConf() {
|
public ConexionRutaConf() {
|
||||||
super();
|
super();
|
||||||
|
@ -125,27 +108,11 @@ public class ConexionRutaConf implements Serializable {
|
||||||
return "ConexionRutaConf [descricao=" + descricao + "]";
|
return "ConexionRutaConf [descricao=" + descricao + "]";
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<ConexionRutaExcepcionTipoPtoVta> getConexionRutaCanalVendasList() {
|
|
||||||
return conexionRutaCanalVendasList;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setConexionRutaCanalVendasList(List<ConexionRutaExcepcionTipoPtoVta> conexionRutaCanalVendasList) {
|
|
||||||
this.conexionRutaCanalVendasList = conexionRutaCanalVendasList;
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<ConexionRutaExcepcionPtoVta> getConexionRutaPuntoVendaList() {
|
|
||||||
return conexionRutaPuntoVendaList;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setConexionRutaPuntoVendaList(List<ConexionRutaExcepcionPtoVta> conexionRutaPuntoVendaList) {
|
|
||||||
this.conexionRutaPuntoVendaList = conexionRutaPuntoVendaList;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
final int prime = 31;
|
final int prime = 31;
|
||||||
int result = 1;
|
int result = 1;
|
||||||
result = prime * result + ((conexionRutaConfId == null) ? 0 : conexionRutaConfId.hashCode());
|
result = prime * result + ((getConexionRutaConfId() == null) ? 0 : getConexionRutaConfId().hashCode());
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -155,16 +122,15 @@ public class ConexionRutaConf implements Serializable {
|
||||||
return true;
|
return true;
|
||||||
if (obj == null)
|
if (obj == null)
|
||||||
return false;
|
return false;
|
||||||
if (getClass() != obj.getClass())
|
if (!(obj instanceof ConexionRutaConf))
|
||||||
return false;
|
return false;
|
||||||
ConexionRutaConf other = (ConexionRutaConf) obj;
|
ConexionRutaConf other = (ConexionRutaConf) obj;
|
||||||
if (conexionRutaConfId == null) {
|
if (getConexionRutaConfId() == null) {
|
||||||
if (other.conexionRutaConfId != null)
|
if (other.getConexionRutaConfId() != null)
|
||||||
return false;
|
return false;
|
||||||
} else if (!conexionRutaConfId.equals(other.conexionRutaConfId))
|
} else if (!getConexionRutaConfId().equals(other.getConexionRutaConfId()))
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,10 @@
|
||||||
package com.rjconsultores.ventaboletos.entidad;
|
package com.rjconsultores.ventaboletos.entidad;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.persistence.Basic;
|
import javax.persistence.Basic;
|
||||||
import javax.persistence.CascadeType;
|
|
||||||
import javax.persistence.Column;
|
import javax.persistence.Column;
|
||||||
import javax.persistence.Entity;
|
import javax.persistence.Entity;
|
||||||
import javax.persistence.FetchType;
|
import javax.persistence.FetchType;
|
||||||
|
@ -15,16 +13,11 @@ import javax.persistence.GenerationType;
|
||||||
import javax.persistence.Id;
|
import javax.persistence.Id;
|
||||||
import javax.persistence.JoinColumn;
|
import javax.persistence.JoinColumn;
|
||||||
import javax.persistence.ManyToOne;
|
import javax.persistence.ManyToOne;
|
||||||
import javax.persistence.OneToMany;
|
|
||||||
import javax.persistence.SequenceGenerator;
|
import javax.persistence.SequenceGenerator;
|
||||||
import javax.persistence.Table;
|
import javax.persistence.Table;
|
||||||
import javax.persistence.Temporal;
|
import javax.persistence.Temporal;
|
||||||
import javax.persistence.TemporalType;
|
import javax.persistence.TemporalType;
|
||||||
|
|
||||||
import org.hibernate.annotations.LazyCollection;
|
|
||||||
import org.hibernate.annotations.LazyCollectionOption;
|
|
||||||
import org.hibernate.annotations.Where;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author wallace
|
* @author wallace
|
||||||
|
@ -38,7 +31,7 @@ public class ConexionRutaCtrl implements Serializable {
|
||||||
@Basic(optional = false)
|
@Basic(optional = false)
|
||||||
@GeneratedValue(strategy = GenerationType.AUTO, generator = "CONEXION_RUTA_CTRL_SEQ")
|
@GeneratedValue(strategy = GenerationType.AUTO, generator = "CONEXION_RUTA_CTRL_SEQ")
|
||||||
@Column(name = "CONEXIONRUTACTRL_ID")
|
@Column(name = "CONEXIONRUTACTRL_ID")
|
||||||
private Integer conexionRutaId;
|
private Long conexionRutaId;
|
||||||
@Column(name = "ACTIVO")
|
@Column(name = "ACTIVO")
|
||||||
private Boolean activo;
|
private Boolean activo;
|
||||||
@Column(name = "FECMODIF")
|
@Column(name = "FECMODIF")
|
||||||
|
@ -53,13 +46,10 @@ public class ConexionRutaCtrl implements Serializable {
|
||||||
@Column(name = "RUTA_DESTINOC_ID")
|
@Column(name = "RUTA_DESTINOC_ID")
|
||||||
private Integer rutaDestinoCId;
|
private Integer rutaDestinoCId;
|
||||||
|
|
||||||
|
|
||||||
@ManyToOne(fetch = FetchType.LAZY)
|
@ManyToOne(fetch = FetchType.LAZY)
|
||||||
@JoinColumn(name = "CONEXIONRUTACONF_ID")
|
@JoinColumn(name = "CONEXIONRUTACONF_ID")
|
||||||
private ConexionRutaConf conexionRutaConf;
|
private ConexionRutaConf conexionRutaConf;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public ConexionRutaCtrl() {
|
public ConexionRutaCtrl() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
@ -68,11 +58,11 @@ public class ConexionRutaCtrl implements Serializable {
|
||||||
return activo;
|
return activo;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getConexionRutaId() {
|
public Long getConexionRutaId() {
|
||||||
return conexionRutaId;
|
return conexionRutaId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setConexionRutaId(Integer conexionRutaId) {
|
public void setConexionRutaId(Long conexionRutaId) {
|
||||||
this.conexionRutaId = conexionRutaId;
|
this.conexionRutaId = conexionRutaId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -152,5 +142,30 @@ public class ConexionRutaCtrl implements Serializable {
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static ConexionRutaCtrl getConexionRutaCtrl(List<ConexionRutaCtrl> list, Integer... rutas) {
|
||||||
|
if(rutas != null && rutas.length > 1) {
|
||||||
|
for (ConexionRutaCtrl conexionRutaCtrl : list) {
|
||||||
|
boolean isMatched = conexionRutaCtrl.getRutaOrigenId() != null && conexionRutaCtrl.getRutaOrigenId().equals(rutas[0]);
|
||||||
|
if(!isMatched) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
isMatched = conexionRutaCtrl.getRutaDestinoId() != null && conexionRutaCtrl.getRutaDestinoId().equals(rutas[1]);
|
||||||
|
if(!isMatched) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(rutas.length > 2 && conexionRutaCtrl.getRutaDestinoCId() != null) {
|
||||||
|
isMatched = conexionRutaCtrl.getRutaDestinoCId().equals(rutas[2]);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(isMatched) {
|
||||||
|
return conexionRutaCtrl;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
throw new RuntimeException("ConexionRutaCtrl não identificada");
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -105,7 +105,7 @@ public class ConexionRutaExcepcionPtoVta implements Serializable {
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
int hash = 0;
|
int hash = 0;
|
||||||
hash += (conexionRutaPtovtaId != null ? conexionRutaPtovtaId.hashCode() : 0);
|
hash += (getConexionRutaPtovtaId() != null ? getConexionRutaPtovtaId().hashCode() : 0);
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -115,7 +115,7 @@ public class ConexionRutaExcepcionPtoVta implements Serializable {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ConexionRutaExcepcionPtoVta other = (ConexionRutaExcepcionPtoVta) object;
|
ConexionRutaExcepcionPtoVta other = (ConexionRutaExcepcionPtoVta) object;
|
||||||
if ((this.conexionRutaPtovtaId == null && other.conexionRutaPtovtaId != null) || (this.conexionRutaPtovtaId != null && !this.conexionRutaPtovtaId.equals(other.conexionRutaPtovtaId))) {
|
if ((this.getConexionRutaPtovtaId() == null && other.getConexionRutaPtovtaId() != null) || (this.getConexionRutaPtovtaId() != null && !this.getConexionRutaPtovtaId().equals(other.conexionRutaPtovtaId))) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -105,7 +105,7 @@ public class ConexionRutaExcepcionTipoPtoVta implements Serializable {
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
int hash = 0;
|
int hash = 0;
|
||||||
hash += (conexionRutatipoptovtaId != null ? conexionRutatipoptovtaId.hashCode() : 0);
|
hash += (getConexionRutatipoptovtaId() != null ? getConexionRutatipoptovtaId().hashCode() : 0);
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -115,7 +115,7 @@ public class ConexionRutaExcepcionTipoPtoVta implements Serializable {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ConexionRutaExcepcionTipoPtoVta other = (ConexionRutaExcepcionTipoPtoVta) object;
|
ConexionRutaExcepcionTipoPtoVta other = (ConexionRutaExcepcionTipoPtoVta) object;
|
||||||
if ((this.conexionRutatipoptovtaId == null && other.conexionRutatipoptovtaId != null) || (this.conexionRutatipoptovtaId != null && !this.conexionRutatipoptovtaId.equals(other.conexionRutatipoptovtaId))) {
|
if ((this.getConexionRutatipoptovtaId() == null && other.getConexionRutatipoptovtaId() != null) || (this.getConexionRutatipoptovtaId() != null && !this.conexionRutatipoptovtaId.equals(other.getConexionRutatipoptovtaId()))) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -32,7 +32,7 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
@Basic(optional = false)
|
@Basic(optional = false)
|
||||||
@GeneratedValue(strategy = GenerationType.AUTO, generator = "CONEXION_RUTA_TRAMO_CTRL_SEQ")
|
@GeneratedValue(strategy = GenerationType.AUTO, generator = "CONEXION_RUTA_TRAMO_CTRL_SEQ")
|
||||||
@Column(name = "CONEXIONRUTATRAMOCTRL_ID")
|
@Column(name = "CONEXIONRUTATRAMOCTRL_ID")
|
||||||
private Integer conexionRutaTramoId;
|
private Long conexionRutaTramoId;
|
||||||
@Column(name = "ACTIVO")
|
@Column(name = "ACTIVO")
|
||||||
private Boolean activo;
|
private Boolean activo;
|
||||||
@Column(name = "FECMODIF")
|
@Column(name = "FECMODIF")
|
||||||
|
@ -40,39 +40,51 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
private Date fecmodif;
|
private Date fecmodif;
|
||||||
@Column(name = "USUARIO_ID")
|
@Column(name = "USUARIO_ID")
|
||||||
private Integer usuarioId;
|
private Integer usuarioId;
|
||||||
@Column(name = "ORIGEN_ID")
|
|
||||||
private Integer origenId;
|
@ManyToOne
|
||||||
@Column(name = "DESTINO_ID")
|
@JoinColumn(name = "ORIGEN_ID")
|
||||||
private Integer destinoId;
|
private Parada origen;
|
||||||
|
|
||||||
|
@ManyToOne
|
||||||
|
@JoinColumn(name = "DESTINO_ID")
|
||||||
|
private Parada destino;
|
||||||
|
|
||||||
@ManyToOne(fetch = FetchType.LAZY)
|
@ManyToOne(fetch = FetchType.LAZY)
|
||||||
@JoinColumn(name = "CONEXIONRUTACTRL_ID")
|
@JoinColumn(name = "CONEXIONRUTACTRL_ID")
|
||||||
private ConexionRutaCtrl conexionRutaCtrl;
|
private ConexionRutaCtrl conexionRutaCtrl;
|
||||||
@Transient
|
|
||||||
private Integer rutaId;
|
@ManyToOne
|
||||||
|
@JoinColumn(name = "RUTA_ID")
|
||||||
|
private Ruta ruta;
|
||||||
|
|
||||||
@Transient
|
@Transient
|
||||||
private Short secuencia;
|
private Short secuencia;
|
||||||
@Transient
|
@Transient
|
||||||
private boolean valido;
|
private boolean valido;
|
||||||
@Transient
|
@Transient
|
||||||
private Integer grupo;
|
private Integer grupo;
|
||||||
|
|
||||||
|
public ConexionRutaTramoCtrl() {
|
||||||
|
super();
|
||||||
|
}
|
||||||
|
|
||||||
|
public ConexionRutaTramoCtrl(Long conexionRutaTramoId) {
|
||||||
|
this();
|
||||||
|
this.conexionRutaTramoId = conexionRutaTramoId;
|
||||||
|
}
|
||||||
|
|
||||||
public Boolean getActivo() {
|
public Boolean getActivo() {
|
||||||
return activo;
|
return activo;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getConexionRutaTramoId() {
|
public Long getConexionRutaTramoId() {
|
||||||
return conexionRutaTramoId;
|
return conexionRutaTramoId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setConexionRutaTramoId(Integer conexionRutaTramoId) {
|
public void setConexionRutaTramoId(Long conexionRutaTramoId) {
|
||||||
this.conexionRutaTramoId = conexionRutaTramoId;
|
this.conexionRutaTramoId = conexionRutaTramoId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getOrigenId() {
|
|
||||||
return origenId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setActivo(Boolean activo) {
|
public void setActivo(Boolean activo) {
|
||||||
this.activo = activo;
|
this.activo = activo;
|
||||||
}
|
}
|
||||||
|
@ -93,18 +105,6 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
this.usuarioId = usuarioId;
|
this.usuarioId = usuarioId;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setOrigenId(Integer origenId) {
|
|
||||||
this.origenId = origenId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Integer getDestinoId() {
|
|
||||||
return destinoId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setDestinoId(Integer destinoId) {
|
|
||||||
this.destinoId = destinoId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ConexionRutaCtrl getConexionRutaCtrl() {
|
public ConexionRutaCtrl getConexionRutaCtrl() {
|
||||||
return conexionRutaCtrl;
|
return conexionRutaCtrl;
|
||||||
}
|
}
|
||||||
|
@ -113,14 +113,6 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
this.conexionRutaCtrl = conexionRutaCtrl;
|
this.conexionRutaCtrl = conexionRutaCtrl;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Integer getRutaId() {
|
|
||||||
return rutaId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setRutaId(Integer rutaId) {
|
|
||||||
this.rutaId = rutaId;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Short getSecuencia() {
|
public Short getSecuencia() {
|
||||||
return secuencia;
|
return secuencia;
|
||||||
}
|
}
|
||||||
|
@ -145,7 +137,7 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
this.grupo = grupo;
|
this.grupo = grupo;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Integer getConexionRutaTramoConexionId(List<Conexion> conexiones) {
|
public static Long getConexionRutaTramoConexionId(List<Conexion> conexiones) {
|
||||||
if(conexiones != null && !conexiones.isEmpty()) {
|
if(conexiones != null && !conexiones.isEmpty()) {
|
||||||
Conexion conexionRutaTramoCtrl = conexiones.get(0);
|
Conexion conexionRutaTramoCtrl = conexiones.get(0);
|
||||||
return conexionRutaTramoCtrl.getConexionRutaTramoId();
|
return conexionRutaTramoCtrl.getConexionRutaTramoId();
|
||||||
|
@ -168,15 +160,39 @@ public class ConexionRutaTramoCtrl implements Serializable {
|
||||||
return true;
|
return true;
|
||||||
if (obj == null)
|
if (obj == null)
|
||||||
return false;
|
return false;
|
||||||
if (getClass() != obj.getClass())
|
if (!(obj instanceof ConexionRutaTramoCtrl))
|
||||||
return false;
|
return false;
|
||||||
ConexionRutaTramoCtrl other = (ConexionRutaTramoCtrl) obj;
|
ConexionRutaTramoCtrl other = (ConexionRutaTramoCtrl) obj;
|
||||||
if (conexionRutaTramoId == null) {
|
if (getConexionRutaTramoId() == null) {
|
||||||
if (other.conexionRutaTramoId != null)
|
if (other.getConexionRutaTramoId() != null)
|
||||||
return false;
|
return false;
|
||||||
} else if (!conexionRutaTramoId.equals(other.conexionRutaTramoId))
|
} else if (!getConexionRutaTramoId().equals(other.getConexionRutaTramoId()))
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Parada getOrigen() {
|
||||||
|
return origen;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOrigen(Parada origen) {
|
||||||
|
this.origen = origen;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Parada getDestino() {
|
||||||
|
return destino;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDestino(Parada destino) {
|
||||||
|
this.destino = destino;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Ruta getRuta() {
|
||||||
|
return ruta;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRuta(Ruta ruta) {
|
||||||
|
this.ruta = ruta;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -130,7 +130,7 @@ public class TipoPuntoVenta implements Serializable {
|
||||||
@Override
|
@Override
|
||||||
public int hashCode() {
|
public int hashCode() {
|
||||||
int hash = 0;
|
int hash = 0;
|
||||||
hash += (tipoptovtaId != null ? tipoptovtaId.hashCode() : 0);
|
hash += (getTipoptovtaId() != null ? getTipoptovtaId().hashCode() : 0);
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -142,7 +142,7 @@ public class TipoPuntoVenta implements Serializable {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
TipoPuntoVenta other = (TipoPuntoVenta) object;
|
TipoPuntoVenta other = (TipoPuntoVenta) object;
|
||||||
if ((this.tipoptovtaId == null && other.tipoptovtaId != null) || (this.tipoptovtaId != null && !this.tipoptovtaId.equals(other.tipoptovtaId))) {
|
if ((this.getTipoptovtaId() == null && other.getTipoptovtaId() != null) || (this.getTipoptovtaId() != null && !this.getTipoptovtaId().equals(other.getTipoptovtaId()))) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -21,5 +21,7 @@ public interface ConexionRutaConfService {
|
||||||
public List<ConexionRutaConf> buscarPorDescricao(String descricao);
|
public List<ConexionRutaConf> buscarPorDescricao(String descricao);
|
||||||
|
|
||||||
public ConexionRutaConf obtenerID(Integer id);
|
public ConexionRutaConf obtenerID(Integer id);
|
||||||
|
|
||||||
|
public void excluirConfiguracao(ConexionRutaConf conexion, boolean excluirConexionRutaConf);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,12 +4,12 @@ import java.util.List;
|
||||||
|
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
||||||
|
import com.rjconsultores.ventaboletos.entidad.Parada;
|
||||||
|
|
||||||
public interface ConexionRutaTramoCtrlService {
|
public interface ConexionRutaTramoCtrlService {
|
||||||
|
|
||||||
public void gerarConexiones();
|
public void gerarConexiones();
|
||||||
|
|
||||||
|
|
||||||
public ConexionRutaTramoCtrl suscribir(ConexionRutaTramoCtrl conexion);
|
public ConexionRutaTramoCtrl suscribir(ConexionRutaTramoCtrl conexion);
|
||||||
|
|
||||||
public ConexionRutaTramoCtrl actualizacion(ConexionRutaTramoCtrl conexion);
|
public ConexionRutaTramoCtrl actualizacion(ConexionRutaTramoCtrl conexion);
|
||||||
|
@ -17,15 +17,18 @@ public interface ConexionRutaTramoCtrlService {
|
||||||
public void borrar(ConexionRutaTramoCtrl conexion);
|
public void borrar(ConexionRutaTramoCtrl conexion);
|
||||||
|
|
||||||
public List<ConexionRutaTramoCtrl> buscarPorConexionRutaCtrl(ConexionRutaCtrl conexionRutaCtrl);
|
public List<ConexionRutaTramoCtrl> buscarPorConexionRutaCtrl(ConexionRutaCtrl conexionRutaCtrl);
|
||||||
|
|
||||||
|
|
||||||
public void borrar(List<ConexionRutaTramoCtrl> lsConexion);
|
public void borrar(List<ConexionRutaTramoCtrl> lsConexion);
|
||||||
|
|
||||||
public void suscribirTodos(List<ConexionRutaTramoCtrl> conexiones);
|
public void suscribirTodos(List<ConexionRutaTramoCtrl> conexiones);
|
||||||
|
|
||||||
|
public ConexionRutaTramoCtrl buscarPorId(Long conexionRutaTramoId);
|
||||||
public ConexionRutaTramoCtrl buscarPorId(Integer conexionRutaTramoId);
|
|
||||||
|
|
||||||
|
|
||||||
public boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId, Integer integer);
|
public boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId, Integer integer);
|
||||||
|
|
||||||
|
public List<Parada> buscarLocalidadesOrigem(ConexionRutaCtrl conexionRutaCtrl);
|
||||||
|
|
||||||
|
public List<Parada> buscarLocalidadesDestino(ConexionRutaCtrl conexionRutaCtrl);
|
||||||
|
|
||||||
|
public List<Parada> buscarLocalidadesDestinoC(ConexionRutaCtrl conexionRutaCtrl);
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,4 +70,6 @@ public interface RutaCombinacionService extends GenericService<RutaCombinacion,
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public boolean existeTramo(Tramo tramo);
|
public boolean existeTramo(Tramo tramo);
|
||||||
|
|
||||||
|
public boolean isRutaCombinacionVenda(Integer rutaId, Integer origenId, Integer destinoId);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
package com.rjconsultores.ventaboletos.service.impl;
|
package com.rjconsultores.ventaboletos.service.impl;
|
||||||
|
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.Date;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
@ -44,9 +43,10 @@ public class ConexionDescuentoServiceImpl implements ConexionDescuentoService {
|
||||||
@Override
|
@Override
|
||||||
@Transactional
|
@Transactional
|
||||||
public void suscribirTodos(List<ConexionDescuento> conexionesDescuentos) {
|
public void suscribirTodos(List<ConexionDescuento> conexionesDescuentos) {
|
||||||
|
for (ConexionDescuento conexionDescuento : conexionesDescuentos) {
|
||||||
|
conexionDescuento.setFecModif(Calendar.getInstance().getTime());
|
||||||
|
}
|
||||||
conexionDescuentoHDAO.suscribirTodos(conexionesDescuentos);
|
conexionDescuentoHDAO.suscribirTodos(conexionesDescuentos);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -83,4 +83,10 @@ public class ConexionRutaConfServiceImpl implements ConexionRutaConfService {
|
||||||
return conexionRutaConfDAO.obtenerID(id);
|
return conexionRutaConfDAO.obtenerID(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional
|
||||||
|
public void excluirConfiguracao(ConexionRutaConf conexion, boolean excluirConexionRutaConf) {
|
||||||
|
conexionRutaConfDAO.excluirConfiguracao(conexion, UsuarioLogado.getUsuarioLogado().getUsuarioId(), excluirConexionRutaConf);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
package com.rjconsultores.ventaboletos.service.impl;
|
package com.rjconsultores.ventaboletos.service.impl;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -10,6 +11,7 @@ import org.springframework.transaction.annotation.Transactional;
|
||||||
import com.rjconsultores.ventaboletos.dao.ConexionRutaTramoCtrlDAO;
|
import com.rjconsultores.ventaboletos.dao.ConexionRutaTramoCtrlDAO;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaCtrl;
|
||||||
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
import com.rjconsultores.ventaboletos.entidad.ConexionRutaTramoCtrl;
|
||||||
|
import com.rjconsultores.ventaboletos.entidad.Parada;
|
||||||
import com.rjconsultores.ventaboletos.service.ConexionRutaTramoCtrlService;
|
import com.rjconsultores.ventaboletos.service.ConexionRutaTramoCtrlService;
|
||||||
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
|
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
|
||||||
|
|
||||||
|
@ -77,7 +79,7 @@ public class ConexionRutaTramoCtrlServiceImpl implements ConexionRutaTramoCtrlSe
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ConexionRutaTramoCtrl buscarPorId(Integer conexionRutaTramoId) {
|
public ConexionRutaTramoCtrl buscarPorId(Long conexionRutaTramoId) {
|
||||||
return conexionRutaTramoCtrlDAO.obtenerID(conexionRutaTramoId);
|
return conexionRutaTramoCtrlDAO.obtenerID(conexionRutaTramoId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -85,4 +87,51 @@ public class ConexionRutaTramoCtrlServiceImpl implements ConexionRutaTramoCtrlSe
|
||||||
public boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer rutaDestinoCId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId) {
|
public boolean validarConexioneRutasExistentes(Integer rutaOrigenId, Integer rutaDestinoId, Integer rutaDestinoCId, Integer paradaOrigenId, Integer paradaDestinoId, Integer origemTrechoId, Integer destinoTrechoId) {
|
||||||
return conexionRutaTramoCtrlDAO.validarConexioneRutasExistentes(rutaOrigenId, rutaDestinoId, rutaDestinoCId, paradaOrigenId, paradaDestinoId, origemTrechoId, destinoTrechoId);
|
return conexionRutaTramoCtrlDAO.validarConexioneRutasExistentes(rutaOrigenId, rutaDestinoId, rutaDestinoCId, paradaOrigenId, paradaDestinoId, origemTrechoId, destinoTrechoId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Parada> buscarLocalidadesOrigem(ConexionRutaCtrl conexionRutaCtrl) {
|
||||||
|
return carregarParadas(conexionRutaCtrl, 'A');
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Parada> buscarLocalidadesDestino(ConexionRutaCtrl conexionRutaCtrl) {
|
||||||
|
return carregarParadas(conexionRutaCtrl, 'B');
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Parada> buscarLocalidadesDestinoC(ConexionRutaCtrl conexionRutaCtrl) {
|
||||||
|
return carregarParadas(conexionRutaCtrl, 'C');
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<Parada> carregarParadas(ConexionRutaCtrl conexionRutaCtrl, char tipo) {
|
||||||
|
List<Parada> paradas = new ArrayList<Parada>(0);
|
||||||
|
List<ConexionRutaTramoCtrl> trechos = buscarPorConexionRutaCtrl(conexionRutaCtrl);
|
||||||
|
for (ConexionRutaTramoCtrl conexionRutaTramoCtrl : trechos) {
|
||||||
|
if(conexionRutaTramoCtrl.getRuta() != null) {
|
||||||
|
switch (tipo) {
|
||||||
|
case 'A':
|
||||||
|
if(conexionRutaTramoCtrl.getRuta().getRutaId().equals(conexionRutaCtrl.getRutaOrigenId()) &&
|
||||||
|
!paradas.contains(conexionRutaTramoCtrl.getOrigen())) {
|
||||||
|
paradas.add(conexionRutaTramoCtrl.getOrigen());
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 'B':
|
||||||
|
if(conexionRutaTramoCtrl.getRuta().getRutaId().equals(conexionRutaCtrl.getRutaDestinoId()) &&
|
||||||
|
!paradas.contains(conexionRutaTramoCtrl.getDestino())) {
|
||||||
|
paradas.add(conexionRutaTramoCtrl.getDestino());
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 'C':
|
||||||
|
if(conexionRutaCtrl.getRutaDestinoCId() != null &&
|
||||||
|
conexionRutaTramoCtrl.getRuta().getRutaId().equals(conexionRutaCtrl.getRutaDestinoCId()) &&
|
||||||
|
!paradas.contains(conexionRutaTramoCtrl.getDestino())) {
|
||||||
|
paradas.add(conexionRutaTramoCtrl.getDestino());
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return paradas;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -440,4 +440,9 @@ public class RutaCombinacionServiceImpl implements RutaCombinacionService {
|
||||||
public boolean existeTramo(Tramo tramo) {
|
public boolean existeTramo(Tramo tramo) {
|
||||||
return rutaCombinacionDAO.existeTramo(tramo);
|
return rutaCombinacionDAO.existeTramo(tramo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isRutaCombinacionVenda(Integer rutaId, Integer origenId, Integer destinoId) {
|
||||||
|
return rutaCombinacionDAO.isRutaCombinacionVenda(rutaId, origenId, destinoId);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,87 @@
|
||||||
|
package com.rjconsultores.ventaboletos.vo.parada;
|
||||||
|
|
||||||
|
public class ConexionCtrlVO {
|
||||||
|
|
||||||
|
private Integer origenId;
|
||||||
|
private Integer destinoId;
|
||||||
|
private Integer grupo;
|
||||||
|
private boolean valida;
|
||||||
|
|
||||||
|
public ConexionCtrlVO(Integer origemConexaoCtrl, Integer destinoConexaoCtrl) {
|
||||||
|
this.grupo = 0;
|
||||||
|
this.origenId = origemConexaoCtrl;
|
||||||
|
this.destinoId = destinoConexaoCtrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getOrigenId() {
|
||||||
|
return origenId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setOrigenId(Integer origenId) {
|
||||||
|
this.origenId = origenId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getDestinoId() {
|
||||||
|
return destinoId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDestinoId(Integer destinoId) {
|
||||||
|
this.destinoId = destinoId;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int hashCode() {
|
||||||
|
final int prime = 31;
|
||||||
|
int result = 1;
|
||||||
|
result = prime * result + ((destinoId == null) ? 0 : destinoId.hashCode());
|
||||||
|
result = prime * result + ((origenId == null) ? 0 : origenId.hashCode());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(Object obj) {
|
||||||
|
if (this == obj)
|
||||||
|
return true;
|
||||||
|
if (obj == null)
|
||||||
|
return false;
|
||||||
|
if (!(obj instanceof ConexionCtrlVO))
|
||||||
|
return false;
|
||||||
|
ConexionCtrlVO other = (ConexionCtrlVO) obj;
|
||||||
|
if (getDestinoId() == null) {
|
||||||
|
if (other.getDestinoId() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getDestinoId().equals(other.getDestinoId()))
|
||||||
|
return false;
|
||||||
|
if (getOrigenId() == null) {
|
||||||
|
if (other.getOrigenId() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getOrigenId().equals(other.getOrigenId()))
|
||||||
|
return false;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void incrementarGrupo() {
|
||||||
|
grupo++;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void decrementarGrupo() {
|
||||||
|
grupo--;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getGrupo() {
|
||||||
|
return grupo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isOrigemDestinoIgual(Integer origemConexaoCtrl, Integer destinoConexaoCtrl) {
|
||||||
|
return getOrigenId().equals(origemConexaoCtrl) && getDestinoId().equals(destinoConexaoCtrl);
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isValida() {
|
||||||
|
return valida;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setValida(boolean valida) {
|
||||||
|
this.valida = valida;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -0,0 +1,76 @@
|
||||||
|
package com.rjconsultores.ventaboletos.vo.parada;
|
||||||
|
|
||||||
|
public class ConexionRutaCtrlVO {
|
||||||
|
|
||||||
|
private Integer rutaIdA;
|
||||||
|
private Integer rutaIdB;
|
||||||
|
private Integer rutaIdC;
|
||||||
|
|
||||||
|
public ConexionRutaCtrlVO(Integer rutaIdA, Integer rutaIdB, Integer rutaIdC) {
|
||||||
|
this.rutaIdA = rutaIdA;
|
||||||
|
this.rutaIdB = rutaIdB;
|
||||||
|
this.rutaIdC = rutaIdC;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getRutaIdA() {
|
||||||
|
return rutaIdA;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRutaIdA(Integer rutaIdA) {
|
||||||
|
this.rutaIdA = rutaIdA;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getRutaIdB() {
|
||||||
|
return rutaIdB;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRutaIdB(Integer rutaIdB) {
|
||||||
|
this.rutaIdB = rutaIdB;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getRutaIdC() {
|
||||||
|
return rutaIdC;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRutaIdC(Integer rutaIdC) {
|
||||||
|
this.rutaIdC = rutaIdC;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int hashCode() {
|
||||||
|
final int prime = 31;
|
||||||
|
int result = 1;
|
||||||
|
result = prime * result + ((getRutaIdA() == null) ? 0 : getRutaIdA().hashCode());
|
||||||
|
result = prime * result + ((getRutaIdB() == null) ? 0 : getRutaIdB().hashCode());
|
||||||
|
result = prime * result + ((getRutaIdC() == null) ? 0 : getRutaIdC().hashCode());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(Object obj) {
|
||||||
|
if (this == obj)
|
||||||
|
return true;
|
||||||
|
if (obj == null)
|
||||||
|
return false;
|
||||||
|
if (!(obj instanceof ConexionRutaCtrlVO))
|
||||||
|
return false;
|
||||||
|
ConexionRutaCtrlVO other = (ConexionRutaCtrlVO) obj;
|
||||||
|
if (getRutaIdA() == null) {
|
||||||
|
if (other.getRutaIdA() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getRutaIdA().equals(other.getRutaIdA()))
|
||||||
|
return false;
|
||||||
|
if (getRutaIdB() == null) {
|
||||||
|
if (other.getRutaIdB() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getRutaIdB().equals(other.getRutaIdB()))
|
||||||
|
return false;
|
||||||
|
if (getRutaIdC() == null) {
|
||||||
|
if (other.getRutaIdC() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getRutaIdC().equals(other.getRutaIdC()))
|
||||||
|
return false;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
|
@ -4,6 +4,7 @@ import com.rjconsultores.ventaboletos.entidad.Parada;
|
||||||
|
|
||||||
public class ParadaVOConexionRuta {
|
public class ParadaVOConexionRuta {
|
||||||
|
|
||||||
|
private Long conexionRutaTramoId;
|
||||||
private Parada paradaOrigem;
|
private Parada paradaOrigem;
|
||||||
private Parada paradaDestino;
|
private Parada paradaDestino;
|
||||||
private Parada paradaOrigemTrecho;
|
private Parada paradaOrigemTrecho;
|
||||||
|
@ -13,8 +14,13 @@ public class ParadaVOConexionRuta {
|
||||||
private Short secuencia;
|
private Short secuencia;
|
||||||
private boolean valido;
|
private boolean valido;
|
||||||
private Integer grupo;
|
private Integer grupo;
|
||||||
|
|
||||||
|
private ConexionCtrlVO conexionCtrl;
|
||||||
|
private ConexionRutaCtrlVO conexionRutaCtrl;
|
||||||
|
|
||||||
public ParadaVOConexionRuta(int grupo, Parada paradaOrigem, Parada paradaDestino, Integer rutaId, String numRuta, Short secuencia, boolean valido, Parada paradaOrigemTrecho, Parada paradaDestinoTrecho) {
|
public ParadaVOConexionRuta(int grupo, Parada paradaOrigem, Parada paradaDestino, Integer rutaId, String numRuta, Short secuencia,
|
||||||
|
boolean valido, Parada paradaOrigemTrecho, Parada paradaDestinoTrecho, ConexionCtrlVO conexionCtrl,
|
||||||
|
ConexionRutaCtrlVO conexionRutaCtrl) {
|
||||||
super();
|
super();
|
||||||
this.grupo = grupo;
|
this.grupo = grupo;
|
||||||
this.paradaOrigem = paradaOrigem;
|
this.paradaOrigem = paradaOrigem;
|
||||||
|
@ -25,6 +31,8 @@ public class ParadaVOConexionRuta {
|
||||||
this.valido = valido;
|
this.valido = valido;
|
||||||
this.paradaOrigemTrecho = paradaOrigemTrecho;
|
this.paradaOrigemTrecho = paradaOrigemTrecho;
|
||||||
this.paradaDestinoTrecho = paradaDestinoTrecho;
|
this.paradaDestinoTrecho = paradaDestinoTrecho;
|
||||||
|
this.conexionCtrl = conexionCtrl;
|
||||||
|
this.conexionRutaCtrl = conexionRutaCtrl;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Parada getParadaOrigem() {
|
public Parada getParadaOrigem() {
|
||||||
|
@ -104,4 +112,65 @@ public class ParadaVOConexionRuta {
|
||||||
return "ParadaVOConexionRuta [paradaOrigem=" + paradaOrigem + ", paradaDestino=" + paradaDestino + ", paradaOrigemTrecho=" + paradaOrigemTrecho + ", paradaDestinoTrecho=" + paradaDestinoTrecho + ", rutaId=" + rutaId + ", numRuta=" + numRuta + ", secuencia=" + secuencia + ", valido=" + valido + "]";
|
return "ParadaVOConexionRuta [paradaOrigem=" + paradaOrigem + ", paradaDestino=" + paradaDestino + ", paradaOrigemTrecho=" + paradaOrigemTrecho + ", paradaDestinoTrecho=" + paradaDestinoTrecho + ", rutaId=" + rutaId + ", numRuta=" + numRuta + ", secuencia=" + secuencia + ", valido=" + valido + "]";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ConexionCtrlVO getConexionCtrl() {
|
||||||
|
return conexionCtrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setConexionCtrl(ConexionCtrlVO conexionCtrl) {
|
||||||
|
this.conexionCtrl = conexionCtrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int hashCode() {
|
||||||
|
final int prime = 31;
|
||||||
|
int result = 1;
|
||||||
|
result = prime * result + ((getParadaDestino() == null) ? 0 : getParadaDestino().hashCode());
|
||||||
|
result = prime * result + ((getParadaOrigem() == null) ? 0 : getParadaOrigem().hashCode());
|
||||||
|
result = prime * result + ((getRutaId() == null) ? 0 : getRutaId().hashCode());
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean equals(Object obj) {
|
||||||
|
if (this == obj)
|
||||||
|
return true;
|
||||||
|
if (obj == null)
|
||||||
|
return false;
|
||||||
|
if (!(obj instanceof ParadaVOConexionRuta))
|
||||||
|
return false;
|
||||||
|
ParadaVOConexionRuta other = (ParadaVOConexionRuta) obj;
|
||||||
|
if (getParadaDestino() == null) {
|
||||||
|
if (other.getParadaDestino() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getParadaDestino().equals(other.getParadaDestino()))
|
||||||
|
return false;
|
||||||
|
if (getParadaOrigem() == null) {
|
||||||
|
if (other.getParadaOrigem() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getParadaOrigem().equals(other.getParadaOrigem()))
|
||||||
|
return false;
|
||||||
|
if (getRutaId() == null) {
|
||||||
|
if (other.getRutaId() != null)
|
||||||
|
return false;
|
||||||
|
} else if (!getRutaId().equals(other.getRutaId()))
|
||||||
|
return false;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ConexionRutaCtrlVO getConexionRutaCtrl() {
|
||||||
|
return conexionRutaCtrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setConexionRutaCtrl(ConexionRutaCtrlVO conexionRutaCtrl) {
|
||||||
|
this.conexionRutaCtrl = conexionRutaCtrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getConexionRutaTramoId() {
|
||||||
|
return conexionRutaTramoId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setConexionRutaTramoId(Long conexionRutaTramoId) {
|
||||||
|
this.conexionRutaTramoId = conexionRutaTramoId;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue