Commit fcd2fb8b by Marcus Efraimsson Committed by GitHub

Explore: Clear queries when switching between metrics and logs (#17505)

This will clear the existing queries when switching between metrics and logs. 

Closes #17496
parent 40f95a95
......@@ -122,6 +122,7 @@ export function changeDatasource(exploreId: ExploreId, datasource: string): Thun
*/
export function changeMode(exploreId: ExploreId, mode: ExploreMode): ThunkResult<void> {
return dispatch => {
dispatch(clearQueries(exploreId));
dispatch(changeModeAction({ exploreId, mode }));
dispatch(runQueries(exploreId));
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment