package com.jasamedika.medifirst2000.entities;

import com.jasamedika.medifirst2000.helper.Caption;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * 
 * @author Adik
 */
@Getter
@Setter
@Entity
@Table(name = "Anamnesis_T")
public class Anamnesis extends MedicalRecordTransaction {

	@ManyToOne
	@JoinColumn(name = "PegawaiFK")
	@NotNull(message = "Pegawai Harus Diisi")
	@Caption(value = "Pegawai")
	private Pegawai petugas;

	@Column(name = "PegawaiFK", insertable = false, updatable = false, nullable = false)
	private Integer petugasId;

	@Column(name = "AnamnesisSuster")
	@Caption(value = "AnamnesisSuster ")
	private String anamnesisSuster;

	@Column(name = "anamnesisDokter")
	@Caption(value = "Anamnesis Dokter")
	private String anamnesisDokter;

	@NotNull(message = "tglInput Tidak Boleh Kosong")
	@Column(name = "tglInput", nullable = false)
	@Caption(value = "Tanggal Input")
	private Date tanggalInput;

	@ManyToOne
	@JoinColumn(name = "RuanganFK")
	@NotNull(message = "Ruangan Harus Diisi")
	@Caption(value = "Ruangan")
	private Ruangan ruangan;

	@Column(name = "RuanganFK", insertable = false, updatable = false, nullable = false)
	private Integer ruanganId;

}
