Skip to content

Commit 05ef180

Browse files
authored
Fix redirection to legacy event_analytics URL from dashboards (opensearch-project#399)
Signed-off-by: Joshua Li <joshuali925@gmail.com>
1 parent 6309e63 commit 05ef180

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

public/components/custom_panels/helpers/add_visualization_popover.tsx

+9-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@
55

66
import { EuiButton, EuiContextMenu, EuiPopover } from '@elastic/eui';
77
import React, { useState } from 'react';
8+
import {
9+
CREATE_TAB_PARAM,
10+
CREATE_TAB_PARAM_KEY,
11+
TAB_CHART_ID,
12+
} from '../../../../common/constants/explorer';
13+
import { observabilityLogsID } from '../../../../common/constants/shared';
814

915
interface AddVisualizationPopoverProps {
1016
showFlyout: (isReplacement?: boolean, replaceVizId?: string) => void;
@@ -27,7 +33,9 @@ export const AddVisualizationPopover = ({
2733

2834
const advancedVisualization = () => {
2935
closeVizPopover();
30-
window.location.assign('#/event_analytics/explorer');
36+
window.location.assign(
37+
`${observabilityLogsID}#/explorer?${CREATE_TAB_PARAM_KEY}=${CREATE_TAB_PARAM[TAB_CHART_ID]}`
38+
);
3139
};
3240

3341
const getVizContextPanels = () => {

0 commit comments

Comments
 (0)