package com.jasamedika.medifirst2000.entities;

import com.jasamedika.medifirst2000.base.BaseActive;
import com.jasamedika.medifirst2000.helper.Caption;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.validator.constraints.NotBlank;

import javax.persistence.*;
import java.io.Serializable;

import static javax.persistence.GenerationType.SEQUENCE;

/**
 * @author salmanoe
 * @version 1.0.0
 * @since 24/10/2023
 */
@Getter
@Setter
@Entity
@Table(name = "rm_frekuensi_pakai_obat_m")
public class FrekuensiPakaiObat extends BaseActive implements Serializable {

	@Id
	@GeneratedValue(strategy = SEQUENCE, generator = "sg_rm_frekuensi_pakai_obat_m")
	@SequenceGenerator(name = "sg_rm_frekuensi_pakai_obat_m", sequenceName = "rm_frekuensi_pakai_obat_m_seq", allocationSize = 1)
	@Column(name = "id")
	protected Long id;

	@Column(nullable = false)
	@NotBlank
	@Caption("Frekuensi Pakai Obat")
	private String namaFrekuensi;

}
