Criação da novas classes relacionada PuntoVenta
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Model/trunk/modelWeb@22224 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
c322fcd1aa
commit
86693139d9
|
@ -13,12 +13,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;
|
||||
|
@ -28,46 +31,50 @@ import javax.persistence.TemporalType;
|
|||
* @author Rafael
|
||||
*/
|
||||
@Entity
|
||||
@Table(name = "PTOVTA_AGENCIABANCARIA")
|
||||
@NamedQueries({
|
||||
@NamedQuery(name = "PtovtaAgenciaBancaria.findAll", query = "SELECT p FROM PtovtaAgenciaBancaria p")})
|
||||
@SequenceGenerator(name = "PTOVTA_AGENCIA_BANCARIA_SEQ", sequenceName = "PTOVTA_AGENCIA_BANCARIA_SEQ", allocationSize = 1)
|
||||
@Table(name = "PTOVTA_AGENCIA_BANCARIA")
|
||||
|
||||
public class PtovtaAgenciaBancaria 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;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "NUMAGENCIA")
|
||||
private String numagencia;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "NUMCONTA")
|
||||
private String numconta;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "DIGITO")
|
||||
private String digito;
|
||||
|
||||
@Column(name = "PESSOA")
|
||||
private String pessoa;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "TIPO")
|
||||
private String tipo;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "BILHETES")
|
||||
private String bilhetes;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "CARGA")
|
||||
private String carga;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "ACTIVO")
|
||||
private Boolean activo;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "FECMODIF")
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
private Date fecmodif;
|
||||
@Basic(optional = false)
|
||||
|
||||
@Column(name = "USUARIO_ID")
|
||||
private int usuarioId;
|
||||
|
||||
@JoinColumn(name = "BANCO_ID", referencedColumnName = "ID")
|
||||
@ManyToOne(optional = false)
|
||||
@ManyToOne
|
||||
private PtovtaBanco bancoId;
|
||||
|
||||
|
||||
|
@ -85,17 +92,18 @@ public class PtovtaAgenciaBancaria implements Serializable {
|
|||
private static List<String> tpContaList = new ArrayList<String>();
|
||||
|
||||
static{
|
||||
pessoaList.add("blue");
|
||||
pessoaList.add("black");
|
||||
pessoaList.add("FÍSICA");
|
||||
pessoaList.add("JURÍDICA");
|
||||
|
||||
tpContaList.add("small");
|
||||
tpContaList.add("medium");
|
||||
tpContaList.add("C/C");
|
||||
tpContaList.add("POUPANÇA");
|
||||
}
|
||||
|
||||
public PtovtaAgenciaBancaria(Integer id, String numagencia, String numconta, String pessoa, String tipo, String bilhetes, String carga, Boolean activo, Date fecmodif, int usuarioId) {
|
||||
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;
|
||||
this.numagencia = numagencia;
|
||||
this.numconta = numconta;
|
||||
this.digito = digito;
|
||||
this.pessoa = pessoa;
|
||||
this.tipo = tipo;
|
||||
this.bilhetes = bilhetes;
|
||||
|
@ -129,7 +137,15 @@ public class PtovtaAgenciaBancaria implements Serializable {
|
|||
this.numconta = numconta;
|
||||
}
|
||||
|
||||
public String getPessoa() {
|
||||
public String getDigito() {
|
||||
return digito;
|
||||
}
|
||||
|
||||
public void setDigito(String digito) {
|
||||
this.digito = digito;
|
||||
}
|
||||
|
||||
public String getPessoa() {
|
||||
return pessoa;
|
||||
}
|
||||
|
||||
|
|
|
@ -9,12 +9,15 @@ import java.util.Date;
|
|||
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.Lob;
|
||||
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;
|
||||
|
@ -25,12 +28,12 @@ import javax.persistence.TemporalType;
|
|||
*/
|
||||
@Entity
|
||||
@Table(name = "PTOVTA_TITULAR")
|
||||
@NamedQueries({
|
||||
@NamedQuery(name = "PtovtaTitular.findAll", query = "SELECT p FROM PtovtaTitular p")})
|
||||
@SequenceGenerator(name = "PTOVTA_TITULAR_SEQ", sequenceName = "PTOVTA_TITULAR_SEQ", allocationSize = 1)
|
||||
public class PtovtaTitular implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
@Id
|
||||
@Basic(optional = false)
|
||||
@GeneratedValue(strategy = GenerationType.AUTO, generator = "PTOVTA_TITULAR_SEQ")
|
||||
@Column(name = "ID")
|
||||
private Integer id;
|
||||
|
||||
|
@ -47,9 +50,9 @@ public class PtovtaTitular implements Serializable {
|
|||
private String orgaoemissor;
|
||||
@Lob
|
||||
@Column(name = "IMAGEM")
|
||||
private Serializable imagem;
|
||||
private byte[] imagem;
|
||||
|
||||
|
||||
@Basic(optional = false)
|
||||
@Column(name = "ACTIVO")
|
||||
private Boolean activo;
|
||||
|
||||
|
@ -121,11 +124,11 @@ public class PtovtaTitular implements Serializable {
|
|||
this.orgaoemissor = orgaoemissor;
|
||||
}
|
||||
|
||||
public Serializable getImagem() {
|
||||
public byte[] getImagem() {
|
||||
return imagem;
|
||||
}
|
||||
|
||||
public void setImagem(Serializable imagem) {
|
||||
public void setImagem(byte[] imagem) {
|
||||
this.imagem = imagem;
|
||||
}
|
||||
|
||||
|
|
|
@ -108,22 +108,51 @@ 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<PtovtaTitular> ptovtaTitularList;
|
||||
@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<PtovtaAgencia> ptovtaAgenciaList;
|
||||
@OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
|
||||
private List<PtovtaAntecipacomissao> ptovtaAntecipacomissaoList;
|
||||
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
|
||||
// private List<PtovtaEstoque> ptovtaEstoqueList;
|
||||
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
|
||||
// private List<PtovtaTitular> ptovtaTitularList;
|
||||
// @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<PtovtaAgenciaBancaria> ptovtaAgenciaList;
|
||||
// @OneToMany(cascade = CascadeType.ALL, mappedBy = "puntoventaId")
|
||||
// private List<PtovtaAntecipacomissao> ptovtaAntecipacomissaoList;
|
||||
|
||||
public PuntoVenta() {
|
||||
|
||||
//@JoinColumn(name = "AGENCIA_ID", referencedColumnName = "ID")
|
||||
@JoinColumn(name = "AGENCIA_ID")
|
||||
@OneToOne(cascade=CascadeType.ALL)
|
||||
private PtovtaAgenciaBancaria agenciaId;
|
||||
|
||||
@JoinColumn(name = "TITULAR_ID")
|
||||
@OneToOne(cascade=CascadeType.ALL)
|
||||
private PtovtaTitular titularId;
|
||||
|
||||
|
||||
|
||||
|
||||
public PtovtaTitular getTitularId() {
|
||||
return titularId;
|
||||
}
|
||||
|
||||
public void setTitularId(PtovtaTitular titularId) {
|
||||
this.titularId = titularId;
|
||||
}
|
||||
|
||||
public PtovtaAgenciaBancaria getAgenciaId() {
|
||||
return agenciaId;
|
||||
}
|
||||
|
||||
public void setAgenciaId(PtovtaAgenciaBancaria agenciaId) {
|
||||
this.agenciaId = agenciaId;
|
||||
}
|
||||
|
||||
public PuntoVenta() {
|
||||
}
|
||||
|
||||
public PuntoVenta(Integer puntoventaId) {
|
||||
|
@ -341,61 +370,61 @@ 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<PtovtaTitular> getPtovtaTitularList() {
|
||||
return ptovtaTitularList;
|
||||
}
|
||||
|
||||
public void setPtovtaTitularList(List<PtovtaTitular> ptovtaTitularList) {
|
||||
this.ptovtaTitularList = ptovtaTitularList;
|
||||
}
|
||||
|
||||
public List<PtovtaHorario> getPtovtaHorarioList() {
|
||||
return ptovtaHorarioList;
|
||||
}
|
||||
|
||||
public void setPtovtaHorarioList(List<PtovtaHorario> ptovtaHorarioList) {
|
||||
this.ptovtaHorarioList = ptovtaHorarioList;
|
||||
}
|
||||
|
||||
public List<PtovtaComissao> getPtovtaComissaoList() {
|
||||
return ptovtaComissaoList;
|
||||
}
|
||||
|
||||
public void setPtovtaComissaoList(List<PtovtaComissao> ptovtaComissaoList) {
|
||||
this.ptovtaComissaoList = ptovtaComissaoList;
|
||||
}
|
||||
|
||||
public List<PtovtaDiversos> getPtovtaDiversosList() {
|
||||
return ptovtaDiversosList;
|
||||
}
|
||||
|
||||
public void setPtovtaDiversosList(List<PtovtaDiversos> ptovtaDiversosList) {
|
||||
this.ptovtaDiversosList = ptovtaDiversosList;
|
||||
}
|
||||
|
||||
public List<PtovtaAgencia> getPtovtaAgenciaList() {
|
||||
return ptovtaAgenciaList;
|
||||
}
|
||||
|
||||
public void setPtovtaAgenciaList(List<PtovtaAgencia> ptovtaAgenciaList) {
|
||||
this.ptovtaAgenciaList = ptovtaAgenciaList;
|
||||
}
|
||||
|
||||
public List<PtovtaAntecipacomissao> getPtovtaAntecipacomissaoList() {
|
||||
return ptovtaAntecipacomissaoList;
|
||||
}
|
||||
|
||||
public void setPtovtaAntecipacomissaoList(List<PtovtaAntecipacomissao> ptovtaAntecipacomissaoList) {
|
||||
this.ptovtaAntecipacomissaoList = ptovtaAntecipacomissaoList;
|
||||
}
|
||||
// public List<PtovtaEstoque> getPtovtaEstoqueList() {
|
||||
// return ptovtaEstoqueList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaEstoqueList(List<PtovtaEstoque> ptovtaEstoqueList) {
|
||||
// this.ptovtaEstoqueList = ptovtaEstoqueList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaTitular> getPtovtaTitularList() {
|
||||
// return ptovtaTitularList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaTitularList(List<PtovtaTitular> ptovtaTitularList) {
|
||||
// this.ptovtaTitularList = ptovtaTitularList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaHorario> getPtovtaHorarioList() {
|
||||
// return ptovtaHorarioList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaHorarioList(List<PtovtaHorario> ptovtaHorarioList) {
|
||||
// this.ptovtaHorarioList = ptovtaHorarioList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaComissao> getPtovtaComissaoList() {
|
||||
// return ptovtaComissaoList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaComissaoList(List<PtovtaComissao> ptovtaComissaoList) {
|
||||
// this.ptovtaComissaoList = ptovtaComissaoList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaDiversos> getPtovtaDiversosList() {
|
||||
// return ptovtaDiversosList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaDiversosList(List<PtovtaDiversos> ptovtaDiversosList) {
|
||||
// this.ptovtaDiversosList = ptovtaDiversosList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaAgenciaBancaria> getPtovtaAgenciaList() {
|
||||
// return ptovtaAgenciaList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaAgenciaList(List<PtovtaAgenciaBancaria> ptovtaAgenciaList) {
|
||||
// this.ptovtaAgenciaList = ptovtaAgenciaList;
|
||||
// }
|
||||
//
|
||||
// public List<PtovtaAntecipacomissao> getPtovtaAntecipacomissaoList() {
|
||||
// return ptovtaAntecipacomissaoList;
|
||||
// }
|
||||
//
|
||||
// public void setPtovtaAntecipacomissaoList(List<PtovtaAntecipacomissao> ptovtaAntecipacomissaoList) {
|
||||
// this.ptovtaAntecipacomissaoList = ptovtaAntecipacomissaoList;
|
||||
// }
|
||||
|
||||
public void setLsPtovtaUsuarioBancario(List<PtoVtaUsuarioBancario> lsPtovtaUsuarioBancario) {
|
||||
this.lsPtovtaUsuarioBancario = lsPtovtaUsuarioBancario;
|
||||
|
|
Loading…
Reference in New Issue