From c0f0e4b0e4beaf2c7093667be80b7cd71efa8323 Mon Sep 17 00:00:00 2001
From: Pranshu Aggarwal <70687348+Pranshu1902@users.noreply.github.com>
Date: Thu, 21 Sep 2023 19:54:42 +0530
Subject: [PATCH] fix loader (#6204)
Co-authored-by: Mohammed Nihal <57055998+nihal467@users.noreply.github.com>
---
src/Components/Patient/PatientNotes.tsx | 111 ++++++++++++------------
1 file changed, 56 insertions(+), 55 deletions(-)
diff --git a/src/Components/Patient/PatientNotes.tsx b/src/Components/Patient/PatientNotes.tsx
index b7993ed1ea3..68a5ab4dc5d 100644
--- a/src/Components/Patient/PatientNotes.tsx
+++ b/src/Components/Patient/PatientNotes.tsx
@@ -101,10 +101,6 @@ const PatientNotes = (props: PatientNotesProps) => {
});
};
- if (isLoading) {
- return ;
- }
-
return (
-
-
Added Notes
-
- {state.notes.length ? (
- state.notes.map((note: any) => (
-
-
- {note.note}
-
-
-
- {formatDateTime(note.created_date) || "-"}
+ {isLoading ? (
+
+ ) : (
+
+
Added Notes
+
+ {state.notes.length ? (
+ state.notes.map((note: any) => (
+
+
+ {note.note}
-
-
-
-
-
-
-
-
- {note.created_by_object?.first_name || "Unknown"}{" "}
- {note.created_by_object?.last_name}
+
+
+ {formatDateTime(note.created_date) || "-"}
- navigate(`/facility/${note.facility?.id}`)}
- >
-
-
+
+
+
+
+
+
+ {note.created_by_object?.first_name || "Unknown"}{" "}
+ {note.created_by_object?.last_name}
+
+
+
+
navigate(`/facility/${note.facility?.id}`)}
+ >
+
+
+
+
+ {note.facility?.name || "Unknown"}
+
-
- {note.facility?.name || "Unknown"}
-
+ ))
+ ) : (
+
+ No Notes Found
- ))
- ) : (
-
- No Notes Found
-
- )}
- {state.count > pageSize && (
-
- )}
+ )}
+ {state.count > pageSize && (
+
+ )}
+
-
+ )}
);
};