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.ProdukDetailLaboratorium;

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 HasilPemeriksaan
 * 
 * @author Generator
 */
@Entity //@Audited
@Table(name = "HasilPemeriksaanDuplo_T")
public class HasilPemeriksaanDuplo extends BaseTransaction {
	
	public StrukHasilPemeriksaan getStrukHasilPemeriksaan() {
		return strukHasilPemeriksaan;
	}
	
	
	@ManyToOne
	@JoinColumn(name = "HasilPemeriksaanFk")
	@NotNull(message = "Hasil Pemeriksaan Harus Diisi")
	@Caption(value = "HasilPemeriksaan")
	private HasilPemeriksaan  hasilPemeriksaan;
	
	
	public HasilPemeriksaan getHasilPemeriksaan() {
		return hasilPemeriksaan;
	}

	public void setHasilPemeriksaan(HasilPemeriksaan hasilPemeriksaan) {
		this.hasilPemeriksaan = hasilPemeriksaan;
	}

	@Column(name = "HasilPemeriksaanFk", columnDefinition = "CHAR(32)", insertable = false, updatable = false)
	private String hasilPemeriksaanId;
	
	@ManyToOne
	@JoinColumn(name = "ProdukFk")
	@NotNull(message = "Produk Harus Diisi")
	@Caption(value = "Produk")
	private Produk  produk;
	
	
	public Produk getProduk() {
		return produk;
	}

	public void setProduk(Produk produk) {
		this.produk = produk;
	}

	@Column(name = "ProdukFk", insertable = false, updatable = false)
	private Integer produkId;
	
	
	@ManyToOne
	@JoinColumn(name = "StrukHasilFk")
	@NotNull(message = "Struk Hasil Harus Diisi")
	@Caption(value = "Struk Hasil")
	private StrukHasilPemeriksaan  strukHasilPemeriksaan;
	
	public StrukHasilPemeriksaan getstrukHasilPemeriksaan() {
		return strukHasilPemeriksaan;
	}

	public void setStrukHasilPemeriksaan(StrukHasilPemeriksaan strukHasilPemeriksaan) {
		this.strukHasilPemeriksaan = strukHasilPemeriksaan;
	}

	@Column(name = "StrukHasilFk", columnDefinition = "CHAR(32)", insertable = false, updatable = false)
	private String strukHasilPemeriksaanId;
	
	@ManyToOne
	@JoinColumn(name = "DetailFk")	
	@Caption(value = "Detail")
	private ProdukDetailLaboratorium detail;

	public ProdukDetailLaboratorium getDetail() {
		return detail;
	}

	public void setDetail(ProdukDetailLaboratorium detail) {
		this.detail = detail;
	}

	@Column(name = "DetailFk", insertable = false, updatable = false,nullable=true)
	private Integer detailId;

	@Column(name = "TglInput", nullable = false, length = 100)
	@Caption(value = "TglInput")
	private Date tglInput;
	
	
	public Date getTglInput() {
		return tglInput;
	}

	public void setTglInput(Date tglInput) {
		this.tglInput = tglInput;
	}



	@Column(name = "Hasil", nullable = false, length = 100)
	@Caption(value = "Hasil")
	private String hasil;

	public String getHasil() {
		return hasil;
	}

	public void setHasil(String hasil) {
		this.hasil = hasil;
	}

}