stackdriver: use new naming convention for query editor all over

This commit is contained in:
Erik Sundell
2018-11-13 10:57:10 +01:00
parent 30f9a324ac
commit e698202fae
15 changed files with 51 additions and 34 deletions

View File

@@ -52,6 +52,7 @@ export class StackdriverQueryCtrl extends QueryCtrl {
metricKind: '',
valueType: '',
};
projects: any;
showHelp: boolean;
showLastQuery: boolean;
@@ -62,11 +63,16 @@ export class StackdriverQueryCtrl extends QueryCtrl {
constructor($scope, $injector) {
super($scope, $injector);
_.defaultsDeep(this.target, this.defaults);
this.setProjects($scope.ctrl.datasource);
this.panelCtrl.events.on('data-received', this.onDataReceived.bind(this), $scope);
this.panelCtrl.events.on('data-error', this.onDataError.bind(this), $scope);
}
async setProjects(ds) {
this.projects = await ds.getProjects();
console.log(this.projects);
}
onDataReceived(dataList) {
this.lastQueryError = null;
this.lastQueryMeta = null;