diff --git a/src/entity/emr/emr_registration.ts b/src/entity/emr/emr_registration.ts index 5e146da..2118833 100644 --- a/src/entity/emr/emr_registration.ts +++ b/src/entity/emr/emr_registration.ts @@ -9,8 +9,8 @@ import { JoinColumn, } from "typeorm"; -import { Status } from "../../types/status"; import { RegistrationType } from "../../types/registration_type"; +import { RegistrationStatus } from "../../types/registration_status"; import { EmrPatient } from "./emr_patient"; /** @@ -40,8 +40,8 @@ export class EmrRegistration { @Column({ type: "text", nullable: true }) reason_notes: string; - @Column({ nullable: false, length: 64 }) - status: Status; + @Column({ nullable: false, length: 32 }) + status: RegistrationStatus; @Column({ type: "date", nullable: true }) visit_date: Date; diff --git a/src/schema/emr.ts b/src/schema/emr.ts index e68fa41..c429da4 100644 --- a/src/schema/emr.ts +++ b/src/schema/emr.ts @@ -6,3 +6,4 @@ export * from "../entity/emr/emr_registration_emergency"; export * from "../entity/emr/emr_registration_hemodialysis"; export * from "../types/registration_type"; +export * from "../types/registration_status"; diff --git a/src/types/registration_status.ts b/src/types/registration_status.ts new file mode 100644 index 0000000..f14f570 --- /dev/null +++ b/src/types/registration_status.ts @@ -0,0 +1,10 @@ +/** + * Workflow status untuk registrasi EMR (bukan status Y/N). + */ +export enum RegistrationStatus { + SCHEDULED = "scheduled", // sudah didaftarkan, belum dipanggil + ONGOING = "ongoing", // sedang dalam proses (pasien sedang dilayani) + COMPLETED = "completed", // layanan sudah selesai + CANCELED = "canceled", // dibatalkan +} +