package com.jasamedika.medifirst2000.entities;

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

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

import static javax.persistence.GenerationType.SEQUENCE;

/**
 * class JenisAnggaran
 * 
 * @author Generator
 */
@Getter
@Setter
@Entity
@Table(name = "JenisAnggaran_M")
public class JenisAnggaran extends BaseMaster {

	@NotNull(message = "Jenis Anggaran tidak boleh kosong")
	@Column(name = "JenisAnggaran", nullable = false, length = 30)
	@Caption(value = "Jenis Anggaran")
	private String jenisAnggaran;

	@NotNull(message = "Kd Jenis Anggaran tidak boleh kosong")
	@Column(name = "KdJenisAnggaran", nullable = false)
	@Caption(value = "Kode Jenis Anggaran")
	private Byte kdJenisAnggaran;

	@Column(name = "Keterangan", length = 100)
	@Caption(value = "Keterangan")
	private String keterangan;

	@NotNull(message = "QJenis Anggaran tidak boleh kosong")
	@Column(name = "QJenisAnggaran", nullable = false)
	@Caption(value = "QJenis Anggaran")
	private Byte qJenisAnggaran;

	@Id
	@GeneratedValue(strategy = SEQUENCE, generator = "public.jenisanggaran_m_id_seq")
	@SequenceGenerator(name = "public.jenisanggaran_m_id_seq", sequenceName = "public.jenisanggaran_m_id_seq", allocationSize = 1)
	@Column(name = "id")
	protected Integer id;

}