Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed close Button in Treatment Summary #7001

Merged
merged 5 commits into from
Jan 31, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/Components/Facility/TreatmentSummary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import { PatientModel } from "../Patient/models";

import { GENDER_TYPES } from "../../Common/constants";
import { formatAge, formatDate, formatDateTime } from "../../Utils/utils";
import useSlug from "../../Common/hooks/useSlug";
import { navigate } from "raviger";

const Loading = lazy(() => import("../Common/Loading"));

Expand All @@ -25,6 +27,7 @@ const TreatmentSummary = (props: any) => {
const [isLoading, setIsLoading] = useState(false);
const [investigations, setInvestigations] = useState<Array<any>>([]);
const [dailyRounds, setDailyRounds] = useState<any>({});
const facilityId = useSlug("facility");

const fetchPatientData = useCallback(
async (status: statusType) => {
Expand Down Expand Up @@ -105,7 +108,11 @@ const TreatmentSummary = (props: any) => {
<i className="fas fa-print mr-2"></i> Print Treatment Summary
</button>
<button
onClick={(_) => window.history.go(-1)}
onClick={(_) =>
navigate(
`/facility/${facilityId}/patient/${patientId}/consultation/${consultationId}`
)
}
rithviknishad marked this conversation as resolved.
Show resolved Hide resolved
className="btn btn-default"
>
<i className="fas fa-times mr-2"></i> Close
Expand Down
Loading