From 6b9dbc32e98945cb734dc6a1f8108226d956c8ca Mon Sep 17 00:00:00 2001 From: Erik Jan de Wit Date: Tue, 21 Mar 2023 11:36:42 +0100 Subject: [PATCH] Add error to details panel (#17510) --- js/apps/admin-ui/src/events/EventsSection.tsx | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/js/apps/admin-ui/src/events/EventsSection.tsx b/js/apps/admin-ui/src/events/EventsSection.tsx index bc05bb29c3..6277c71ddc 100644 --- a/js/apps/admin-ui/src/events/EventsSection.tsx +++ b/js/apps/admin-ui/src/events/EventsSection.tsx @@ -68,6 +68,28 @@ const defaultValues: UserEventSearchForm = { type: [], }; +const UserDetailLink = (event: EventRepresentation) => { + const { t } = useTranslation("events"); + const { realm } = useRealm(); + return ( + <> + {event.userId && ( + + {event.userId} + + )} + {!event.userId && t("noUserDetails")} + + ); +}; + const StatusRow = (event: EventRepresentation) => !event.error ? ( @@ -90,6 +112,12 @@ const DetailCell = (event: EventRepresentation) => ( {value} ))} + {event.error && ( + + error + {event.error} + + )} );