Skip to content

Commit

Permalink
update: Add visit ward in the table
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveGT96 committed Aug 8, 2023
1 parent 37178bd commit f633198
Show file tree
Hide file tree
Showing 2 changed files with 204 additions and 138 deletions.
13 changes: 12 additions & 1 deletion src/components/accessories/opds/table/OpdTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export const OpdTable: FC<IOpdTableProps> = ({ data }) => {
const header = [
"id",
"date",
"ward",
"patientCode",
"patientName",
"sex",
Expand All @@ -37,8 +38,17 @@ export const OpdTable: FC<IOpdTableProps> = ({ data }) => {
referralTo: t("opd.referralto"),
nextVisitDate: t("opd.nextvisitdate"),
age: t("opd.age"),
ward: t("opd.ward"),
};
const order = ["id", "date", "patientCode", "patientName", "age", "disease"];
const order = [
"id",
"date",
"ward",
"patientCode",
"patientName",
"age",
"disease",
];
const [opd, setOpd] = useState({} as OpdDTO);

const formatDataToDisplay = (data: OpdDTO[]) => {
Expand All @@ -58,6 +68,7 @@ export const OpdTable: FC<IOpdTableProps> = ({ data }) => {
disease3: e.disease3?.description ?? "",
referralFrom: e.referralFrom ?? "",
referralTo: e.referralTo ?? "",
ward: e.ward?.description ?? "",
newPatient:
e.newPatient === "R"
? t("opd.reattendance")
Expand Down
Loading

0 comments on commit f633198

Please sign in to comment.