Alteração do cadastro de ponto de venda (agencia)

git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@22312 d1611594-4594-4d17-8e1d-87c2c4800839
master
carla 2012-10-31 12:47:43 +00:00
parent ea58d7b75b
commit 8ab1367fa5
37 changed files with 697 additions and 1455 deletions

View File

@ -0,0 +1,13 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
public interface InstiFinanceiraDAO extends GenericDAO<InstiFinanceira, Integer> {
public List<InstiFinanceira> buscar(String nome);
}

View File

@ -1,13 +0,0 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgenciaBancaria;
public interface PtovtaAgenciaBancariaDAO extends GenericDAO<PtovtaAgenciaBancaria, Integer> {
public List<PtovtaAgenciaBancaria> buscar(String numagencia);
}

View File

@ -0,0 +1,13 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgencia;
public interface PtovtaAgenciaDAO extends GenericDAO<PtovtaAgencia, Integer> {
public List<PtovtaAgencia> buscar(String numagencia);
}

View File

@ -1,13 +0,0 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
public interface PtovtaBancoDAO extends GenericDAO<PtovtaBanco, Integer> {
public List<PtovtaBanco> buscar(String nome);
}

View File

@ -1,15 +0,0 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaInformacao;
public interface PtovtaInformacaoDAO extends GenericDAO<PtovtaInformacao, Integer> {
public List<PtovtaInformacao> buscar(int id);
}

View File

@ -1,17 +0,0 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaPercentual;
public interface PtovtaPercentualDAO extends GenericDAO<PtovtaPercentual, Integer> {
public List<PtovtaPercentual> buscar(int id);
}

View File

@ -1,16 +0,0 @@
package com.rjconsultores.ventaboletos.dao;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaTipoPercentual;
public interface PtovtaTipoPercentualDAO extends GenericDAO<PtovtaTipoPercentual, Integer> {
public List<PtovtaTipoPercentual> buscar(int id);
}

View File

@ -11,21 +11,21 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;
import com.rjconsultores.ventaboletos.dao.PtovtaBancoDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
import com.rjconsultores.ventaboletos.dao.InstiFinanceiraDAO;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
@Repository("ptovtaBancoDAO")
public class PtovtaBancoHibernateDAO extends GenericHibernateDAO<PtovtaBanco, Integer>
implements PtovtaBancoDAO {
public class InstiFinanceiraHibernateDAO extends GenericHibernateDAO<InstiFinanceira, Integer>
implements InstiFinanceiraDAO {
@Autowired
public PtovtaBancoHibernateDAO(
public InstiFinanceiraHibernateDAO(
@Qualifier("sessionFactory") SessionFactory factory) {
setSessionFactory(factory);
}
@Override
public List<PtovtaBanco> obtenerTodos() {
public List<InstiFinanceira> obtenerTodos() {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.addOrder(Order.asc("nome"));
@ -33,7 +33,7 @@ public class PtovtaBancoHibernateDAO extends GenericHibernateDAO<PtovtaBanco, In
return c.list();
}
public List<PtovtaBanco> buscar(String nome) {
public List<InstiFinanceira> buscar(String nome) {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.add(Restrictions.eq("nome", nome));

View File

@ -11,22 +11,22 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;
import com.rjconsultores.ventaboletos.dao.PtovtaAgenciaBancariaDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgenciaBancaria;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
import com.rjconsultores.ventaboletos.dao.PtovtaAgenciaDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgencia;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
@Repository("ptovtaAgenciaBancariaDAO")
public class PtovtaAgenciaBancariaHibernateDAO extends GenericHibernateDAO<PtovtaAgenciaBancaria, Integer>
implements PtovtaAgenciaBancariaDAO {
public class PtovtaAgenciaHibernateDAO extends GenericHibernateDAO<PtovtaAgencia, Integer>
implements PtovtaAgenciaDAO {
@Autowired
public PtovtaAgenciaBancariaHibernateDAO(
public PtovtaAgenciaHibernateDAO(
@Qualifier("sessionFactory") SessionFactory factory) {
setSessionFactory(factory);
}
@Override
public List<PtovtaAgenciaBancaria> obtenerTodos() {
public List<PtovtaAgencia> obtenerTodos() {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.addOrder(Order.asc("numagencia"));
@ -34,7 +34,7 @@ public class PtovtaAgenciaBancariaHibernateDAO extends GenericHibernateDAO<Ptovt
return c.list();
}
public List<PtovtaAgenciaBancaria> buscar(String numagencia) {
public List<PtovtaAgencia> buscar(String numagencia) {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.add(Restrictions.eq("numagencia", numagencia));

View File

@ -1,49 +0,0 @@
package com.rjconsultores.ventaboletos.dao.hibernate;
import java.util.List;
import org.hibernate.Criteria;
import org.hibernate.Query;
import org.hibernate.SessionFactory;
import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;
import com.rjconsultores.ventaboletos.dao.PtovtaInformacaoDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaInformacao;
@Repository("ptovtaInformacaoDAO")
public class PtovtaInformacaoHibernateDAO extends GenericHibernateDAO<PtovtaInformacao, Integer>
implements PtovtaInformacaoDAO {
@Autowired
public PtovtaInformacaoHibernateDAO(
@Qualifier("sessionFactory") SessionFactory factory) {
setSessionFactory(factory);
}
@Override
public List<PtovtaInformacao> obtenerTodos() {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.addOrder(Order.asc("id"));
return c.list();
}
public List<PtovtaInformacao> buscar(int id) {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.add(Restrictions.eq("id", id));
return c.list();
}
}

View File

@ -1,49 +0,0 @@
package com.rjconsultores.ventaboletos.dao.hibernate;
import java.util.List;
import org.hibernate.Criteria;
import org.hibernate.Query;
import org.hibernate.SessionFactory;
import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;
import com.rjconsultores.ventaboletos.dao.PtovtaPercentualDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaPercentual;
@Repository("ptovtaPercentualDAO")
public class PtovtaPercentualHibernateDAO extends GenericHibernateDAO<PtovtaPercentual, Integer>
implements PtovtaPercentualDAO {
@Autowired
public PtovtaPercentualHibernateDAO(
@Qualifier("sessionFactory") SessionFactory factory) {
setSessionFactory(factory);
}
@Override
public List<PtovtaPercentual> obtenerTodos() {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.addOrder(Order.asc("id"));
return c.list();
}
public List<PtovtaPercentual> buscar(int id) {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.add(Restrictions.eq("id", id));
return c.list();
}
}

View File

@ -1,49 +0,0 @@
package com.rjconsultores.ventaboletos.dao.hibernate;
import java.util.List;
import org.hibernate.Criteria;
import org.hibernate.Query;
import org.hibernate.SessionFactory;
import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Repository;
import com.rjconsultores.ventaboletos.dao.PtovtaTipoPercentualDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaTipoPercentual;
@Repository("ptovtaTipoPercentualDAO")
public class PtovtaTipoPercentualHibernateDAO extends GenericHibernateDAO<PtovtaTipoPercentual, Integer>
implements PtovtaTipoPercentualDAO {
@Autowired
public PtovtaTipoPercentualHibernateDAO(
@Qualifier("sessionFactory") SessionFactory factory) {
setSessionFactory(factory);
}
@Override
public List<PtovtaTipoPercentual> obtenerTodos() {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.addOrder(Order.asc("id"));
return c.list();
}
public List<PtovtaTipoPercentual> buscar(int id) {
Criteria c = getSession().createCriteria(getPersistentClass());
c.add(Restrictions.eq("activo", Boolean.TRUE));
c.add(Restrictions.eq("id", id));
return c.list();
}
}

View File

@ -11,10 +11,13 @@ import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@ -24,41 +27,46 @@ import javax.persistence.TemporalType;
* @author Rafael
*/
@Entity
@Table(name = "PTOVTA_BANCO")
@NamedQueries({
@NamedQuery(name = "PtovtaBanco.findAll", query = "SELECT p FROM PtovtaBanco p")})
public class PtovtaBanco implements Serializable {
@Column(name = "USUARIO_ID")
private Integer usuarioId;
@Column(name = "CODIGO")
private String codigo;
@SequenceGenerator(name = " INSTI_FINANCEIRA_SEQ", sequenceName = " INSTI_FINANCEIRA_SEQ", allocationSize = 1)
@Table(name = "INSTI_FINANCEIRA")
public class InstiFinanceira implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Basic(optional = false)
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_COMISSAO_SEQ")
@Column(name = "INSTIFINANCEIRA_ID")
private Integer instFinanceiraId;
@Column(name = "NOME")
private String nome;
@Basic(optional = false)
@Column(name = "USUARIO_ID")
private Integer usuarioId;
@Column(name = "CODIGO")
private String codigo;
@Column(name = "ACTIVO")
private Boolean activo;
@Basic(optional = false)
@Column(name = "FECMODIF")
@Temporal(TemporalType.TIMESTAMP)
private Date fecmodif;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "bancoId")
private List<PtovtaAgenciaBancaria> ptovtaAgenciaList;
private List<PtovtaAgencia> ptovtaAgenciaList;
public PtovtaBanco() {
public InstiFinanceira() {
}
public PtovtaBanco(Integer id) {
this.id = id;
public InstiFinanceira(Integer instFinanceiraId) {
this.instFinanceiraId = instFinanceiraId;
}
public PtovtaBanco(Integer id, String codigo, String nome, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public InstiFinanceira(Integer instFinanceiraId, String codigo, String nome, Boolean activo, Date fecmodif, int usuarioId) {
this.instFinanceiraId = instFinanceiraId;
this.codigo = codigo;
this.nome = nome;
this.activo = activo;
@ -66,12 +74,14 @@ public class PtovtaBanco implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getInstFinanceiraId() {
return instFinanceiraId;
}
public void setId(Integer id) {
this.id = id;
public void setInstFinanceiraId(Integer instFinanceiraId) {
this.instFinanceiraId = instFinanceiraId;
}
public String getNome() {
@ -106,11 +116,11 @@ public class PtovtaBanco implements Serializable {
this.usuarioId = usuarioId;
}
public List<PtovtaAgenciaBancaria> getPtovtaAgenciaList() {
public List<PtovtaAgencia> getPtovtaAgenciaList() {
return ptovtaAgenciaList;
}
public void setPtovtaAgenciaList(List<PtovtaAgenciaBancaria> ptovtaAgenciaList) {
public void setPtovtaAgenciaList(List<PtovtaAgencia> ptovtaAgenciaList) {
this.ptovtaAgenciaList = ptovtaAgenciaList;
}
@ -125,18 +135,18 @@ public class PtovtaBanco implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (instFinanceiraId != null ? instFinanceiraId.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaBanco)) {
if (!(object instanceof InstiFinanceira)) {
return false;
}
PtovtaBanco other = (PtovtaBanco) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
InstiFinanceira other = (InstiFinanceira) object;
if ((this.instFinanceiraId == null && other.instFinanceiraId != null) || (this.instFinanceiraId != null && !this.instFinanceiraId.equals(other.instFinanceiraId))) {
return false;
}
return true;

View File

@ -31,16 +31,16 @@ import javax.persistence.TemporalType;
* @author Rafael
*/
@Entity
@SequenceGenerator(name = "PTOVTA_AGENCIA_BANCARIA_SEQ", sequenceName = "PTOVTA_AGENCIA_BANCARIA_SEQ", allocationSize = 1)
@Table(name = "PTOVTA_AGENCIA_BANCARIA")
@SequenceGenerator(name = "PTOVTA_AGENCIA_SEQ", sequenceName = "PTOVTA_AGENCIA_SEQ", allocationSize = 1)
@Table(name = "PTOVTA_AGENCIA")
public class PtovtaAgenciaBancaria implements Serializable {
public class PtovtaAgencia implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_AGENCIA_BANCARIA_SEQ")
@Column(name = "ID")
private Integer id;
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_AGENCIA_SEQ")
@Column(name = "PTOVTAAGENCIA_ID")
private Integer ptovtaAgenciaId;
@Column(name = "NUMAGENCIA")
private String numagencia;
@ -73,19 +73,19 @@ public class PtovtaAgenciaBancaria implements Serializable {
@Column(name = "USUARIO_ID")
private int usuarioId;
@JoinColumn(name = "BANCO_ID", referencedColumnName = "ID")
@JoinColumn(name = "INSTIFINANCEIRA_ID", referencedColumnName = "INSTIFINANCEIRA_ID")
@ManyToOne
private PtovtaBanco bancoId;
private InstiFinanceira instiFinanceiraId;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "agenciaId")
private List<PuntoVenta> puntoVentaList;
public PtovtaAgenciaBancaria() {
public PtovtaAgencia() {
}
public PtovtaAgenciaBancaria(Integer id) {
this.id = id;
public PtovtaAgencia(Integer ptovtaAgenciaId) {
this.ptovtaAgenciaId = ptovtaAgenciaId;
}
private static List<String> pessoaList = new ArrayList<String>();
@ -99,8 +99,8 @@ public class PtovtaAgenciaBancaria implements Serializable {
tpContaList.add("POUPANÇA");
}
public PtovtaAgenciaBancaria(Integer id, String numagencia, String digito, String numconta, String pessoa, String tipo, String bilhetes, String carga, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaAgencia(Integer ptovtaAgenciaId, String numagencia, String digito, String numconta, String pessoa, String tipo, String bilhetes, String carga, Boolean activo, Date fecmodif, int usuarioId) {
this.ptovtaAgenciaId = ptovtaAgenciaId;
this.numagencia = numagencia;
this.numconta = numconta;
this.digito = digito;
@ -113,12 +113,14 @@ public class PtovtaAgenciaBancaria implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaAgenciaId() {
return ptovtaAgenciaId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaAgenciaId(Integer ptovtaAgenciaId) {
this.ptovtaAgenciaId = ptovtaAgenciaId;
}
public String getNumagencia() {
@ -203,12 +205,12 @@ public class PtovtaAgenciaBancaria implements Serializable {
public PtovtaBanco getBancoId() {
return bancoId;
public InstiFinanceira getInstiFinanceiraId() {
return instiFinanceiraId;
}
public void setBancoId(PtovtaBanco bancoId) {
this.bancoId = bancoId;
public void setInstiFinanceiraId(InstiFinanceira instiFinanceiraId) {
this.instiFinanceiraId = instiFinanceiraId;
}
public List<PuntoVenta> getPuntoVentaList() {
@ -231,18 +233,18 @@ public class PtovtaAgenciaBancaria implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaAgenciaId != null ? ptovtaAgenciaId.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaAgenciaBancaria)) {
if (!(object instanceof PtovtaAgencia)) {
return false;
}
PtovtaAgenciaBancaria other = (PtovtaAgenciaBancaria) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
PtovtaAgencia other = (PtovtaAgencia) object;
if ((this.ptovtaAgenciaId == null && other.ptovtaAgenciaId != null) || (this.ptovtaAgenciaId != null && !this.ptovtaAgenciaId.equals(other.ptovtaAgenciaId))) {
return false;
}
return true;
@ -250,7 +252,7 @@ public class PtovtaAgenciaBancaria implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaAgencia[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaAgencia[ ptovtaAgenciaId=" + ptovtaAgenciaId + " ]";
}
}

View File

@ -35,8 +35,8 @@ public class PtovtaAntecipacomissao implements Serializable {
@Id
@Basic(optional = false)
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_ANTECIPACOMISSAO_SEQ")
@Column(name = "ID")
private Integer id;
@Column(name = " PTOVTAANTECIPACOMISSAO_ID")
private Integer ptovtaAntecipaComissaoId;
@Column(name = "DATA")
@Temporal(TemporalType.TIMESTAMP)
@ -57,6 +57,7 @@ public class PtovtaAntecipacomissao implements Serializable {
@Column(name = "USUARIO_ID")
private int usuarioId;
@JoinColumn(name = "PUNTOVENTA_ID", referencedColumnName = "PUNTOVENTA_ID")
@ManyToOne
private PuntoVenta puntoventaId;
@ -64,12 +65,12 @@ public class PtovtaAntecipacomissao implements Serializable {
public PtovtaAntecipacomissao() {
}
public PtovtaAntecipacomissao(Integer id) {
this.id = id;
public PtovtaAntecipacomissao(Integer ptovtaAntecipaComissaoId) {
this.ptovtaAntecipaComissaoId = ptovtaAntecipaComissaoId;
}
public PtovtaAntecipacomissao(Integer id, Date data, BigDecimal retem, BigDecimal percentual, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaAntecipacomissao(Integer ptovtaAntecipaComissaoId, Date data, BigDecimal retem, BigDecimal percentual, Boolean activo, Date fecmodif, int usuarioId) {
this.ptovtaAntecipaComissaoId = ptovtaAntecipaComissaoId;
this.data = data;
this.retem = retem;
this.percentual = percentual;
@ -78,12 +79,14 @@ public class PtovtaAntecipacomissao implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaAntecipaComissaoId() {
return ptovtaAntecipaComissaoId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaAntecipaComissaoId(Integer ptovtaAntecipaComissaoId) {
this.ptovtaAntecipaComissaoId = ptovtaAntecipaComissaoId;
}
public Date getData() {
@ -145,7 +148,7 @@ public class PtovtaAntecipacomissao implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaAntecipaComissaoId != null ? ptovtaAntecipaComissaoId.hashCode() : 0);
return hash;
}
@ -156,7 +159,7 @@ public class PtovtaAntecipacomissao implements Serializable {
return false;
}
PtovtaAntecipacomissao other = (PtovtaAntecipacomissao) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaAntecipaComissaoId == null && other.ptovtaAntecipaComissaoId != null) || (this.ptovtaAntecipaComissaoId != null && !this.ptovtaAntecipaComissaoId.equals(other.ptovtaAntecipaComissaoId))) {
return false;
}
return true;
@ -164,7 +167,7 @@ public class PtovtaAntecipacomissao implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaAntecipacomissao[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaAntecipacomissao[ ptovtaAntecipaComissaoId=" + ptovtaAntecipaComissaoId + " ]";
}
}

View File

@ -5,18 +5,22 @@
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@ -26,24 +30,24 @@ import javax.persistence.TemporalType;
* @author Rafael
*/
@Entity
@SequenceGenerator(name = "PTOVTA_COMISSAO_SEQ", sequenceName = "PTOVTA_COMISSAO_SEQ", allocationSize = 1)
@Table(name = "PTOVTA_COMISSAO")
@NamedQueries({
@NamedQuery(name = "PtovtaComissao.findAll", query = "SELECT p FROM PtovtaComissao p")})
public class PtovtaComissao implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_COMISSAO_SEQ")
@Column(name = "PTOVTACOMISSAO_ID")
private Integer ptovtaComissaoId;
@Column(name = "ISSRETIDO")
private int issretido;
private BigDecimal issretido;
@Column(name = "ROYALTIES")
private int royalties;
private BigDecimal royalties;
@Column(name = "ENVIARRECIBO")
private short enviarrecibo;
private Boolean enviarRecibo;
@Column(name = "RECEITA")
private String receita;
@ -51,11 +55,57 @@ public class PtovtaComissao implements Serializable {
@Column(name = "CODAG")
private int codag;
// @Column(name = "DESTINO_ID")
// private String destinoId;
@Column(name = "PASSAGEMALTA")
private BigDecimal passagemAlta;
@Column(name = "PASSAGEMBAIXA")
private BigDecimal passagemBaixa;
@Column(name = "SEGUROALTA")
private BigDecimal seguroAlta;
@Column(name = "SEGUROBAIXA")
private BigDecimal seguroBaixa;
@Column(name = "OUTROSBAIXA")
private BigDecimal outrosBaixa;
@Column(name = " OUTROSALTA")
private BigDecimal outrosAlta;
@Column(name = "EXCESSOALTA")
private BigDecimal excessoAlta;
@Column(name = "EXCESSOBAIXA")
private BigDecimal excessoBaixa;
@Column(name = "TARIFARECEITA")
private Boolean tarifaReceita;
@Column(name = " SEGURORECEITA")
private Boolean seguroReceita;
@Column(name = "TAXARECEITA")
private Boolean taxaReceita;
@Column(name = "PEDAGIORECEITA")
private Boolean pedagioReceita;
@Column(name = " TARIFADEV")
private Boolean tarifaDev;
@Column(name = " SEGURODEV")
private Boolean seguroDev;
@Column(name = "TAXADEV")
private Boolean taxaDev;
@Column(name = "PEDAGIODEV")
private Boolean pegagioDev;
@Column(name = "DESTINO_ID")
private int destinoId;
@Basic(optional = false)
@Column(name = "ACTIVO")
private Boolean activo;
@ -66,10 +116,7 @@ public class PtovtaComissao implements Serializable {
@Column(name = "USUARIO_ID")
private int usuarioId;
@OneToMany(mappedBy = "comissaoId")
private List<PtovtaComposicao> ptovtaComposicaoList;
@OneToMany(mappedBy = "comissaoId")
private List<PtovtaPercentual> ptovtaPercentualList;
@JoinColumn(name = "PUNTOVENTA_ID", referencedColumnName = "PUNTOVENTA_ID")
@ManyToOne
@ -78,53 +125,73 @@ public class PtovtaComissao implements Serializable {
public PtovtaComissao() {
}
public PtovtaComissao(Integer id) {
this.id = id;
public PtovtaComissao(Integer ptovtaComissaoId) {
this.ptovtaComissaoId = ptovtaComissaoId;
}
public PtovtaComissao(Integer id, int issretido, int royalties, short enviarrecibo, String receita, int codag, int destinoId, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaComissao(Integer ptovtaComissaoId, BigDecimal issretido, BigDecimal royalties, Boolean enviarrecibo, String receita, int codag, BigDecimal passagemAlta, BigDecimal passagemBaixa, BigDecimal seguroAlta, BigDecimal seguroBaixa, BigDecimal outrosBaixa, BigDecimal outrosAlta, BigDecimal excessoAlta, BigDecimal excessoBaixa, Boolean tarifaReceita, Boolean seguroReceita, Boolean taxaReceita, Boolean pedagioReceita, Boolean tarifaDev, Boolean seguroDev, Boolean taxaDev, Boolean pegagioDev, Boolean activo, Date fecmodif, int usuarioId) {
super();
this.ptovtaComissaoId = ptovtaComissaoId;
this.issretido = issretido;
this.royalties = royalties;
this.enviarrecibo = enviarrecibo;
this.enviarRecibo = enviarrecibo;
this.receita = receita;
this.codag = codag;
this.destinoId = destinoId;
//this.destinoId = destinoId;
this.passagemAlta = passagemAlta;
this.passagemBaixa = passagemBaixa;
this.seguroAlta = seguroAlta;
this.seguroBaixa = seguroBaixa;
this.outrosBaixa = outrosBaixa;
this.outrosAlta = outrosAlta;
this.excessoAlta = excessoAlta;
this.excessoBaixa = excessoBaixa;
this.tarifaReceita = tarifaReceita;
this.seguroReceita = seguroReceita;
this.taxaReceita = taxaReceita;
this.pedagioReceita = pedagioReceita;
this.tarifaDev = tarifaDev;
this.seguroDev = seguroDev;
this.taxaDev = taxaDev;
this.pegagioDev = pegagioDev;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaComissaoId() {
return ptovtaComissaoId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaComissaoId(Integer ptovtaComissaoId) {
this.ptovtaComissaoId = ptovtaComissaoId;
}
public int getIssretido() {
public BigDecimal getIssretido() {
return issretido;
}
public void setIssretido(int issretido) {
public void setIssretido(BigDecimal issretido) {
this.issretido = issretido;
}
public int getRoyalties() {
public BigDecimal getRoyalties() {
return royalties;
}
public void setRoyalties(int royalties) {
public void setRoyalties(BigDecimal royalties) {
this.royalties = royalties;
}
public short getEnviarrecibo() {
return enviarrecibo;
public Boolean getEnviarrecibo() {
return enviarRecibo;
}
public void setEnviarrecibo(short enviarrecibo) {
this.enviarrecibo = enviarrecibo;
public void setEnviarrecibo(Boolean enviarRecibo) {
this.enviarRecibo = enviarRecibo;
}
public String getReceita() {
@ -143,12 +210,140 @@ public class PtovtaComissao implements Serializable {
this.codag = codag;
}
public int getDestinoId() {
return destinoId;
// public String getDestinoId() {
// return destinoId;
// }
//
// public void setDestinoId(String destinoId) {
// this.destinoId = destinoId;
// }
public BigDecimal getPassagemAlta() {
return passagemAlta;
}
public void setDestinoId(int destinoId) {
this.destinoId = destinoId;
public void setPassagemAlta(BigDecimal passagemAlta) {
this.passagemAlta = passagemAlta;
}
public BigDecimal getPassagemBaixa() {
return passagemBaixa;
}
public void setPassagemBaixa(BigDecimal passagemBaixa) {
this.passagemBaixa = passagemBaixa;
}
public BigDecimal getSeguroAlta() {
return seguroAlta;
}
public void setSeguroAlta(BigDecimal seguroAlta) {
this.seguroAlta = seguroAlta;
}
public BigDecimal getSeguroBaixa() {
return seguroBaixa;
}
public void setSeguroBaixa(BigDecimal seguroBaixa) {
this.seguroBaixa = seguroBaixa;
}
public BigDecimal getOutrosBaixa() {
return outrosBaixa;
}
public void setOutrosBaixa(BigDecimal outrosBaixa) {
this.outrosBaixa = outrosBaixa;
}
public BigDecimal getOutrosAlta() {
return outrosAlta;
}
public void setOutrosAlta(BigDecimal outrosAlta) {
this.outrosAlta = outrosAlta;
}
public BigDecimal getExcessoAlta() {
return excessoAlta;
}
public void setExcessoAlta(BigDecimal excessoAlta) {
this.excessoAlta = excessoAlta;
}
public BigDecimal getExcessoBaixa() {
return excessoBaixa;
}
public void setExcessoBaixa(BigDecimal excessoBaixa) {
this.excessoBaixa = excessoBaixa;
}
public Boolean getTarifaReceita() {
return tarifaReceita;
}
public void setTarifaReceita(Boolean tarifaReceita) {
this.tarifaReceita = tarifaReceita;
}
public Boolean getSeguroReceita() {
return seguroReceita;
}
public void setSeguroReceita(Boolean seguroReceita) {
this.seguroReceita = seguroReceita;
}
public Boolean getTaxaReceita() {
return taxaReceita;
}
public void setTaxaReceita(Boolean taxaReceita) {
this.taxaReceita = taxaReceita;
}
public Boolean getPedagioReceita() {
return pedagioReceita;
}
public void setPedagioReceita(Boolean pedagioReceita) {
this.pedagioReceita = pedagioReceita;
}
public Boolean getTarifaDev() {
return tarifaDev;
}
public void setTarifaDev(Boolean tarifaDev) {
this.tarifaDev = tarifaDev;
}
public Boolean getSeguroDev() {
return seguroDev;
}
public void setSeguroDev(Boolean seguroDev) {
this.seguroDev = seguroDev;
}
public Boolean getTaxaDev() {
return taxaDev;
}
public void setTaxaDev(Boolean taxaDev) {
this.taxaDev = taxaDev;
}
public Boolean getPegagioDev() {
return pegagioDev;
}
public void setPegagioDev(Boolean pegagioDev) {
this.pegagioDev = pegagioDev;
}
public Boolean getActivo() {
@ -186,27 +381,12 @@ public class PtovtaComissao implements Serializable {
}
public List<PtovtaComposicao> getPtovtaComposicaoList() {
return ptovtaComposicaoList;
}
public void setPtovtaComposicaoList(List<PtovtaComposicao> ptovtaComposicaoList) {
this.ptovtaComposicaoList = ptovtaComposicaoList;
}
public List<PtovtaPercentual> getPtovtaPercentualList() {
return ptovtaPercentualList;
}
public void setPtovtaPercentualList(List<PtovtaPercentual> ptovtaPercentualList) {
this.ptovtaPercentualList = ptovtaPercentualList;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaComissaoId != null ? ptovtaComissaoId.hashCode() : 0);
return hash;
}
@ -217,7 +397,7 @@ public class PtovtaComissao implements Serializable {
return false;
}
PtovtaComissao other = (PtovtaComissao) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaComissaoId == null && other.ptovtaComissaoId != null) || (this.ptovtaComissaoId != null && !this.ptovtaComissaoId.equals(other.ptovtaComissaoId))) {
return false;
}
return true;
@ -225,7 +405,7 @@ public class PtovtaComissao implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaComissao[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaComissao[ ptovtaComissaoId=" + ptovtaComissaoId + " ]";
}
}

View File

@ -1,154 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;
/**
*
* @author Rafael
*/
@Entity
@Table(name = "PTOVTA_COMPOSICAO")
@NamedQueries({
@NamedQuery(name = "PtovtaComposicao.findAll", query = "SELECT p FROM PtovtaComposicao p")})
public class PtovtaComposicao implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Basic(optional = false)
@Column(name = "DESCRICAO")
private String descricao;
@Basic(optional = false)
@Column(name = "TIPOCOMPOSICAO")
private String tipocomposicao;
@Basic(optional = false)
@Column(name = "ACTIVO")
private short activo;
@Basic(optional = false)
@Column(name = "FECMODIF")
private int fecmodif;
@Basic(optional = false)
@Column(name = "USUARIO_ID")
private int usuarioId;
@JoinColumn(name = "COMISSAO_ID", referencedColumnName = "ID")
@ManyToOne
private PtovtaComissao comissaoId;
public PtovtaComposicao() {
}
public PtovtaComposicao(Integer id) {
this.id = id;
}
public PtovtaComposicao(Integer id, String descricao, String tipocomposicao, short activo, int fecmodif, int usuarioId) {
this.id = id;
this.descricao = descricao;
this.tipocomposicao = tipocomposicao;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getDescricao() {
return descricao;
}
public void setDescricao(String descricao) {
this.descricao = descricao;
}
public String getTipocomposicao() {
return tipocomposicao;
}
public void setTipocomposicao(String tipocomposicao) {
this.tipocomposicao = tipocomposicao;
}
public short getActivo() {
return activo;
}
public void setActivo(short activo) {
this.activo = activo;
}
public int getFecmodif() {
return fecmodif;
}
public void setFecmodif(int fecmodif) {
this.fecmodif = fecmodif;
}
public int getUsuarioId() {
return usuarioId;
}
public void setUsuarioId(int usuarioId) {
this.usuarioId = usuarioId;
}
public PtovtaComissao getComissaoId() {
return comissaoId;
}
public void setComissaoId(PtovtaComissao comissaoId) {
this.comissaoId = comissaoId;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaComposicao)) {
return false;
}
PtovtaComposicao other = (PtovtaComposicao) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
return false;
}
return true;
}
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaComposicao[ id=" + id + " ]";
}
}

View File

@ -11,12 +11,15 @@ import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@ -26,29 +29,52 @@ import javax.persistence.TemporalType;
* @author Rafael
*/
@Entity
@SequenceGenerator(name = "PTOVTA_DIVERSOS_SEQ", sequenceName = "PTOVTA_DIVERSOS_SEQ", allocationSize = 1)
@Table(name = "PTOVTA_DIVERSOS")
@NamedQueries({
@NamedQuery(name = "PtovtaDiversos.findAll", query = "SELECT p FROM PtovtaDiversos p")})
public class PtovtaDiversos implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_DIVERSOS_SEQ")
@Column(name = "PTOVTADIVERSOS_ID ")
private Integer ptovtaDiversosId;
@Column(name = "RESPON_ALUGUEL")
@Column(name = "RESPONALUGUEL")
private String responAluguel;
@Column(name = "RESPON_TELEFONE")
@Column(name = "RESPONTELEFONE")
private String responTelefone;
@Column(name = "RESPON_ENERGIA")
@Column(name = "RESPONENERGIA")
private String responEnergia;
@Column(name = "POSICAO")
private String posicao;
@Basic(optional = false)
@Column(name = "INFORMATIZADA")
private Boolean informatizada;
@Column(name = "BILHETEINFO")
private Boolean bilheteInfo;
@Column(name = "VENDAINTERNET")
private Boolean vendaInternet;
@Column(name = "DIGITACAOSEQ")
private Boolean digitacaoSeq;
@Column(name = "TELEENTREGA")
private Boolean teleEntrega;
@Column(name = "TRABALHABILHETE")
private Boolean trabalhaBilhete;
@Column(name = "TRABOFPSPROPRIA")
private Boolean ofpsPropria;
@Column(name = "TRABOFPSTERCEIROS")
private Boolean ofpsTerceiros;
@Column(name = "ACTIVO")
private Boolean activo;
@ -59,8 +85,7 @@ public class PtovtaDiversos implements Serializable {
@Column(name = "USUARIO_ID")
private int usuarioId;
@OneToMany(mappedBy = "diversosId")
private List<PtovtaInformacao> ptovtaInformacaoList;
@JoinColumn(name = "PUNTOVENTA_ID", referencedColumnName = "PUNTOVENTA_ID")
@ManyToOne
@ -69,27 +94,35 @@ public class PtovtaDiversos implements Serializable {
public PtovtaDiversos() {
}
public PtovtaDiversos(Integer id) {
this.id = id;
}
public PtovtaDiversos(Integer id, String responAluguel, String responTelefone, String responEnergia, String posicao, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaDiversos(Integer ptovtaDiversosId, String responAluguel, String responTelefone, String responEnergia, String posicao, Boolean informatizada, Boolean bilheteInfo, Boolean vendaInternet, Boolean digitacaoSeq, Boolean teleEntrega, Boolean trabalhaBilhete, Boolean ofpsPropria, Boolean ofpsTerceiros, Boolean activo, Date fecmodif, int usuarioId) {
super();
this.ptovtaDiversosId = ptovtaDiversosId;
this.responAluguel = responAluguel;
this.responTelefone = responTelefone;
this.responEnergia = responEnergia;
this.posicao = posicao;
this.informatizada = informatizada;
this.bilheteInfo = bilheteInfo;
this.vendaInternet = vendaInternet;
this.digitacaoSeq = digitacaoSeq;
this.teleEntrega = teleEntrega;
this.trabalhaBilhete = trabalhaBilhete;
this.ofpsPropria = ofpsPropria;
this.ofpsTerceiros = ofpsTerceiros;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaDiversosId() {
return ptovtaDiversosId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaDiversosId(Integer ptovtaDiversosId) {
this.ptovtaDiversosId = ptovtaDiversosId;
}
public String getResponAluguel() {
@ -124,6 +157,71 @@ public class PtovtaDiversos implements Serializable {
this.posicao = posicao;
}
public Boolean getInformatizada() {
return informatizada;
}
public void setInformatizada(Boolean informatizada) {
this.informatizada = informatizada;
}
public Boolean getBilheteInfo() {
return bilheteInfo;
}
public void setBilheteInfo(Boolean bilheteInfo) {
this.bilheteInfo = bilheteInfo;
}
public Boolean getVendaInternet() {
return vendaInternet;
}
public void setVendaInternet(Boolean vendaInternet) {
this.vendaInternet = vendaInternet;
}
public Boolean getDigitacaoSeq() {
return digitacaoSeq;
}
public void setDigitacaoSeq(Boolean digitacaoSeq) {
this.digitacaoSeq = digitacaoSeq;
}
public Boolean getTeleEntrega() {
return teleEntrega;
}
public void setTeleEntrega(Boolean teleEntrega) {
this.teleEntrega = teleEntrega;
}
public Boolean getTrabalhaBilhete() {
return trabalhaBilhete;
}
public void setTrabalhaBilhete(Boolean trabalhaBilhete) {
this.trabalhaBilhete = trabalhaBilhete;
}
public Boolean getOfpsPropria() {
return ofpsPropria;
}
public void setOfpsPropria(Boolean ofpsPropria) {
this.ofpsPropria = ofpsPropria;
}
public Boolean getOfpsTerceiros() {
return ofpsTerceiros;
}
public void setOfpsTerceiros(Boolean ofpsTerceiros) {
this.ofpsTerceiros = ofpsTerceiros;
}
public Boolean getActivo() {
return activo;
}
@ -158,14 +256,11 @@ public class PtovtaDiversos implements Serializable {
this.puntoventaId = puntoventaId;
}
public List<PtovtaInformacao> getPtovtaInformacaoList() {
return ptovtaInformacaoList;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaDiversosId != null ? ptovtaDiversosId.hashCode() : 0);
return hash;
}
@ -176,7 +271,7 @@ public class PtovtaDiversos implements Serializable {
return false;
}
PtovtaDiversos other = (PtovtaDiversos) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaDiversosId == null && other.ptovtaDiversosId != null) || (this.ptovtaDiversosId != null && !this.ptovtaDiversosId.equals(other.ptovtaDiversosId))) {
return false;
}
return true;
@ -184,7 +279,7 @@ public class PtovtaDiversos implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaDiversos[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaDiversos[ ptovtaDiversosId=" + ptovtaDiversosId + " ]";
}
}

View File

@ -5,6 +5,7 @@
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@ -12,11 +13,14 @@ import java.util.List;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
@ -26,27 +30,28 @@ import javax.persistence.TemporalType;
* @author Rafael
*/
@Entity
@SequenceGenerator(name = "PTOVTA_ESTOQUE_SEQ ", sequenceName = "PTOVTA_ESTOQUE_SEQ ", allocationSize = 1)
@Table(name = "PTOVTA_ESTOQUE")
@NamedQueries({
@NamedQuery(name = "PtovtaEstoque.findAll", query = "SELECT p FROM PtovtaEstoque p")})
public class PtovtaEstoque implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_ESTOQUE_SEQ ")
@Column(name = "PTOVTAESTOQUE_ID")
private Integer ptovtaEstoqueId;
@Column(name = "ESPECIE")
private String especie;
@Column(name = "FORM_CONT")
private short formCont;
@Column(name = "FORMCONT")
private String formCont;
@Column(name = "QUANTIDADE")
private long quantidade;
private int quantidade;
@Column(name = "LOTEFORM")
private long loteform;
private String loteform;
@Basic(optional = false)
@Column(name = "ACTIVO")
@ -65,8 +70,8 @@ public class PtovtaEstoque implements Serializable {
public PtovtaEstoque() {
}
public PtovtaEstoque(Integer id) {
this.id = id;
public PtovtaEstoque(Integer ptovtaEstoqueId) {
this.ptovtaEstoqueId = ptovtaEstoqueId;
}
@ -81,8 +86,8 @@ public class PtovtaEstoque implements Serializable {
loteList.add("NÃO");
}
public PtovtaEstoque(Integer id, String especie, short formCont, long quantidade, long loteform, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaEstoque(Integer ptovtaEstoqueId, String especie, String formCont, int quantidade, String loteform, Boolean activo, Date fecmodif, int usuarioId) {
this.ptovtaEstoqueId = ptovtaEstoqueId;
this.especie = especie;
this.formCont = formCont;
this.quantidade = quantidade;
@ -92,12 +97,14 @@ public class PtovtaEstoque implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaEstoqueId() {
return ptovtaEstoqueId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaEstoqueId(Integer ptovtaEstoqueId) {
this.ptovtaEstoqueId = ptovtaEstoqueId;
}
public String getEspecie() {
@ -108,27 +115,27 @@ public class PtovtaEstoque implements Serializable {
this.especie = especie;
}
public short getFormCont() {
public String getFormCont() {
return formCont;
}
public void setFormCont(short formCont) {
public void setFormCont(String formCont) {
this.formCont = formCont;
}
public long getQuantidade() {
public int getQuantidade() {
return quantidade;
}
public void setQuantidade(long quantidade) {
public void setQuantidade(int quantidade) {
this.quantidade = quantidade;
}
public long getLoteform() {
public String getLoteform() {
return loteform;
}
public void setLoteform(long loteform) {
public void setLoteform(String loteform) {
this.loteform = loteform;
}
@ -185,7 +192,7 @@ public class PtovtaEstoque implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaEstoqueId != null ? ptovtaEstoqueId.hashCode() : 0);
return hash;
}
@ -196,7 +203,7 @@ public class PtovtaEstoque implements Serializable {
return false;
}
PtovtaEstoque other = (PtovtaEstoque) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaEstoqueId == null && other.ptovtaEstoqueId != null) || (this.ptovtaEstoqueId != null && !this.ptovtaEstoqueId.equals(other.ptovtaEstoqueId))) {
return false;
}
return true;
@ -204,7 +211,7 @@ public class PtovtaEstoque implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaEstoque[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaEstoque[ ptovtaEstoqueId=" + ptovtaEstoqueId + " ]";
}
}

View File

@ -34,8 +34,8 @@ public class PtovtaHorario implements Serializable {
@Id
@Basic(optional = false)
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_HORARIO_SEQ")
@Column(name = "ID")
private Integer id;
@Column(name = "PTOVTAHORARIO_ID")
private Integer ptovtaHorarioId;
@Column(name = "INICIO")
@Temporal(TemporalType.TIMESTAMP)
@ -45,7 +45,7 @@ public class PtovtaHorario implements Serializable {
@Temporal(TemporalType.TIMESTAMP)
private Date fim;
@Basic(optional = false)
@Column(name = "ACTIVO")
private Boolean activo;
@ -62,12 +62,12 @@ public class PtovtaHorario implements Serializable {
public PtovtaHorario() {
}
public PtovtaHorario(Integer id) {
this.id = id;
public PtovtaHorario(Integer ptovtaHorarioId) {
this.ptovtaHorarioId = ptovtaHorarioId;
}
public PtovtaHorario(Integer id, Date inicio, Date fim, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaHorario(Integer ptovtaHorarioId, Date inicio, Date fim, Boolean activo, Date fecmodif, int usuarioId) {
this.ptovtaHorarioId = ptovtaHorarioId;
this.inicio = inicio;
this.fim = fim;
this.activo = activo;
@ -75,12 +75,14 @@ public class PtovtaHorario implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaHorarioId() {
return ptovtaHorarioId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaHorarioId(Integer ptovtaHorarioId) {
this.ptovtaHorarioId = ptovtaHorarioId;
}
public Date getInicio() {
@ -134,7 +136,7 @@ public class PtovtaHorario implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaHorarioId != null ? ptovtaHorarioId.hashCode() : 0);
return hash;
}
@ -145,7 +147,7 @@ public class PtovtaHorario implements Serializable {
return false;
}
PtovtaHorario other = (PtovtaHorario) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaHorarioId == null && other.ptovtaHorarioId != null) || (this.ptovtaHorarioId != null && !this.ptovtaHorarioId.equals(other.ptovtaHorarioId))) {
return false;
}
return true;
@ -153,7 +155,7 @@ public class PtovtaHorario implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaHorario[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaHorario[ ptovtaHorarioId=" + ptovtaHorarioId + " ]";
}
}

View File

@ -1,157 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.util.Date;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
/**
*
* @author Rafael
*/
@Entity
@Table(name = "PTOVTA_INFORMACAO")
@NamedQueries({
@NamedQuery(name = "PtovtaInformacao.findAll", query = "SELECT p FROM PtovtaInformacao p")})
public class PtovtaInformacao implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Column(name = "DESCRICAO")
private String descricao;
@Basic(optional = false)
@Column(name = "ACTIVO")
private Boolean activo;
@Column(name = "FECMODIF")
@Temporal(TemporalType.TIMESTAMP)
private Date fecmodif;
@Column(name = "USUARIO_ID")
private int usuarioId;
@JoinColumn(name = "PUNTOVENTA_ID", referencedColumnName = "PUNTOVENTA_ID")
@ManyToOne
private PuntoVenta puntoventaId;
@JoinColumn(name = "DIVERSOS_ID", referencedColumnName = "ID")
@ManyToOne
private PtovtaDiversos diversosId;
public PtovtaInformacao() {
}
public PtovtaInformacao(Integer id) {
this.id = id;
}
public PtovtaInformacao(Integer id, String descricao, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
this.descricao = descricao;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getDescricao() {
return descricao;
}
public void setDescricao(String descricao) {
this.descricao = descricao;
}
public Boolean getActivo() {
return activo;
}
public void setActivo(Boolean activo) {
this.activo = activo;
}
public Date getFecmodif() {
return fecmodif;
}
public void setFecmodif(Date fecmodif) {
this.fecmodif = fecmodif;
}
public int getUsuarioId() {
return usuarioId;
}
public void setUsuarioId(int usuarioId) {
this.usuarioId = usuarioId;
}
public PuntoVenta getPuntoventaId() {
return puntoventaId;
}
public void setPuntoventaId(PuntoVenta puntoventaId) {
this.puntoventaId = puntoventaId;
}
public PtovtaDiversos getDiversosId() {
return diversosId;
}
public void setDiversosId(PtovtaDiversos diversosId) {
this.diversosId = diversosId;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaInformacao)) {
return false;
}
PtovtaInformacao other = (PtovtaInformacao) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
return false;
}
return true;
}
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaInformacao[ id=" + id + " ]";
}
}

View File

@ -1,167 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.util.Date;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
/**
*
* @author Rafael
*/
@Entity
@Table(name = "PTOVTA_PERCENTUAL")
@NamedQueries({
@NamedQuery(name = "PtovtaPercentual.findAll", query = "SELECT p FROM PtovtaPercentual p")})
public class PtovtaPercentual implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Column(name = "BAIXAESTACAO")
private int baixaestacao;
@Column(name = "ALTAESTACAO")
private int altaestacao;
@Basic(optional = false)
@Column(name = "ACTIVO")
private Boolean activo;
@Column(name = "FECMODIF")
@Temporal(TemporalType.TIMESTAMP)
private Date fecmodif;
@Column(name = "USUARIO_ID")
private int usuarioId;
@JoinColumn(name = "IDTIPOPERCENT", referencedColumnName = "ID")
@ManyToOne
private PtovtaTipoPercentual idtipopercent;
@JoinColumn(name = "COMISSAO_ID", referencedColumnName = "ID")
@ManyToOne
private PtovtaComissao comissaoId;
public PtovtaPercentual() {
}
public PtovtaPercentual(Integer id) {
this.id = id;
}
public PtovtaPercentual(Integer id, int baixaestacao, int altaestacao, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
this.baixaestacao = baixaestacao;
this.altaestacao = altaestacao;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public int getBaixaestacao() {
return baixaestacao;
}
public void setBaixaestacao(int baixaestacao) {
this.baixaestacao = baixaestacao;
}
public int getAltaestacao() {
return altaestacao;
}
public void setAltaestacao(int altaestacao) {
this.altaestacao = altaestacao;
}
public Boolean getActivo() {
return activo;
}
public void setActivo(Boolean activo) {
this.activo = activo;
}
public Date getFecmodif() {
return fecmodif;
}
public void setFecmodif(Date fecmodif) {
this.fecmodif = fecmodif;
}
public int getUsuarioId() {
return usuarioId;
}
public void setUsuarioId(int usuarioId) {
this.usuarioId = usuarioId;
}
public PtovtaTipoPercentual getIdtipopercent() {
return idtipopercent;
}
public void setIdtipopercent(PtovtaTipoPercentual idtipopercent) {
this.idtipopercent = idtipopercent;
}
public PtovtaComissao getComissaoId() {
return comissaoId;
}
public void setComissaoId(PtovtaComissao comissaoId) {
this.comissaoId = comissaoId;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaPercentual)) {
return false;
}
PtovtaPercentual other = (PtovtaPercentual) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
return false;
}
return true;
}
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaPercentual[ id=" + id + " ]";
}
}

View File

@ -1,141 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.entidad;
import java.io.Serializable;
import java.util.Date;
import java.util.List;
import javax.persistence.Basic;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
/**
*
* @author Rafael
*/
@Entity
@Table(name = "PTOVTA_TIPO_PERCENTUAL")
@NamedQueries({
@NamedQuery(name = "PtovtaTipoPercentual.findAll", query = "SELECT p FROM PtovtaTipoPercentual p")})
public class PtovtaTipoPercentual implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Column(name = "DESCRICAO")
private String descricao;
@Basic(optional = false)
@Column(name = "ACTIVO")
private Boolean activo;
@Column(name = "FECMODIF")
@Temporal(TemporalType.TIMESTAMP)
private Date fecmodif;
@Column(name = "USUARIO_ID")
private int usuarioId;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "idtipopercent")
private List<PtovtaPercentual> ptovtaPercentualList;
public PtovtaTipoPercentual() {
}
public PtovtaTipoPercentual(Integer id) {
this.id = id;
}
public PtovtaTipoPercentual(Integer id, String descricao, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
this.descricao = descricao;
this.activo = activo;
this.fecmodif = fecmodif;
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getDescricao() {
return descricao;
}
public void setDescricao(String descricao) {
this.descricao = descricao;
}
public Boolean getActivo() {
return activo;
}
public void setActivo(Boolean activo) {
this.activo = activo;
}
public Date getFecmodif() {
return fecmodif;
}
public void setFecmodif(Date fecmodif) {
this.fecmodif = fecmodif;
}
public int getUsuarioId() {
return usuarioId;
}
public void setUsuarioId(int usuarioId) {
this.usuarioId = usuarioId;
}
public List<PtovtaPercentual> getPtovtaPercentualList() {
return ptovtaPercentualList;
}
public void setPtovtaPercentualList(List<PtovtaPercentual> ptovtaPercentualList) {
this.ptovtaPercentualList = ptovtaPercentualList;
}
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
return hash;
}
@Override
public boolean equals(Object object) {
// TODO: Warning - this method won't work in the case the id fields are not set
if (!(object instanceof PtovtaTipoPercentual)) {
return false;
}
PtovtaTipoPercentual other = (PtovtaTipoPercentual) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
return false;
}
return true;
}
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaTipoPercentual[ id=" + id + " ]";
}
}

View File

@ -38,8 +38,8 @@ public class PtovtaTitular implements Serializable {
@Id
@Basic(optional = false)
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_TITULAR_SEQ ")
@Column(name = "ID")
private Integer id;
@Column(name = "PTOVTATITULAR_ID")
private Integer ptovtaTitularId;
@Column(name = "NOME")
private String nome;
@ -72,12 +72,12 @@ public class PtovtaTitular implements Serializable {
public PtovtaTitular() {
}
public PtovtaTitular(Integer id) {
this.id = id;
public PtovtaTitular(Integer ptovtaTitularId) {
this.ptovtaTitularId = ptovtaTitularId;
}
public PtovtaTitular(Integer id, String nome, String cpf, String rg, String orgaoemissor, Boolean activo, Date fecmodif, int usuarioId) {
this.id = id;
public PtovtaTitular(Integer ptovtaTitularId, String nome, String cpf, String rg, String orgaoemissor, Boolean activo, Date fecmodif, int usuarioId) {
this.ptovtaTitularId = ptovtaTitularId;
this.nome = nome;
this.cpf = cpf;
this.rg = rg;
@ -87,12 +87,14 @@ public class PtovtaTitular implements Serializable {
this.usuarioId = usuarioId;
}
public Integer getId() {
return id;
public Integer getPtovtaTitularId() {
return ptovtaTitularId;
}
public void setId(Integer id) {
this.id = id;
public void setPtovtaTitularId(Integer ptovtaTitularId) {
this.ptovtaTitularId = ptovtaTitularId;
}
public String getNome() {
@ -171,7 +173,7 @@ public class PtovtaTitular implements Serializable {
@Override
public int hashCode() {
int hash = 0;
hash += (id != null ? id.hashCode() : 0);
hash += (ptovtaTitularId != null ? ptovtaTitularId.hashCode() : 0);
return hash;
}
@ -182,7 +184,7 @@ public class PtovtaTitular implements Serializable {
return false;
}
PtovtaTitular other = (PtovtaTitular) object;
if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
if ((this.ptovtaTitularId == null && other.ptovtaTitularId != null) || (this.ptovtaTitularId != null && !this.ptovtaTitularId.equals(other.ptovtaTitularId))) {
return false;
}
return true;
@ -190,7 +192,7 @@ public class PtovtaTitular implements Serializable {
@Override
public String toString() {
return "com.rjconsultores.ventaboletos.entidad.PtovtaTitular[ id=" + id + " ]";
return "com.rjconsultores.ventaboletos.entidad.PtovtaTitular[ ptovtaTitularId=" + ptovtaTitularId + " ]";
}
}

View File

@ -108,30 +108,49 @@ public class PuntoVenta implements Serializable {
private String numfax;
@Column(name = "COMPL")
private String compl;
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
// private List<PtovtaEstoque> ptovtaEstoqueList;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
private List<PtovtaEstoque> ptovtaEstoqueList;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
private List<PtovtaHorario> ptovtaHorarioList;
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
// private List<PtovtaComissao> ptovtaComissaoList;
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
// private List<PtovtaDiversos> ptovtaDiversosList;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
private List<PtovtaAntecipacomissao> ptovtaAntecipacomissaoList;
//@JoinColumn(name = "AGENCIA_ID", referencedColumnName = "ID")
@JoinColumn(name = "AGENCIA_ID")
@JoinColumn(name = "PTOVTACOMISSAO_ID")
@OneToOne(cascade=CascadeType.ALL)
private PtovtaAgenciaBancaria agenciaId;
private PtovtaComissao comissaoId;
@JoinColumn(name = "TITULAR_ID")
@JoinColumn(name = "PTOVTADIVERSOS_ID")
@OneToOne(cascade=CascadeType.ALL)
private PtovtaDiversos diversosId;
@JoinColumn(name = "PTOVTAAGENCIA_ID")
@OneToOne(cascade=CascadeType.ALL)
private PtovtaAgencia agenciaId;
@JoinColumn(name = "PTOVTATITULAR_ID")
@OneToOne(cascade=CascadeType.ALL)
private PtovtaTitular titularId;
public PtovtaComissao getComissaoId() {
return comissaoId;
}
public void setComissaoId(PtovtaComissao comissaoId) {
this.comissaoId = comissaoId;
}
public PtovtaDiversos getDiversosId() {
return diversosId;
}
public void setDiversosId(PtovtaDiversos diversosId) {
this.diversosId = diversosId;
}
public PtovtaTitular getTitularId() {
return titularId;
}
@ -140,18 +159,20 @@ public class PuntoVenta implements Serializable {
this.titularId = titularId;
}
public PtovtaAgenciaBancaria getAgenciaId() {
public PtovtaAgencia getAgenciaId() {
return agenciaId;
}
public void setAgenciaId(PtovtaAgenciaBancaria agenciaId) {
public void setAgenciaId(PtovtaAgencia agenciaId) {
this.agenciaId = agenciaId;
}
public PuntoVenta() {
this.colonia = new Colonia();
this.agenciaId = new PtovtaAgenciaBancaria();
this.agenciaId = new PtovtaAgencia();
this.titularId = new PtovtaTitular();
this.comissaoId = new PtovtaComissao();
this.diversosId = new PtovtaDiversos();
}
public PuntoVenta(Integer puntoventaId) {
@ -369,14 +390,14 @@ public class PuntoVenta implements Serializable {
this.compl = compl;
}
// public List<PtovtaEstoque> getPtovtaEstoqueList() {
// return ptovtaEstoqueList;
// }
//
// public void setPtovtaEstoqueList(List<PtovtaEstoque> ptovtaEstoqueList) {
// this.ptovtaEstoqueList = ptovtaEstoqueList;
// }
//
public List<PtovtaEstoque> getPtovtaEstoqueList() {
return ptovtaEstoqueList;
}
public void setPtovtaEstoqueList(List<PtovtaEstoque> ptovtaEstoqueList) {
this.ptovtaEstoqueList = ptovtaEstoqueList;
}
public List<PtovtaHorario> getPtovtaHorarioList() {

View File

@ -0,0 +1,18 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
public interface InstiFinanceiraService extends GenericService<InstiFinanceira, Integer> {
public List<InstiFinanceira> buscar(String nome);
}

View File

@ -1,18 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgenciaBancaria;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
public interface PtovtaAgenciaBancariaService extends GenericService<PtovtaAgenciaBancaria, Integer> {
public List<PtovtaAgenciaBancaria> buscar(String numagencia);
}

View File

@ -0,0 +1,18 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgencia;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
public interface PtovtaAgenciaService extends GenericService<PtovtaAgencia, Integer> {
public List<PtovtaAgencia> buscar(String numagencia);
}

View File

@ -1,18 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
public interface PtovtaBancoService extends GenericService<PtovtaBanco, Integer> {
public List<PtovtaBanco> buscar(String nome);
}

View File

@ -1,19 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaInformacao;
public interface PtovtaInformacaoService extends GenericService<PtovtaInformacao, Integer> {
public List<PtovtaInformacao> buscar(int id);
}

View File

@ -1,22 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaPercentual;
public interface PtovtaPercentualService extends GenericService<PtovtaPercentual, Integer> {
public List<PtovtaPercentual> buscar(int id);
}

View File

@ -1,18 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service;
import java.util.List;
import com.rjconsultores.ventaboletos.entidad.PtovtaTipoPercentual;
public interface PtovtaTipoPercentualService extends GenericService<PtovtaTipoPercentual, Integer> {
public List<PtovtaTipoPercentual> buscar(int id);
}

View File

@ -4,9 +4,9 @@
*/
package com.rjconsultores.ventaboletos.service.impl;
import com.rjconsultores.ventaboletos.dao.PtovtaBancoDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaBanco;
import com.rjconsultores.ventaboletos.service.PtovtaBancoService;
import com.rjconsultores.ventaboletos.dao.InstiFinanceiraDAO;
import com.rjconsultores.ventaboletos.entidad.InstiFinanceira;
import com.rjconsultores.ventaboletos.service.InstiFinanceiraService;
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
import java.util.Calendar;
import java.util.List;
@ -20,21 +20,21 @@ import org.springframework.transaction.annotation.Transactional;
* @author Desenvolvimento
*/
@Service("ptovtaBancoService")
public class PtovtaBancoServiceImpl implements PtovtaBancoService {
public class InstiFinanceiraServiceImpl implements InstiFinanceiraService {
@Autowired
private PtovtaBancoDAO ptovtaBancoDAO;
private InstiFinanceiraDAO ptovtaBancoDAO;
public List<PtovtaBanco> obtenerTodos() {
public List<InstiFinanceira> obtenerTodos() {
return ptovtaBancoDAO.obtenerTodos();
}
public PtovtaBanco obtenerID(Integer id) {
public InstiFinanceira obtenerID(Integer id) {
return ptovtaBancoDAO.obtenerID(id);
}
@Transactional
public PtovtaBanco suscribir(PtovtaBanco entidad) {
public InstiFinanceira suscribir(InstiFinanceira entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
@ -43,7 +43,7 @@ public class PtovtaBancoServiceImpl implements PtovtaBancoService {
}
@Transactional
public PtovtaBanco actualizacion(PtovtaBanco entidad) {
public InstiFinanceira actualizacion(InstiFinanceira entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
@ -52,7 +52,7 @@ public class PtovtaBancoServiceImpl implements PtovtaBancoService {
}
@Transactional
public void borrar(PtovtaBanco entidad) {
public void borrar(InstiFinanceira entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.FALSE);
@ -60,7 +60,7 @@ public class PtovtaBancoServiceImpl implements PtovtaBancoService {
ptovtaBancoDAO.actualizacion(entidad);
}
public List<PtovtaBanco> buscar(String nome) {
public List<InstiFinanceira> buscar(String nome) {
return ptovtaBancoDAO.buscar(nome);
}

View File

@ -4,11 +4,11 @@
*/
package com.rjconsultores.ventaboletos.service.impl;
import com.rjconsultores.ventaboletos.dao.PtovtaAgenciaBancariaDAO;
import com.rjconsultores.ventaboletos.dao.PtovtaAgenciaDAO;
import com.rjconsultores.ventaboletos.entidad.ProdVigencia;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgenciaBancaria;
import com.rjconsultores.ventaboletos.entidad.PtovtaAgencia;
import com.rjconsultores.ventaboletos.service.ProdVigenciaService;
import com.rjconsultores.ventaboletos.service.PtovtaAgenciaBancariaService;
import com.rjconsultores.ventaboletos.service.PtovtaAgenciaService;
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
import java.util.Calendar;
import java.util.List;
@ -22,21 +22,21 @@ import org.springframework.transaction.annotation.Transactional;
* @author Desenvolvimento
*/
@Service("ptovtaAgenciaBancariaService")
public class PtovtaAgenciaBancariaServiceImpl implements PtovtaAgenciaBancariaService {
public class PtovtaAgenciaServiceImpl implements PtovtaAgenciaService {
@Autowired
private PtovtaAgenciaBancariaDAO ptovtaBancoDAO;
private PtovtaAgenciaDAO ptovtaBancoDAO;
public List<PtovtaAgenciaBancaria> obtenerTodos() {
public List<PtovtaAgencia> obtenerTodos() {
return ptovtaBancoDAO.obtenerTodos();
}
public PtovtaAgenciaBancaria obtenerID(Integer id) {
public PtovtaAgencia obtenerID(Integer id) {
return ptovtaBancoDAO.obtenerID(id);
}
@Transactional
public PtovtaAgenciaBancaria suscribir(PtovtaAgenciaBancaria entidad) {
public PtovtaAgencia suscribir(PtovtaAgencia entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
@ -45,7 +45,7 @@ public class PtovtaAgenciaBancariaServiceImpl implements PtovtaAgenciaBancariaSe
}
@Transactional
public PtovtaAgenciaBancaria actualizacion(PtovtaAgenciaBancaria entidad) {
public PtovtaAgencia actualizacion(PtovtaAgencia entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
@ -55,7 +55,7 @@ public class PtovtaAgenciaBancariaServiceImpl implements PtovtaAgenciaBancariaSe
@Transactional
public void borrar(PtovtaAgenciaBancaria entidad) {
public void borrar(PtovtaAgencia entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.FALSE);
@ -64,7 +64,7 @@ public class PtovtaAgenciaBancariaServiceImpl implements PtovtaAgenciaBancariaSe
}
public List<PtovtaAgenciaBancaria> buscar(String numagencia) {
public List<PtovtaAgencia> buscar(String numagencia) {
return ptovtaBancoDAO.buscar(numagencia);
}

View File

@ -1,69 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service.impl;
import com.rjconsultores.ventaboletos.dao.PtovtaInformacaoDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaInformacao;
import com.rjconsultores.ventaboletos.service.PtovtaInformacaoService;
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
import java.util.Calendar;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
/**
*
* @author Desenvolvimento
*/
@Service("ptovtaInformacaoService")
public class PtovtaInformacaoServiceImpl implements PtovtaInformacaoService {
@Autowired
private PtovtaInformacaoDAO ptovtaInformacaoDAO;
public List<PtovtaInformacao> obtenerTodos() {
return ptovtaInformacaoDAO.obtenerTodos();
}
public PtovtaInformacao obtenerID(Integer id) {
return ptovtaInformacaoDAO.obtenerID(id);
}
@Transactional
public PtovtaInformacao suscribir(PtovtaInformacao entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaInformacaoDAO.suscribir(entidad);
}
@Transactional
public PtovtaInformacao actualizacion(PtovtaInformacao entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaInformacaoDAO.actualizacion(entidad);
}
@Transactional
public void borrar(PtovtaInformacao entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.FALSE);
ptovtaInformacaoDAO.actualizacion(entidad);
}
public List<PtovtaInformacao> buscar(int id) {
return ptovtaInformacaoDAO.buscar(id);
}
}

View File

@ -1,69 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service.impl;
import com.rjconsultores.ventaboletos.dao.PtovtaPercentualDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaPercentual;
import com.rjconsultores.ventaboletos.service.PtovtaPercentualService;
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
import java.util.Calendar;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
/**
*
* @author Desenvolvimento
*/
@Service("ptovtaPercentualService")
public class PtovtaPercentualServiceImpl implements PtovtaPercentualService {
@Autowired
private PtovtaPercentualDAO ptovtaPercentualDAO;
public List<PtovtaPercentual> obtenerTodos() {
return ptovtaPercentualDAO.obtenerTodos();
}
public PtovtaPercentual obtenerID(Integer id) {
return ptovtaPercentualDAO.obtenerID(id);
}
@Transactional
public PtovtaPercentual suscribir(PtovtaPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaPercentualDAO.suscribir(entidad);
}
@Transactional
public PtovtaPercentual actualizacion(PtovtaPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaPercentualDAO.actualizacion(entidad);
}
@Transactional
public void borrar(PtovtaPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.FALSE);
ptovtaPercentualDAO.actualizacion(entidad);
}
public List<PtovtaPercentual> buscar(int id) {
return ptovtaPercentualDAO.buscar(id);
}
}

View File

@ -1,69 +0,0 @@
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.rjconsultores.ventaboletos.service.impl;
import com.rjconsultores.ventaboletos.dao.PtovtaTipoPercentualDAO;
import com.rjconsultores.ventaboletos.entidad.PtovtaTipoPercentual;
import com.rjconsultores.ventaboletos.service.PtovtaTipoPercentualService;
import com.rjconsultores.ventaboletos.utilerias.UsuarioLogado;
import java.util.Calendar;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
/**
*
* @author Desenvolvimento
*/
@Service("ptovtaTipoPercentualService")
public class PtovtaTipoPercentualServiceImpl implements PtovtaTipoPercentualService {
@Autowired
private PtovtaTipoPercentualDAO ptovtaTipoPercentualDAO;
public List<PtovtaTipoPercentual> obtenerTodos() {
return ptovtaTipoPercentualDAO.obtenerTodos();
}
public PtovtaTipoPercentual obtenerID(Integer id) {
return ptovtaTipoPercentualDAO.obtenerID(id);
}
@Transactional
public PtovtaTipoPercentual suscribir(PtovtaTipoPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaTipoPercentualDAO.suscribir(entidad);
}
@Transactional
public PtovtaTipoPercentual actualizacion(PtovtaTipoPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.TRUE);
return ptovtaTipoPercentualDAO.actualizacion(entidad);
}
@Transactional
public void borrar(PtovtaTipoPercentual entidad) {
entidad.setUsuarioId(UsuarioLogado.getUsuarioLogado().getUsuarioId());
entidad.setFecmodif(Calendar.getInstance().getTime());
entidad.setActivo(Boolean.FALSE);
ptovtaTipoPercentualDAO.actualizacion(entidad);
}
public List<PtovtaTipoPercentual> buscar(int id) {
return ptovtaTipoPercentualDAO.buscar(id);
}
}