Skip to content

Commit

Permalink
fixes #7017; Show feed for Nurse and NurseReadOnly
Browse files Browse the repository at this point in the history
  • Loading branch information
rithviknishad committed Jan 12, 2024
1 parent f2bf161 commit d9082bb
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions src/Components/Facility/ConsultationDetails/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -299,9 +299,13 @@ export const ConsultationDetails = (props: any) => {
</button>
{patientData.last_consultation?.id &&
isCameraAttached &&
["DistrictAdmin", "StateAdmin", "Doctor"].includes(
authUser.user_type
) && (
[
"DistrictAdmin",
"StateAdmin",
"Doctor",
"Nurse",
"NurseReadOnly",
].includes(authUser.user_type) && (
<Link
href={`/facility/${patientData.facility}/patient/${patientData.id}/consultation/${patientData.last_consultation?.id}/feed`}
className="btn btn-primary m-1 w-full hover:text-white"
Expand Down Expand Up @@ -452,9 +456,13 @@ export const ConsultationDetails = (props: any) => {
isCameraAttached === false || // No camera attached
consultationData?.discharge_date || // Discharged
!consultationData?.current_bed?.bed_object?.id || // Not admitted to bed
!["DistrictAdmin", "StateAdmin", "Doctor"].includes(
authUser.user_type
) // Not admin or doctor
![
"DistrictAdmin",
"StateAdmin",
"Doctor",
"Nurse",
"NurseReadOnly",
].includes(authUser.user_type) // Not admin or doctor
)
return null; // Hide feed tab
}
Expand Down

0 comments on commit d9082bb

Please sign in to comment.