From 86ff9e4c2c1774ae17f17f7e7eb5174f7f560359 Mon Sep 17 00:00:00 2001 From: Ashesh <3626859+Ashesh3@users.noreply.github.com> Date: Thu, 22 Jun 2023 05:18:38 +0530 Subject: [PATCH] Fix header on Patient list page (#5736) * Fix header on Patient list page * fix button alignment --- src/Components/Common/components/Page.tsx | 2 +- src/Components/Patient/ManagePatients.tsx | 179 ++++++++++++---------- 2 files changed, 97 insertions(+), 84 deletions(-) diff --git a/src/Components/Common/components/Page.tsx b/src/Components/Common/components/Page.tsx index 9f2c3c760bf..4292804728a 100644 --- a/src/Components/Common/components/Page.tsx +++ b/src/Components/Common/components/Page.tsx @@ -18,7 +18,7 @@ export default function Page(props: PageProps) { } return ( -
+
{ }; return ( - - setSelectedFacility(e)} - selectedFacility={selectedFacility} - handleOk={() => navigate(`facility/${selectedFacility.id}/patient`)} - handleCancel={() => { - setShowDialog(false); - setSelectedFacility({ name: "" }); - }} - /> -
-
- { - qParams.facility - ? navigate(`/facility/${qParams.facility}/patient`) - : setShowDialog(true); - }} - className="w-full lg:w-fit" - > - -

- Add Patient Details -

-
-
-
- updateQuery({ is_active: "True" })} - onClickTab2={() => updateQuery({ is_active: "False" })} - activeTab={tabValue ? true : false} - /> - {showDoctorConnect && ( + +
{ - setShowDoctors(true); + qParams.facility + ? navigate(`/facility/${qParams.facility}/patient`) + : setShowDialog(true); }} + className="w-full lg:w-fit" > - -

Doctor Connect

+ +

+ Add Patient Details +

- )} - - advancedFilter.setShow(true)} /> - -
- {!isExportAllowed ? ( +
+
+ updateQuery({ is_active: "True" })} + onClickTab2={() => updateQuery({ is_active: "False" })} + activeTab={tabValue ? true : false} + /> + {showDoctorConnect && ( { - advancedFilter.setShow(true); - setTimeout(() => { - const element = document.getElementById("bed-type-select"); - if (element) element.scrollIntoView({ behavior: "smooth" }); - Notification.Warn({ - msg: "Please select a seven day period.", - }); - }, 500); + setShowDoctors(true); }} - className="lg:w-fit w-full mr-5" > - - Export + +

Doctor Connect

- ) : ( - )} - {!isExportAllowed && ( - - Select a seven day period - - )} + advancedFilter.setShow(true)} + /> + +
+ {!isExportAllowed ? ( + { + advancedFilter.setShow(true); + setTimeout(() => { + const element = + document.getElementById("bed-type-select"); + if (element) + element.scrollIntoView({ behavior: "smooth" }); + Notification.Warn({ + msg: "Please select a seven day period.", + }); + }, 500); + }} + className="lg:w-fit w-full mr-5" + > + + Export + + ) : ( + + )} + + {!isExportAllowed && ( + + Select a seven day period + + )} +
-
+ } + > + setSelectedFacility(e)} + selectedFacility={selectedFacility} + handleOk={() => navigate(`facility/${selectedFacility.id}/patient`)} + handleCancel={() => { + setShowDialog(false); + setSelectedFacility({ name: "" }); + }} + /> +