From b08e859426e786c69c15fd49f6a0d886913b77b7 Mon Sep 17 00:00:00 2001 From: Vikrant Gupta Date: Mon, 22 Jul 2024 13:43:47 +0530 Subject: [PATCH] fix: do not add select columns when the datasource is logs (#5515) * fix: do not add select columns when the datasource is logs * chore: added data test id --- frontend/src/container/GridCardLayout/GridCard/index.tsx | 5 ++--- .../NewWidget/LeftContainer/ExplorerColumnsRenderer.tsx | 1 + frontend/src/container/NewWidget/index.tsx | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/frontend/src/container/GridCardLayout/GridCard/index.tsx b/frontend/src/container/GridCardLayout/GridCard/index.tsx index 0f30a189cf..8e34e32879 100644 --- a/frontend/src/container/GridCardLayout/GridCard/index.tsx +++ b/frontend/src/container/GridCardLayout/GridCard/index.tsx @@ -125,10 +125,9 @@ function GridCardGraph({ offset: 0, limit: updatedQuery.builder.queryData[0].limit || 0, }, + // we do not need select columns in case of logs selectColumns: - initialDataSource === DataSource.LOGS - ? widget.selectedLogFields - : widget.selectedTracesFields, + initialDataSource === DataSource.TRACES && widget.selectedTracesFields, }, fillGaps: widget.fillSpans, }; diff --git a/frontend/src/container/NewWidget/LeftContainer/ExplorerColumnsRenderer.tsx b/frontend/src/container/NewWidget/LeftContainer/ExplorerColumnsRenderer.tsx index a9a8d9ceb2..0ead9a3765 100644 --- a/frontend/src/container/NewWidget/LeftContainer/ExplorerColumnsRenderer.tsx +++ b/frontend/src/container/NewWidget/LeftContainer/ExplorerColumnsRenderer.tsx @@ -309,6 +309,7 @@ function ExplorerColumnsRenderer({ >