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="PapDataAplasnasi_T")
public class PapDataAplasnasi 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 = "ObjectDataAplasnasiFk")
	@NotNull(message = "DataAplasnasi tidak boleh kosong")
	private DataAplasnasi dataAplasnasi;
	
	@Column(name = "ObjectDataAplasnasiFk", insertable = false, updatable = false, nullable = false)
	private Integer dataAplasnasiId;
	
	@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 DataAplasnasi getDataAplasnasi() {
		return dataAplasnasi;
	}

	public void setDataAplasnasi(DataAplasnasi dataAplasnasi) {
		this.dataAplasnasi = dataAplasnasi;
	}

}
