mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
fix: datatrails: hide graphs when previews disabled (#81423)
fix: datatrails: hide graph when previews disabled
This commit is contained in:
parent
811ce04390
commit
329440cb1e
@ -168,11 +168,11 @@ export class MetricSelectScene extends SceneObjectBase<MetricSelectSceneState> {
|
|||||||
for (let index = 0; index < metricsList.length; index++) {
|
for (let index = 0; index < metricsList.length; index++) {
|
||||||
const metric = metricsList[index];
|
const metric = metricsList[index];
|
||||||
|
|
||||||
if (metric.itemRef && metric.isPanel) {
|
|
||||||
children.push(metric.itemRef.resolve());
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (this.state.showPreviews) {
|
if (this.state.showPreviews) {
|
||||||
|
if (metric.itemRef && metric.isPanel) {
|
||||||
|
children.push(metric.itemRef.resolve());
|
||||||
|
continue;
|
||||||
|
}
|
||||||
const panel = getPreviewPanelFor(metric.name, index);
|
const panel = getPreviewPanelFor(metric.name, index);
|
||||||
metric.itemRef = panel.getRef();
|
metric.itemRef = panel.getRef();
|
||||||
metric.isPanel = true;
|
metric.isPanel = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user