feat (vaccine-data): add migration and fix entity

This commit is contained in:
dpurbosakti
2025-12-16 14:53:50 +07:00
parent 8b06e969ca
commit 5e80b49bc5
9 changed files with 97 additions and 63 deletions

No files matched your search

@@ -0,0 +1,17 @@
-- Create "VaccineData" table
CREATE TABLE "public"."VaccineData" (
"Id" bigserial NOT NULL,
"CreatedAt" timestamptz NULL,
"UpdatedAt" timestamptz NULL,
"DeletedAt" timestamptz NULL,
"Type" character varying(25) NULL,
"Encounter_Id" bigint NULL,
"BatchNumber" text NULL,
"Dose" numeric NULL,
"DoseOrder" bigint NULL,
"InjectionLocation" text NULL,
"GivenDate" timestamptz NULL,
"ExpirationDate" timestamptz NULL,
PRIMARY KEY ("Id"),
CONSTRAINT "fk_Encounter_Vaccines" FOREIGN KEY ("Encounter_Id") REFERENCES "public"."Encounter" ("Id") ON UPDATE NO ACTION ON DELETE NO ACTION
);