Skip to content

Commit

Permalink
Commented out showFacilities
Browse files Browse the repository at this point in the history
  • Loading branch information
Sulochan-khadka authored Apr 15, 2024
1 parent 03a0b7d commit bd2c122
Showing 1 changed file with 42 additions and 42 deletions.
84 changes: 42 additions & 42 deletions src/Components/Facility/FacilityUsers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -192,48 +192,48 @@ export default function FacilityUsers(props: any) {
// </>
// );
// }
return (
<div className="col-span-full sm:col-span-3 sm:col-start-2">
<div className="mb-2">
{facilities.map((facility, i) => (
<div
key={`facility_${i}`}
className="font-gbold mr-3 mt-2 inline-block rounded-md border-2 py-1 pl-3"
>
<div className="flex items-center space-x-1">
<div className="font-semibold">{facility.name}</div>
<ButtonV2
size="small"
circle
variant="secondary"
disabled={isUnlinkFacilityLoading}
onClick={() =>
setUnlinkFacilityData({
show: true,
facility: facility,
userName: username,
})
}
>
<CareIcon icon="l-multiply" />
</ButtonV2>
</div>
</div>
))}
</div>
{showLinkFacility(username)}
{unlinkFacilityData.show && (
<UnlinkFacilityDialog
facilityName={unlinkFacilityData.facility?.name || ""}
userName={unlinkFacilityData.userName}
isHomeFacility={false}
handleCancel={hideUnlinkFacilityModal}
handleOk={handleUnlinkFacilitySubmit}
/>
)}
</div>
);
};
// return (
// <div className="col-span-full sm:col-span-3 sm:col-start-2">
// <div className="mb-2">
// {facilities.map((facility, i) => (
// <div
// key={`facility_${i}`}
// className="font-gbold mr-3 mt-2 inline-block rounded-md border-2 py-1 pl-3"
// >
// <div className="flex items-center space-x-1">
// <div className="font-semibold">{facility.name}</div>
// <ButtonV2
// size="small"
// circle
// variant="secondary"
// disabled={isUnlinkFacilityLoading}
// onClick={() =>
// setUnlinkFacilityData({
// show: true,
// facility: facility,
// userName: username,
// })
// }
// >
// <CareIcon icon="l-multiply" />
// </ButtonV2>
// </div>
// </div>
// ))}
// </div>
// {showLinkFacility(username)}
// {unlinkFacilityData.show && (
// <UnlinkFacilityDialog
// facilityName={unlinkFacilityData.facility?.name || ""}
// userName={unlinkFacilityData.userName}
// isHomeFacility={false}
// handleCancel={hideUnlinkFacilityModal}
// handleOk={handleUnlinkFacilitySubmit}
// />
// )}
// </div>
// );
// };

const addFacility = async (username: string, facility: any) => {
hideLinkFacilityModal();
Expand Down

0 comments on commit bd2c122

Please sign in to comment.