Clean code
Persiapan service duplikat racikan detail sebagai relasi pelayanan pasien saat split jumlah pelayanan
This commit is contained in:
parent
43467935a9
commit
c3d5c67ba7
@ -1,18 +1,14 @@
|
|||||||
package com.jasamedika.medifirst2000.entities;
|
package com.jasamedika.medifirst2000.entities;
|
||||||
|
|
||||||
import javax.persistence.Column;
|
|
||||||
import javax.persistence.Entity;
|
|
||||||
import javax.persistence.FetchType;
|
|
||||||
import javax.persistence.JoinColumn;
|
|
||||||
import javax.persistence.ManyToOne;
|
|
||||||
import javax.persistence.Table;
|
|
||||||
|
|
||||||
import com.jasamedika.medifirst2000.base.BaseTransaction;
|
import com.jasamedika.medifirst2000.base.BaseTransaction;
|
||||||
import com.jasamedika.medifirst2000.helper.Caption;
|
import com.jasamedika.medifirst2000.helper.Caption;
|
||||||
|
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
|
import javax.persistence.*;
|
||||||
|
|
||||||
|
import static javax.persistence.FetchType.LAZY;
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@ -21,66 +17,66 @@ public class RacikanDetail extends BaseTransaction {
|
|||||||
private static final long serialVersionUID = -1028349501971182390L;
|
private static final long serialVersionUID = -1028349501971182390L;
|
||||||
|
|
||||||
@Caption(value = "Harga Satuan")
|
@Caption(value = "Harga Satuan")
|
||||||
@Column(name = "hargaSatuan", nullable = true)
|
@Column(name = "hargaSatuan")
|
||||||
private Double hargaSatuan;
|
private Double hargaSatuan;
|
||||||
|
|
||||||
@Caption(value = "Harga Jual")
|
@Caption(value = "Harga Jual")
|
||||||
@Column(name = "HargaJual", nullable = true)
|
@Column(name = "HargaJual")
|
||||||
private Double hargaJual;
|
private Double hargaJual;
|
||||||
|
|
||||||
@ManyToOne
|
@ManyToOne(fetch = LAZY)
|
||||||
@JoinColumn(name = "Generik")
|
@JoinColumn(name = "Generik")
|
||||||
@Caption(value = "Generik")
|
@Caption(value = "Generik")
|
||||||
private Generik generik;
|
private Generik generik;
|
||||||
|
|
||||||
@Column(name = "Generik", insertable = false, updatable = false,nullable=true)
|
@Column(name = "Generik", insertable = false, updatable = false)
|
||||||
private Integer generikId;
|
private Integer generikId;
|
||||||
|
|
||||||
@Caption(value = "statusOrder")
|
@Caption(value = "statusOrder")
|
||||||
@Column(name = "statusOrder", nullable = true)
|
@Column(name = "statusOrder")
|
||||||
private Byte statusOrder;
|
private Byte statusOrder;
|
||||||
|
|
||||||
@Caption(value="Jenis Racikan")
|
@Caption(value = "Jenis Racikan")
|
||||||
@Column(name = "jenisRacikan", nullable = true , length = 10)
|
@Column(name = "jenisRacikan", length = 10)
|
||||||
private String jenisRacikan;
|
private String jenisRacikan;
|
||||||
|
|
||||||
@Caption(value="Total Miligram")
|
@Caption(value = "Total Miligram")
|
||||||
@Column(name = "totalMgMl", nullable = true , length = 10)
|
@Column(name = "totalMgMl", length = 10)
|
||||||
private Double totalMgMl;
|
private Double totalMgMl;
|
||||||
|
|
||||||
@Caption(value="Total Kekuatan")
|
@Caption(value = "Total Kekuatan")
|
||||||
@Column(name = "jumlahKekuatan", nullable = true , length = 10)
|
@Column(name = "jumlahKekuatan", length = 10)
|
||||||
private Double jumlahKekuatan;
|
private Double jumlahKekuatan;
|
||||||
|
|
||||||
@Caption(value="Total Table")
|
@Caption(value = "Total Table")
|
||||||
@Column(name = "jumlahTablet", nullable = true , length = 10)
|
@Column(name = "jumlahTablet", length = 10)
|
||||||
private Double jumlahTablet;
|
private Double jumlahTablet;
|
||||||
|
|
||||||
@Caption(value="Total")
|
@Caption(value = "Total")
|
||||||
@Column(name = "total", nullable = true , length = 10)
|
@Column(name = "total", length = 10)
|
||||||
private Double total;
|
private Double total;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@ManyToOne(fetch = LAZY)
|
||||||
@JoinColumn(name = "ProdukFk")
|
@JoinColumn(name = "ProdukFk")
|
||||||
@Caption(value="Produk")
|
@Caption(value = "Produk")
|
||||||
private Produk produk;
|
private Produk produk;
|
||||||
|
|
||||||
@Column(name = "ProdukFk", insertable=false,updatable=false)
|
@Column(name = "ProdukFk", insertable = false, updatable = false)
|
||||||
private Integer kdProduk;
|
private Integer kdProduk;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@ManyToOne(fetch = LAZY)
|
||||||
@JoinColumn(name = "StrukRacikanFk")
|
@JoinColumn(name = "StrukRacikanFk")
|
||||||
@Caption(value="No Racikan")
|
@Caption(value = "No Racikan")
|
||||||
private StrukRacikan strukRacikan;
|
private StrukRacikan strukRacikan;
|
||||||
|
|
||||||
@Column(name = "StrukRacikanFk", insertable=false,updatable=false)
|
@Column(name = "StrukRacikanFk", insertable = false, updatable = false)
|
||||||
private String noRacikan;
|
private String noRacikan;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@ManyToOne(fetch = LAZY)
|
||||||
@JoinColumn(name = "PelayananPasienFk")
|
@JoinColumn(name = "PelayananPasienFk")
|
||||||
@Caption(value="Pelayanan Pasien")
|
@Caption(value = "Pelayanan Pasien")
|
||||||
private PelayananPasien pelayananPasien;
|
private PelayananPasien pelayananPasien;
|
||||||
|
|
||||||
@Column(name = "PelayananPasienFk", insertable=false,updatable=false)
|
@Column(name = "PelayananPasienFk", insertable = false, updatable = false)
|
||||||
private String pelayananPasienId;
|
private String pelayananPasienId;
|
||||||
}
|
}
|
||||||
@ -1,67 +1,35 @@
|
|||||||
package com.jasamedika.medifirst2000.entities;
|
package com.jasamedika.medifirst2000.entities;
|
||||||
|
|
||||||
import java.util.Date;
|
|
||||||
|
|
||||||
import javax.persistence.Column;
|
|
||||||
import javax.persistence.Entity;
|
|
||||||
import javax.persistence.FetchType;
|
|
||||||
import javax.persistence.JoinColumn;
|
|
||||||
import javax.persistence.ManyToOne;
|
|
||||||
import javax.persistence.Table;
|
|
||||||
|
|
||||||
import com.jasamedika.medifirst2000.base.BaseTransaction;
|
import com.jasamedika.medifirst2000.base.BaseTransaction;
|
||||||
import com.jasamedika.medifirst2000.helper.Caption;
|
import com.jasamedika.medifirst2000.helper.Caption;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
import javax.persistence.*;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
import static javax.persistence.FetchType.LAZY;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "StrukRacikan_T")
|
@Table(name = "StrukRacikan_T")
|
||||||
public class StrukRacikan extends BaseTransaction {
|
public class StrukRacikan extends BaseTransaction {
|
||||||
|
private static final long serialVersionUID = -3297839532635972916L;
|
||||||
|
|
||||||
@Caption(value="No Racikan")
|
@Caption(value = "No Racikan")
|
||||||
@Column(name = "NoRacikan", nullable = false , length = 10)
|
@Column(name = "NoRacikan", nullable = false, length = 10)
|
||||||
private String noRacikan;
|
private String noRacikan;
|
||||||
|
|
||||||
@Caption(value="Tanggal Racikan")
|
@Caption(value = "Tanggal Racikan")
|
||||||
@Column(name = "TglRacikan", nullable = false )
|
@Column(name = "TglRacikan", nullable = false)
|
||||||
private Date tglRacikan;
|
private Date tglRacikan;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@ManyToOne(fetch = LAZY)
|
||||||
@JoinColumn(name = "StrukOrderFk")
|
@JoinColumn(name = "StrukOrderFk")
|
||||||
@Caption(value="No Order")
|
@Caption(value = "No Order")
|
||||||
private StrukOrder strukOrder;
|
private StrukOrder strukOrder;
|
||||||
|
|
||||||
@Column(name = "StrukOrderFk", insertable=false,updatable=false)
|
@Column(name = "StrukOrderFk", insertable = false, updatable = false)
|
||||||
private String noOrder;
|
private String noOrder;
|
||||||
|
|
||||||
public String getNoRacikan() {
|
|
||||||
return noRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setNoRacikan(String noRacikan) {
|
|
||||||
this.noRacikan = noRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Date getTglRacikan() {
|
|
||||||
return tglRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setTglRacikan(Date tglRacikan) {
|
|
||||||
this.tglRacikan = tglRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public StrukOrder getStrukOrder() {
|
|
||||||
return strukOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setStrukOrder(StrukOrder strukOrder) {
|
|
||||||
this.strukOrder = strukOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getNoOrder() {
|
|
||||||
return noOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setNoOrder(String noOrder) {
|
|
||||||
this.noOrder = noOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -1,10 +1,6 @@
|
|||||||
package com.jasamedika.medifirst2000.vo;
|
package com.jasamedika.medifirst2000.vo;
|
||||||
|
|
||||||
import javax.persistence.FetchType;
|
|
||||||
import javax.persistence.ManyToOne;
|
|
||||||
|
|
||||||
import com.jasamedika.medifirst2000.helper.Caption;
|
import com.jasamedika.medifirst2000.helper.Caption;
|
||||||
|
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@ -13,40 +9,37 @@ import lombok.Setter;
|
|||||||
public class RacikanDetailVO extends MedicalRecordTransactionVO {
|
public class RacikanDetailVO extends MedicalRecordTransactionVO {
|
||||||
@Caption(value = "generik")
|
@Caption(value = "generik")
|
||||||
private GenerikVO generik;
|
private GenerikVO generik;
|
||||||
|
|
||||||
@Caption(value = "Harga Satuan")
|
@Caption(value = "Harga Satuan")
|
||||||
private Double hargaSatuan;
|
private Double hargaSatuan;
|
||||||
|
|
||||||
@Caption(value = "Harga Jual")
|
@Caption(value = "Harga Jual")
|
||||||
private Double hargaJual;
|
private Double hargaJual;
|
||||||
|
|
||||||
@Caption(value="Status Order")
|
@Caption(value = "Status Order")
|
||||||
private Byte statusOrder;
|
private Byte statusOrder;
|
||||||
|
|
||||||
@Caption(value="Jenis Racikan")
|
@Caption(value = "Jenis Racikan")
|
||||||
private String jenisRacikan;
|
private String jenisRacikan;
|
||||||
|
|
||||||
@Caption(value="Total Miligram")
|
@Caption(value = "Total Miligram")
|
||||||
private Double totalMgMl;
|
private Double totalMgMl;
|
||||||
|
|
||||||
@Caption(value="Total Kekuatan")
|
@Caption(value = "Total Kekuatan")
|
||||||
private Double jumlahKekuatan;
|
private Double jumlahKekuatan;
|
||||||
|
|
||||||
@Caption(value="Total Table")
|
@Caption(value = "Total Table")
|
||||||
private Double jumlahTablet;
|
private Double jumlahTablet;
|
||||||
|
|
||||||
@Caption(value="Total")
|
@Caption(value = "Total")
|
||||||
private Double total;
|
private Double total;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@Caption(value = "Produk")
|
||||||
@Caption(value="Produk")
|
|
||||||
private ProdukVO produk;
|
private ProdukVO produk;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@Caption(value = "No Racikan")
|
||||||
@Caption(value="No Racikan")
|
|
||||||
private StrukRacikanVO strukRacikan;
|
private StrukRacikanVO strukRacikan;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@Caption(value = "Pelayanan Pasien")
|
||||||
@Caption(value="Pelayanan Pasien")
|
|
||||||
private PelayananPasienVO pelayananPasien;
|
private PelayananPasienVO pelayananPasien;
|
||||||
}
|
}
|
||||||
@ -1,50 +1,21 @@
|
|||||||
package com.jasamedika.medifirst2000.vo;
|
package com.jasamedika.medifirst2000.vo;
|
||||||
|
|
||||||
|
import com.jasamedika.medifirst2000.base.vo.BaseTransactionVO;
|
||||||
|
import com.jasamedika.medifirst2000.helper.Caption;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
import javax.persistence.Column;
|
@Getter
|
||||||
import javax.persistence.FetchType;
|
@Setter
|
||||||
import javax.persistence.JoinColumn;
|
public class StrukRacikanVO extends BaseTransactionVO {
|
||||||
import javax.persistence.ManyToOne;
|
@Caption(value = "No Racikan")
|
||||||
|
|
||||||
import com.jasamedika.medifirst2000.base.vo.BaseTransactionVO;
|
|
||||||
import com.jasamedika.medifirst2000.entities.StrukOrder;
|
|
||||||
import com.jasamedika.medifirst2000.helper.Caption;
|
|
||||||
|
|
||||||
public class StrukRacikanVO extends BaseTransactionVO{
|
|
||||||
|
|
||||||
@Caption(value="No Racikan")
|
|
||||||
private String noRacikan;
|
private String noRacikan;
|
||||||
|
|
||||||
@Caption(value="Tanggal Racikan")
|
@Caption(value = "Tanggal Racikan")
|
||||||
private Date tglRacikan;
|
private Date tglRacikan;
|
||||||
|
|
||||||
@ManyToOne(fetch=FetchType.LAZY)
|
@Caption(value = "No Order")
|
||||||
@Caption(value="No Order")
|
|
||||||
private StrukOrderVO strukOrder;
|
private StrukOrderVO strukOrder;
|
||||||
|
|
||||||
public String getNoRacikan() {
|
|
||||||
return noRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setNoRacikan(String noRacikan) {
|
|
||||||
this.noRacikan = noRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public Date getTglRacikan() {
|
|
||||||
return tglRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setTglRacikan(Date tglRacikan) {
|
|
||||||
this.tglRacikan = tglRacikan;
|
|
||||||
}
|
|
||||||
|
|
||||||
public StrukOrderVO getStrukOrder() {
|
|
||||||
return strukOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setStrukOrder(StrukOrderVO strukOrder) {
|
|
||||||
this.strukOrder = strukOrder;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user