DashboardEditPane: Get original panel id for repeated panel edit pane (#103877)
get original panel id for repeated panel edit pane
This commit is contained in:
@@ -17,7 +17,7 @@ import {
|
||||
} from '@grafana/ui';
|
||||
import { t, Trans } from 'app/core/internationalization';
|
||||
|
||||
import { isInCloneChain } from '../utils/clone';
|
||||
import { containsCloneKey, getOriginalKey, isInCloneChain } from '../utils/clone';
|
||||
import { getDashboardSceneFor } from '../utils/utils';
|
||||
|
||||
import { DashboardOutline } from './DashboardOutline';
|
||||
@@ -101,7 +101,9 @@ export class DashboardEditPane extends SceneObjectBase<DashboardEditPaneState> {
|
||||
return;
|
||||
}
|
||||
|
||||
const obj = sceneGraph.findByKey(this, element.id);
|
||||
const elementId = containsCloneKey(element.id) ? getOriginalKey(element.id) : element.id;
|
||||
|
||||
const obj = sceneGraph.findByKey(this, elementId);
|
||||
if (obj) {
|
||||
this.selectObject(obj, element.id, options);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user