diff --git a/src/components/IOC/IOCDetails/IOCDetails.tsx b/src/components/IOC/IOCDetails/IOCDetails.tsx index 6ae05e9220668a04e895bac7f70c813f9a67e2fc..dc834792f1cd4a1cf4fe33b032654447d86ef6ed 100644 --- a/src/components/IOC/IOCDetails/IOCDetails.tsx +++ b/src/components/IOC/IOCDetails/IOCDetails.tsx @@ -1,5 +1,9 @@ import { Grid, Box, Stack, Typography } from "@mui/material"; -import { KeyValueTable, AlertBannerList } from "@ess-ics/ce-ui-common"; +import { + KeyValueTable, + AlertBannerList, + InternalLink +} from "@ess-ics/ce-ui-common"; import { IOCStatus } from "../IOCStatus"; import { AccessControl } from "../../auth/AccessControl"; import { IocDetails, useFetchIocAlertsQuery } from "../../../store/deployApi"; @@ -82,13 +86,12 @@ export function IOCDetails({ ioc, getSubset, buttons }: IOCDetailsProps) { > {ioc.namingName} </Typography> - <Typography - noWrap - component="p" - variant="subtitle2" + <InternalLink + to={`/hosts/${ioc?.activeDeployment?.host?.hostId}`} + label={`Host details, ${ioc?.activeDeployment?.host?.fqdn}`} > {ioc.activeDeployment?.host?.fqdn || "---"} - </Typography> + </InternalLink> </Box> </Stack> diff --git a/src/components/IOC/IOCLiveStatus/IOCLiveStatus.tsx b/src/components/IOC/IOCLiveStatus/IOCLiveStatus.tsx index 3ca87ebface15265dace0cfdd8d9a40a7b716ab3..b1271d2d0ed4156ecc51ac80f54d95c7797b9e74 100644 --- a/src/components/IOC/IOCLiveStatus/IOCLiveStatus.tsx +++ b/src/components/IOC/IOCLiveStatus/IOCLiveStatus.tsx @@ -1,10 +1,6 @@ import { useCallback, useState, ChangeEvent } from "react"; import { Typography } from "@mui/material"; -import { - SimpleAccordion, - InternalLink, - EmptyValue -} from "@ess-ics/ce-ui-common"; +import { SimpleAccordion, EmptyValue } from "@ess-ics/ce-ui-common"; import { useSearchParams } from "react-router-dom"; import { IOCDetails } from "../IOCDetails"; import { LokiPanel } from "../../common/Loki/LokiPanel"; @@ -34,25 +30,7 @@ export function IOCLiveStatus({ ioc }: { ioc: IocDetails }) { /> ) : ( <EmptyValue /> - ), - "Deployed on": - ioc?.activeDeployment?.host && - ioc?.activeDeployment?.host.externalIdValid ? ( - <Typography> - {ioc.activeDeployment?.host.hostId ? ( - <InternalLink - to={`/hosts/${ioc.activeDeployment?.host.hostId}`} - label={`Host details, ${ioc.activeDeployment?.host.fqdn}`} - > - {ioc.activeDeployment?.host.fqdn} - </InternalLink> - ) : ( - ioc.activeDeployment?.host.fqdn - )} - </Typography> - ) : ( - <EmptyValue /> - ) + ) }; return subset;