Skip to content

Commit

Permalink
Merge branch 'main' into bed-type
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriel090 authored Jan 19, 2024
2 parents 1faf27c + cdf0ba9 commit 6489ecd
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ const ActivePatientsTable: React.FC<ActiveVisitsTableProps> = ({
session?.sessionLocation?.uuid,
status
);

const handleBedAssigmentModal = useCallback(
(entry) => {
setSelectedPatientDetails({
Expand Down
3 changes: 1 addition & 2 deletions src/bed-admission/bed-admission-tabs.component.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Tab, TabList, TabPanel, TabPanels, Tabs } from "@carbon/react";
import { Tab, TabList, TabPanel, TabPanels, Tabs, Button } from "@carbon/react";

Check warning on line 1 in src/bed-admission/bed-admission-tabs.component.tsx

View workflow job for this annotation

GitHub Actions / build

'Button' is defined but never used
import React, { useState } from "react";
import styles from "./bed-admission-tabs-styles.scss";
import { useTranslation } from "react-i18next";
Expand All @@ -12,7 +12,6 @@ const BedAdmissionTabs: React.FC = () => {
const [admittedCount, setAdmittedCount] = useState(0);
const [toAdmitCount, setToAdmitCount] = useState(0);
const [toDischargeCount, setToDischargeCount] = useState(0);

return (
<>
<div className={styles.cardContainer}>
Expand Down
3 changes: 1 addition & 2 deletions src/root.component.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import React, { useEffect } from "react";
import { BrowserRouter, Route, Routes } from "react-router-dom";
import { setLeftNav, unsetLeftNav } from "@openmrs/esm-framework";
import BedAdministrationTable from "./bed-administration/bed-administration-table.component";
import Home from "./home.component";
import LeftPanel from "./left-panel/left-panel.component";
import WardWithBeds from "./ward-with-beds/ward-with-beds.component";
import styles from "./root.scss";
import BedAdministrationTable from "./bed-administration/bed-administration-table.component";
import BedTagAdministrationTable from "./bed-admission/bed-tag/bed-tag-administration-table.component";
import BedTypeAdministrationTable from "./bed-admission/bed-type/bed-type-administration-table.component";

Expand All @@ -30,7 +30,6 @@ const Root: React.FC = () => {
<Route path="/administration" element={<BedAdministrationTable />} />
<Route path="/bed-tag" element={<BedTagAdministrationTable />} />
<Route path="/bed-type" element={<BedTypeAdministrationTable />} />

</Routes>
</main>
</BrowserRouter>
Expand Down
10 changes: 10 additions & 0 deletions src/routes.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,16 @@
"name": "bed-administration-left-panel-link",
"slot": "bed-management-left-panel-slot"
},
{
"component": "bedTypeLeftPanelLink",
"name": "bed-type-left-panel-link",
"slot": "bed-management-left-panel-slot"
},
{
"component": "bedTagLeftPanelLink",
"name": "bed-tag-left-panel-link",
"slot": "bed-management-left-panel-slot"
},
{
"component": "summaryLeftPanelLink",
"name": "bed-management-home-dashboard-link",
Expand Down
2 changes: 1 addition & 1 deletion src/summary/summary.resource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,4 +208,4 @@ export async function editBedTag({
}
);
return response;
}

11 changes: 11 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,17 @@ export interface InitialData {
};
}

export interface BedTypeData {
uuid: string;
name: string;
displayName: string;
description: string;
}

export interface BedTagData {
uuid: string;
name: string;
}
export type Mutator = KeyedMutator<{
data: {
results: Array<Location>;
Expand Down

0 comments on commit 6489ecd

Please sign in to comment.