package com.jasamedika.medifirst2000.vo;

import java.util.HashSet;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.validation.constraints.NotNull;

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

/**
 * class DokumenRekamMedisVOVO
 * 
 * @author Generator
 */
public class DokumenRekamMedisVO extends BaseTransactionVO {
	private String noRecPasienDaftar;
	@ManyToOne
	@JoinColumn(name = "NoCMFk")
	@NotNull(message = "No C M Harus Diisi")
	@Caption(value = "No C M")
	private PasienVO noCM;

	public PasienVO getNoCM() {
		return noCM;
	}

	public void setNoCM(PasienVO noCM) {
		this.noCM = noCM;
	}

	@Column(name = "NoCMFk", insertable = false, updatable = false)
	private String noCMId;

	@Column(name = "Status", nullable = true, length = 100)
	@Caption(value = "Status")
	private String status;

	public void setStatus(String status) {
		this.status = status;
	}

	public String getStatus() {
		return this.status;
	}

	@ManyToOne
	@JoinColumn(name = "NoKirimFk")
	@NotNull(message = "No Kirim Harus Diisi")
	@Caption(value = "No Kirim")
	private StrukKirimVO noKirim;

	public StrukKirimVO getNoKirim() {
		return noKirim;
	}

	public void setNoKirim(StrukKirimVO noKirim) {
		this.noKirim = noKirim;
	}

	@Column(name = "NoKirimFk", insertable = false, updatable = false)
	private String noKirimId;

	@ManyToOne
	@JoinColumn(name = "NoTerimaFk")

	@Caption(value = "No Terima")
	private StrukPelayananVO noTerima;

	public StrukPelayananVO getNoTerima() {
		return noTerima;
	}

	public void setNoTerima(StrukPelayananVO noTerima) {
		this.noTerima = noTerima;
	}

	@Column(name = "NoTerimaFk", insertable = false, updatable = false, nullable = true)
	private String noTerimaId;

	@ManyToOne
	@JoinColumn(name = "NoDokumenFk")
	@NotNull(message = "No Dokumen Harus Diisi")
	@Caption(value = "No Dokumen")
	private DokumenVO noDokumen;

	public DokumenVO getNoDokumen() {
		return noDokumen;
	}

	public void setNoDokumen(DokumenVO noDokumen) {
		this.noDokumen = noDokumen;
	}

	@Column(name = "NoDokumenFk", insertable = false, updatable = false)
	private String noDokumenId;

	@ManyToOne
	@JoinColumn(name = "RuanganTujuanFk")
	@NotNull(message = "Ruangan Tujuan Harus Diisi")
	@Caption(value = "Ruangan Tujuan")
	private RuanganVO ruanganTujuan;

	public RuanganVO getRuanganTujuan() {
		return ruanganTujuan;
	}

	public void setRuanganTujuan(RuanganVO ruanganTujuan) {
		this.ruanganTujuan = ruanganTujuan;
	}

	@Column(name = "RuanganTujuanFk", insertable = false, updatable = false)
	private String ruanganTujuanId;

	@ManyToOne
	@JoinColumn(name = "RuanganAsalFk")
	@NotNull(message = "Ruangan Asal Harus Diisi")
	@Caption(value = "Ruangan Asal")
	private RuanganVO ruanganAsal;

	public RuanganVO getRuanganAsal() {
		return ruanganAsal;
	}

	public void setRuanganAsal(RuanganVO ruanganAsal) {
		this.ruanganAsal = ruanganAsal;
	}

	@Column(name = "RuanganAsalFk", insertable = false, updatable = false)
	private String ruanganAsalId;

	// add by Arya 2017-02-09
	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "dokumenRekamMedis")
	private Set<MappingKirimDokumenPasienVO> mapKirimDokumenPasien = new HashSet<MappingKirimDokumenPasienVO>();
	// end add by Arya 2017-02-09

	public Set<MappingKirimDokumenPasienVO> getMapKirimDokumenPasien() {
		return mapKirimDokumenPasien;
	}

	public void setMapKirimDokumenPasien(Set<MappingKirimDokumenPasienVO> mapKirimDokumenPasien) {
		this.mapKirimDokumenPasien = mapKirimDokumenPasien;
	}

	public String getNoRecPasienDaftar() {
		return noRecPasienDaftar;
	}

	public void setNoRecPasienDaftar(String noRecPasienDaftar) {
		this.noRecPasienDaftar = noRecPasienDaftar;
	}

}