From cbb607b36f026349fe989d37ff2b0f7055ae6f5b Mon Sep 17 00:00:00 2001 From: Juan Cabanas Date: Tue, 21 Nov 2023 12:00:03 -0300 Subject: [PATCH] Revert "Panel: omit query API call when the panel is a row (#75847)" (#78475) --- public/app/features/dashboard/state/PanelModel.test.ts | 9 --------- public/app/features/dashboard/state/PanelModel.ts | 4 ---- 2 files changed, 13 deletions(-) diff --git a/public/app/features/dashboard/state/PanelModel.test.ts b/public/app/features/dashboard/state/PanelModel.test.ts index 1848b0f43bf..22612a0951a 100644 --- a/public/app/features/dashboard/state/PanelModel.test.ts +++ b/public/app/features/dashboard/state/PanelModel.test.ts @@ -590,15 +590,6 @@ describe('PanelModel', () => { expect(model.getQueryRunner).toBeCalled(); }); - it('when called then it should not call all pending queries if the panel is a row', () => { - model.getQueryRunner = jest.fn().mockReturnValue({ - run: jest.fn(), - }); - model.type = 'row'; - model.runAllPanelQueries({}); - - expect(model.getQueryRunner).not.toBeCalled(); - }); }); }); }); diff --git a/public/app/features/dashboard/state/PanelModel.ts b/public/app/features/dashboard/state/PanelModel.ts index 0f20b754ebc..68ec74568f7 100644 --- a/public/app/features/dashboard/state/PanelModel.ts +++ b/public/app/features/dashboard/state/PanelModel.ts @@ -362,10 +362,6 @@ export class PanelModel implements DataConfigSource, IPanelModel { } runAllPanelQueries({ dashboardUID, dashboardTimezone, timeData, width }: RunPanelQueryOptions) { - if (this.type === 'row') { - return; - } - this.getQueryRunner().run({ datasource: this.datasource, queries: this.targets,