From ce797e197142c5b61e5b583eedfd65d23785c83c Mon Sep 17 00:00:00 2001 From: Jeremy Clements <79224539+jeclrsg@users.noreply.github.com> Date: Tue, 8 Oct 2024 14:12:28 -0400 Subject: [PATCH] HPCC-32775 ECL Watch v9 fix Queries list status columns fix an issue where the status/icon columns of the Queries list were not properly displaying values of the results from the API call to ESP Signed-off-by: Jeremy Clements <79224539+jeclrsg@users.noreply.github.com> --- esp/src/src-react/components/Queries.tsx | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/esp/src/src-react/components/Queries.tsx b/esp/src/src-react/components/Queries.tsx index ff45b2a7f6d..a64847aff70 100644 --- a/esp/src/src-react/components/Queries.tsx +++ b/esp/src/src-react/components/Queries.tsx @@ -120,8 +120,8 @@ export const Queries: React.FunctionComponent = ({ headerTooltip: nlsHPCC.ErrorWarnings, width: 16, sortable: false, - formatter: (error) => { - if (error > 0) { + formatter: (error, row) => { + if (row.ErrorCount > 0) { return ; } return ""; @@ -133,8 +133,9 @@ export const Queries: React.FunctionComponent = ({ headerTooltip: nlsHPCC.MixedNodeStates, width: 16, sortable: false, - formatter: (mixed) => { - if (mixed === true) { + formatter: (mixed, row) => { + const mixedStates = row.Clusters.ClusterQueryState[0]?.MixedNodeStates ?? false; + if (mixedStates === true) { return ; } return ""; @@ -144,8 +145,8 @@ export const Queries: React.FunctionComponent = ({ headerIcon: "SkypeCircleCheck", headerTooltip: nlsHPCC.Active, width: 16, - formatter: (activated) => { - if (activated === true) { + formatter: (activated, row) => { + if (row.Activated === true) { return ; } return "";