package com.jasamedika.medifirst2000.entities;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.validation.constraints.NotNull;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.jasamedika.medifirst2000.base.BaseTransaction;
import com.jasamedika.medifirst2000.helper.Caption;import org.hibernate.envers.Audited;

@Entity //@Audited
@Table(name="PapDataTonometri_T")
public class PapDataTonometri extends BaseTransaction{
	/*@JsonBackReference
	@ManyToOne
	@JoinColumn(name = "ObjectPapMataFk")
	@NotNull(message = "PapMata tidak boleh kosong")
	private PapMata papMata;

	@Column(name = "ObjectPapMataFk", insertable = false, updatable = false, nullable = false)
	private String papMataId;*/

	@ManyToOne
	@JoinColumn(name = "ObjectDataTonometriFk")
	@NotNull(message = "DataTonometri tidak boleh kosong")
	private DataTonometri dataTonometri;
	
	@Column(name = "ObjectDataTonometriFk", insertable = false, updatable = false, nullable = false)
	private Integer dataTonometriId;
	
	@NotNull(message = "isNilai tidak boleh kosong")
	@Column(name = "isNilai", nullable = false)
	@Caption(value = "isNilai")
	private Boolean isNilai;

	/*public PapMata getPapMata() {
		return papMata;
	}

	public void setPapMata(PapMata papMata) {
		this.papMata = papMata;
	}*/

	public Boolean getIsNilai() {
		return isNilai;
	}

	public void setIsNilai(Boolean isNilai) {
		this.isNilai = isNilai;
	}

	public DataTonometri getDataTonometri() {
		return dataTonometri;
	}

	public void setDataTonometri(DataTonometri dataTonometri) {
		this.dataTonometri = dataTonometri;
	}

}
