mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Fixing delete dashboard url form datasource configuration (#46637)
This commit is contained in:
@@ -106,9 +106,9 @@ export function importDashboard(data: any, dashboardTitle: string): ThunkResult<
|
||||
};
|
||||
}
|
||||
|
||||
export function removeDashboard(uri: string): ThunkResult<void> {
|
||||
export function removeDashboard(uid: string): ThunkResult<void> {
|
||||
return async (dispatch) => {
|
||||
await getBackendSrv().delete(`/api/dashboards/${uri}`);
|
||||
await getBackendSrv().delete(`/api/dashboards/uid/${uid}`);
|
||||
dispatch(loadPluginDashboards());
|
||||
};
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ export class DataSourceDashboards extends PureComponent<Props> {
|
||||
};
|
||||
|
||||
onRemove = (dashboard: PluginDashboard) => {
|
||||
this.props.removeDashboard(dashboard.importedUri);
|
||||
this.props.removeDashboard(dashboard.uid);
|
||||
};
|
||||
|
||||
render() {
|
||||
|
||||
Reference in New Issue
Block a user