1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113
|
@Entity
@Table(name = "PRODUIT")
public class Produit implements java.io.Serializable {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "REFERENCE")
private int reference;
@Column(name = "DESIGNATION")
private String designation;
@Column(name = "TVA")
private int tva;
@Column(name = "PRIX_HORS_TAXE")
private double ht;
@Column(name = "QUANTITE")
private int quantite;
@Column(name = "UNITE")
private String unite;
@Column(name = "STOCK_MINIMAL")
private int stockMin;
@ManyToOne
@JoinColumn(name = "FK_CODE_CATEGORIE")
private Categorie categorie;
public Produit(String designation, int tva, double ht, int quantite, String unite, int stockMin, Categorie categorie) {
this.designation = designation;
this.tva = tva;
this.ht = ht;
this.quantite = quantite;
this.unite = unite;
this.stockMin = stockMin;
this.categorie = categorie;
}
public Produit(String designation, int tva, double ht, int quantite, String unite, int stockMin) {
super();
this.designation = designation;
this.tva = tva;
this.ht = ht;
this.quantite = quantite;
this.unite = unite;
this.stockMin = stockMin;
}
public Produit() {
super();
}
public int getReference() {
return reference;
}
public void setReference(int reference) {
this.reference = reference;
}
public String getDesignation() {
return designation;
}
public void setDesignation(String designation) {
this.designation = designation;
}
public int getTva() {
return tva;
}
public void setTva(int tva) {
this.tva = tva;
}
public double getHt() {
return ht;
}
public void setHt(double ht) {
this.ht = ht;
}
public int getQuantite() {
return quantite;
}
public void setQuantite(int quantite) {
this.quantite = quantite;
}
public String getUnite() {
return unite;
}
public void setUnite(String unite) {
this.unite = unite;
}
public int getStockMin() {
return stockMin;
}
public void setStockMin(int stockMin) {
this.stockMin = stockMin;
}
public Categorie getCategorie() {
return categorie;
}
public void setCategorie(Categorie categorie) {
this.categorie = categorie;
}
} |
Partager