mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
wip: react panels, query editor loading from react PanelEditor view
This commit is contained in:
parent
230606146d
commit
1099daec38
@ -31,6 +31,7 @@ export class PanelModel {
|
||||
collapsed?: boolean;
|
||||
panels?: any;
|
||||
soloMode?: boolean;
|
||||
targets: any[];
|
||||
|
||||
// non persisted
|
||||
fullscreen: boolean;
|
||||
@ -48,6 +49,10 @@ export class PanelModel {
|
||||
if (!this.gridPos) {
|
||||
this.gridPos = { x: 0, y: 0, h: 3, w: 6 };
|
||||
}
|
||||
|
||||
if (!this.targets) {
|
||||
this.targets = [{}];
|
||||
}
|
||||
}
|
||||
|
||||
getSaveModel() {
|
||||
|
@ -45,10 +45,6 @@ class MetricsPanelCtrl extends PanelCtrl {
|
||||
this.scope = $scope;
|
||||
this.panel.datasource = this.panel.datasource || null;
|
||||
|
||||
if (!this.panel.targets) {
|
||||
this.panel.targets = [{}];
|
||||
}
|
||||
|
||||
this.events.on('refresh', this.onMetricsPanelRefresh.bind(this));
|
||||
this.events.on('init-edit-mode', this.onInitMetricsPanelEditMode.bind(this));
|
||||
this.events.on('panel-teardown', this.onPanelTearDown.bind(this));
|
||||
|
Loading…
Reference in New Issue
Block a user