Skip to content

Commit

Permalink
MOSIP-38029: UI Development - View of linked devices for a SBI
Browse files Browse the repository at this point in the history
Signed-off-by: Swetha K <[email protected]>
  • Loading branch information
Swetha K committed Jan 6, 2025
1 parent 089e6fd commit 7e894da
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ function ViewAdminSbiDetails() {
navigate('/partnermanagement/admin/device-provider-services/sbi-list');
};

const showLinkedDevices = () => {
if (sbiDetails.countOfAssociatedDevices > 0) {
navigate(`/partnermanagement/admin/device-provider-services/devices-list?sbiId=${sbiDetails.sbiId}&sbiVersion=${sbiDetails.sbiVersion}`);
}
};

return (
<div className={`mt-2 w-[100%] ${isLoginLanguageRTL ? "mr-28 ml-5" : "ml-28 mr-5"} font-inter relative`}>
<div className={`flex-col mt-4 bg-anti-flash-white h-full font-inter break-words max-[450px]:text-sm mb-[2%]`}>
Expand Down Expand Up @@ -100,7 +106,7 @@ function ViewAdminSbiDetails() {
<p className="font-[600] text-suva-gray text-sm">
{t("sbiList.linkedDevices")}
</p>
<p className="font-[600] text-vulcan text-md">
<p className={`font-[600] text-vulcan text-md ${sbiDetails.countOfAssociatedDevices > 0 && 'cursor-pointer'}`} onClick={() => showLinkedDevices()}>
{sbiDetails.countOfAssociatedDevices}
</p>
</div>
Expand Down

0 comments on commit 7e894da

Please sign in to comment.