feat(patient): use type and make nullable for citizen in patient

This commit is contained in:
avicenan
2026-05-21 11:10:46 +09:00
parent c18bb6df96
commit 132acf0dbb
3 changed files with 13 additions and 2 deletions

View File

@ -9,6 +9,7 @@ import { Province } from "../province";
import { City } from "../city"; import { City } from "../city";
import { Subdistrict } from "../subdistrict"; import { Subdistrict } from "../subdistrict";
import { Ward } from "../ward"; import { Ward } from "../ward";
import { Citizen } from "../../types/citizen";
@Entity("emr_patients", { schema: "emr" }) @Entity("emr_patients", { schema: "emr" })
export class EmrPatient { export class EmrPatient {
@ -36,8 +37,8 @@ export class EmrPatient {
@Column({ nullable: false, length: 32 }) @Column({ nullable: false, length: 32 })
gender: string; gender: string;
@Column({ nullable: false, length: 32 }) @Column({ nullable: true, length: 32 })
citizen: string; citizen: Citizen;
@Column({ nullable: true, length: 64 }) @Column({ nullable: true, length: 64 })
marriage_status: string; marriage_status: string;

View File

@ -58,3 +58,4 @@ export * from "../types/radiology_order_status";
export * from "../types/laboratory_order_status"; export * from "../types/laboratory_order_status";
export * from "../enum/consciousness"; export * from "../enum/consciousness";
export * from "../types/patient_category"; export * from "../types/patient_category";
export * from "../types/citizen";

9
src/types/citizen.ts Normal file
View File

@ -0,0 +1,9 @@
/**
* Workflow kategori pendaftaran pasien.
* Timoroan: pasien timor leste
* Estranjeiru: pasien asing
*/
export enum Citizen {
TIMOROAN = "Timoroan",
ESTRANJEIRU = "Estranjeiru",
}