Skip to content

Commit

Permalink
Abdm m3 improvements (#7845)
Browse files Browse the repository at this point in the history
  • Loading branch information
khavinshankar authored May 17, 2024
1 parent 4653d65 commit aa6d33f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/Components/ABDM/ABDMRecordsTab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,17 @@ export default function ABDMRecordsTab({ patientId }: IProps) {
<Loading />;
}

if (!data?.results.length) {
return (
<div className="mt-12 flex flex-col items-center justify-center gap-2.5">
<p className="font-semibold text-gray-600">No Records found</p>
<p className="text-sm text-gray-600">
Raise a consent request to fetch patient records over ABDM
</p>
</div>
);
}

return (
<div className="mt-6 flex flex-col gap-6">
{data?.results.map((record) => {
Expand Down
5 changes: 5 additions & 0 deletions src/Components/Facility/ConsultationDetails/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,11 @@ export const ConsultationDetails = (props: any) => {
)
return null; // Hide feed tab
}

if (p.text === "ABDM" && !patientData.abha_number) {
return null;
}

return (
<Link
key={p.text}
Expand Down

0 comments on commit aa6d33f

Please sign in to comment.