From 050da9a2a95cdb9bae48e4807089985a5aec42ab Mon Sep 17 00:00:00 2001 From: pal-sig <88981777+pal-sig@users.noreply.github.com> Date: Mon, 11 Oct 2021 16:21:44 +0530 Subject: [PATCH] fix: while saving the widget, queryData(response of the query) is not send over the backend as it is always calc over the frontend (#323) --- frontend/src/store/actions/dashboard/saveDashboard.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/frontend/src/store/actions/dashboard/saveDashboard.ts b/frontend/src/store/actions/dashboard/saveDashboard.ts index 33f1a03422..a280221d9f 100644 --- a/frontend/src/store/actions/dashboard/saveDashboard.ts +++ b/frontend/src/store/actions/dashboard/saveDashboard.ts @@ -73,6 +73,15 @@ export const SaveDashboard = ({ opacity: updatedopacity, title: updatedTitle, timePreferance: updatedtimePreferance, + queryData: { + ...selectedWidget.queryData, + data: [ + ...selectedWidget.queryData.data.map((e) => ({ + ...e, + queryData: [], + })), + ], + }, }, ...afterWidget, ],