_id -> id

This commit is contained in:
Alex Holliday
2026-01-20 19:41:57 +00:00
parent c0e4893f96
commit c1b2bda623
3 changed files with 10 additions and 7 deletions
@@ -150,7 +150,9 @@ const IncidentTable = ({
{
id: "monitorName",
content: t("incidentsTableMonitorName"),
render: (row) => monitors[row.monitorId]?.name ?? "N/A",
render: (row) => {
return monitors?.[row.metadata?.monitorId]?.name || "N/A";
},
},
{
id: "status",
@@ -20,12 +20,13 @@ const OptionsHeader = ({
}) => {
const theme = useTheme();
const { t } = useTranslation();
console.log(monitors);
const monitorNames = typeof monitors !== "undefined" ? Object.values(monitors) : [];
const filterOptions = [
{ _id: "all", name: t("incidentsOptionsHeaderFilterAll") },
{ _id: "down", name: t("incidentsOptionsHeaderFilterDown") },
{ _id: "resolve", name: t("incidentsOptionsHeaderFilterCannotResolve") },
{ _id: "resolved", name: t("incidentsOptionsHeaderFilterResolved") },
{ id: "all", name: t("incidentsOptionsHeaderFilterAll") },
{ id: "down", name: t("incidentsOptionsHeaderFilterDown") },
{ id: "resolve", name: t("incidentsOptionsHeaderFilterCannotResolve") },
{ id: "resolved", name: t("incidentsOptionsHeaderFilterResolved") },
];
// The stacks below which are three in number have the same style so
+2 -2
View File
@@ -48,8 +48,8 @@ const Checks = () => {
useEffect(() => {
const monitorLookup = monitors?.reduce((acc, monitor) => {
acc[monitor._id] = {
_id: monitor._id,
acc[monitor.id] = {
id: monitor.id,
name: monitor.name,
type: monitor.type,
};