package com.jasamedika.medifirst2000.vo;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

import com.jasamedika.medifirst2000.base.vo.BaseMasterVO;
import com.jasamedika.medifirst2000.helper.Caption;

import lombok.Getter;
import lombok.Setter;

/**
 * class Produk
 * 
 * @author Generator
 */
@Getter
@Setter
public class ProdukVO extends BaseMasterVO {

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "BahanSampleFk")
	@Caption(value = "Bahan Sample")
	private BahanSampleVO bahanSample;

	@Caption(value = "Deskripsi Produk")
	@Column(name = "DeskripsiProduk", nullable = true, length = 300)
	private String deskripsiProduk;

	@Caption(value = "Is Produk Intern")
	@Column(name = "isProdukIntern", nullable = true)
	private Byte isProdukIntern;

	@ManyToOne
	@JoinColumn(name = "ObjectAccountFk")
	@Caption(value = "Object Account")
	private ChartOfAccountVO account;

	@ManyToOne
	@JoinColumn(name = "ObjectBahanProdukFk")
	@Caption(value = "Object Bahan Produk")
	private BahanProdukVO bahanProduk;

	@Caption(value = "Kode Barcode")
	@Column(name = "KdBarcode", nullable = true, length = 50)
	private String kdBarcode;

	@ManyToOne
	@JoinColumn(name = "ObjectBentukProdukFk")
	@Caption(value = "Object Bentuk Produk")
	private BentukProdukVO bentukProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectDepartemenFk")
	@Caption(value = "Object Departemen")
	private DepartemenVO departemen;

	@ManyToOne
	@JoinColumn(name = "ObjectDetailGolonganProdukFk")
	@Caption(value = "Object Detail Golongan Produk")
	private DetailGolonganProdukVO detailGolonganProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectDetailJenisProdukFk")
	@Caption(value = "Object Detail Jenis Produk")
	private DetailJenisProdukVO detailJenisProduk;

	@Column(name = "ObjectDetailJenisProdukFk", insertable = false, updatable = false)
	private Integer detailJenisProdukId;

	@ManyToOne
	@JoinColumn(name = "ObjectFungsiProdukFk")
	@Caption(value = "Object Fungsi Produk")
	private FungsiProdukVO fungsiProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectGolonganProdukFk")
	@Caption(value = "Object Golongan Produk")
	private GolonganProdukVO golonganProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectGProdukFk")
	@Caption(value = "Object G Produk")
	private GeneralProdukVO gProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectJenisPeriksaPenunjangFk")
	@Caption(value = "Object JenisPeriksaPenunjang")
	private JenisPeriksaPenunjangVO jenisPeriksaPenunjang;

	@ManyToOne
	@JoinColumn(name = "ObjectKategoryProdukFk")
	@Caption(value = "Object Kategory Produk")
	private KategoryProdukVO kategoryProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectLevelProdukFk")
	@Caption(value = "Object Level Produk")
	private LevelProdukVO levelProduk;

	@Caption(value = "Kode Produk")
	@Column(name = "KdProduk", nullable = false, length = 6)
	private String kdProduk;

	@Caption(value = "Kode Produk Intern")
	@Column(name = "KdProdukIntern", nullable = true, length = 15)
	private String kdProdukIntern;

	@ManyToOne
	@JoinColumn(name = "ObjectProdusenProdukFk")
	@Caption(value = "Object Produsen Produk")
	private ProdusenProdukVO produsenProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectSatuanBesarFk")
	@Caption(value = "Object Satuan Besar")
	private SatuanBesarVO satuanBesar;

	@ManyToOne
	@JoinColumn(name = "ObjectSatuanKecilFk")
	@Caption(value = "Object Satuan Kecil")
	private SatuanKecilVO satuanKecil;

	@ManyToOne
	@JoinColumn(name = "ObjectSatuanStandarFk")
	@Caption(value = "Object Satuan Standar")
	private SatuanStandarVO satuanStandar;

	@ManyToOne
	@JoinColumn(name = "ObjectStatusProdukFk")
	@Caption(value = "Object Status Produk")
	private StatusProdukVO statusProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectTypeProdukFk")
	@Caption(value = "Object Type Produk")
	private TypeProdukVO typeProduk;

	@ManyToOne
	@JoinColumn(name = "ObjectUnitLaporanFk")
	@Caption(value = "Object Unit Laporan")
	private UnitLaporanVO unitLaporan;

	@ManyToOne
	@JoinColumn(name = "ObjectWarnaProdukFk")
	@Caption(value = "Object Warna Produk")
	private WarnaProdukVO warnaProduk;

	@Caption(value = "Kekuatan")
	@Column(name = "Kekuatan", nullable = true, length = 20)
	private String kekuatan;

	@Caption(value = "Nama Produk")
	@Column(name = "NamaProduk", nullable = false, length = 150)
	private String namaProduk;

	@Caption(value = "Nilai Normal")
	@Column(name = "NilaiNormal", nullable = false)
	private short nilaiNormal;

	@Caption(value = "QProduk")
	@Column(name = "QProduk", nullable = false)
	private Integer qProduk;

	@Caption(value = "Qty Jual Terkecil")
	@Column(name = "QtyJualTerkecil", nullable = false)
	private Double qtyJualTerkecil;

	@Caption(value = "Qty Kalori")
	@Column(name = "QtyKalori", nullable = true)
	private Double qtyKalori;

	@Caption(value = "Qty Karbohidrat")
	@Column(name = "QtyKarbohidrat", nullable = true)
	private Double qtyKarbohidrat;

	@Caption(value = "Qty Lemak")
	@Column(name = "QtyLemak", nullable = true)
	private Double qtyLemak;

	@Caption(value = "Qty Porsi")
	@Column(name = "QtyPorsi", nullable = true)
	private Double qtyPorsi;

	@Caption(value = "Qty Protein")
	@Column(name = "QtyProtein", nullable = true)
	private Double qtyProtein;

	@Caption(value = "Qty Satu Kemasan")
	@Column(name = "QtySatuKemasan", nullable = false)
	private short qtySatuKemasan;

	@Caption(value = "Qty Terkecil")
	@Column(name = "QtyTerkecil", nullable = false)
	private Double qtyTerkecil;

	@Caption(value = "Tanggal Produksi")
	@Column(name = "TglProduksi", nullable = true)
	private Date tglProduksi;

	@ManyToOne
	@JoinColumn(name = "ObjectGenerikFk")
	@Caption(value = "Object Generik")
	private GenerikVO generik;

	@ManyToOne
	@JoinColumn(name = "ObjectSediaanFk")
	@Caption(value = "Object Sediaan")
	private SediaanVO sediaan;

	@ManyToOne
	@JoinColumn(name = "ObjectDetailObatFk")
	@Caption(value = "Object Detail Obat")
	private DetailObatVO detailObat;

	@ManyToOne
	@JoinColumn(name = "ObjectStatusBarangFk")
	@Caption(value = "Object Detail Obat")
	private StatusBarangVO statusBarang;

	@ManyToOne
	@JoinColumn(name = "ObjectMerkProdukFk")
	@Caption(value = "Object Merk Produk")
	private MerkProdukVO merkProduk;

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "golonganDarahFk")
	@Caption(value = "Golongan Darah")
	private GolonganDarahVO golonganDarah;

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "rhesusFk")
	@Caption(value = "Rhesus")
	private RhesusVO rhesus;

	@ManyToOne
	@JoinColumn(name = "ObjectRekananFk")
	@Caption(value = "Object Rekanan")
	private RekananVO rekanan;

	// add by Arya
	@Caption(value = "Status")
	@Column(name = "Status", nullable = true)
	private String status;

	@Caption(value = "KPTL")
	private String kptl;
}
