package com.jasamedika.medifirst2000.entities;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.jasamedika.medifirst2000.base.BaseTransaction;
import com.jasamedika.medifirst2000.helper.Caption;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;
import javax.validation.constraints.NotNull;

/**
 * class Agama
 * 
 * @author Generator
 */
@Getter
@Setter
@Entity
@Table(name = "DetailAlasanPemindahanPasien_T")
public class DetailAlasanPemindahanPasien extends BaseTransaction {

	@ManyToOne
	@JoinColumn(name = "objectTransferPasienInternalFk")
	@Caption(value = "Transfer Pasien Internal")
	@JsonBackReference
	private TransferPasienInternal transferPasienInternal;

	@Column(name = "objectTransferPasienInternalFk", insertable = false, updatable = false)
	private String transferPasienInternalId;

	@ManyToOne
	@JoinColumn(name = "objectAlasanPemindahanPasienFk")
	@Caption(value = "Alasan Pemindahan Pasien")
	@JsonBackReference
	@NotNull(message = "Alasan Pemindahan Pasien Harus Diisi")
	private AlasanPemindahanPasien alasanPemindahanPasien;

	@Column(name = "objectAlasanPemindahanPasienFk", insertable = false, updatable = false, nullable = false)
	private Integer alasanPemindahanPasienId;

	@Column(name = "checked")
	private Boolean checked;

}
