67 lines
1.7 KiB
Java
67 lines
1.7 KiB
Java
package com.jasamedika.medifirst2000.entities;
|
|
|
|
import java.util.Date;
|
|
import java.util.HashSet;
|
|
import java.util.Set;
|
|
import javax.persistence.*;
|
|
import com.jasamedika.medifirst2000.entities.StrukOrder;
|
|
import com.jasamedika.medifirst2000.entities.StrukResep;
|
|
|
|
import com.fasterxml.jackson.annotation.JsonBackReference;
|
|
import com.jasamedika.medifirst2000.base.BaseTransaction;
|
|
|
|
import javax.validation.constraints.NotNull;
|
|
import com.jasamedika.medifirst2000.helper.Caption;import org.hibernate.envers.Audited;
|
|
|
|
/**
|
|
* class PelayananObat
|
|
*
|
|
* @author Generator
|
|
*/
|
|
@Entity //@Audited
|
|
@Table(name = "PelayananObat_T")
|
|
public class PelayananObat extends BaseTransaction {
|
|
|
|
|
|
@ManyToOne
|
|
@JoinColumn(name = "StrukResepFk")
|
|
@NotNull(message = "Struk Resep Harus Diisi")
|
|
@Caption(value = "Struk Resep")
|
|
private StrukResep strukResep;
|
|
|
|
public StrukResep getStrukResep() {
|
|
return strukResep;
|
|
}
|
|
|
|
public void setStrukResep(StrukResep strukResep) {
|
|
this.strukResep = strukResep;
|
|
}
|
|
|
|
@Column(name = "StrukResepFk", columnDefinition = "CHAR(32)", insertable = false, updatable = false)
|
|
private String strukResepId;
|
|
|
|
// @JsonBackReference
|
|
// @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "pelayananObat")
|
|
// private Set<PelayananPasien> pelayananObats = new HashSet<PelayananPasien>();
|
|
//
|
|
// public Set<PelayananPasien> getListObat() {
|
|
// return pelayananObats;
|
|
// }
|
|
//
|
|
// public void setListObat(Set<PelayananPasien> pelayananObats) {
|
|
// this.pelayananObats = pelayananObats;
|
|
// }
|
|
|
|
@Caption(value = "deskripsi")
|
|
@Column(name = "deskripsi", nullable = true)
|
|
private String deskripsi;
|
|
|
|
public String getDeskripsi() {
|
|
return deskripsi;
|
|
}
|
|
|
|
public void setDeskripsi(String deskripsi) {
|
|
this.deskripsi = deskripsi;
|
|
}
|
|
|
|
} |