From 47b3901e7d40bc29a3f9ce916152422aefb05fdb Mon Sep 17 00:00:00 2001 From: Erik Sundell Date: Wed, 12 Dec 2018 14:08:47 +0100 Subject: [PATCH] remove on metric type change --- .../datasource/stackdriver/query_filter_ctrl.ts | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/public/app/plugins/datasource/stackdriver/query_filter_ctrl.ts b/public/app/plugins/datasource/stackdriver/query_filter_ctrl.ts index 8ce2dfde554..e617dba5945 100644 --- a/public/app/plugins/datasource/stackdriver/query_filter_ctrl.ts +++ b/public/app/plugins/datasource/stackdriver/query_filter_ctrl.ts @@ -60,7 +60,9 @@ export class StackdriverFilterCtrl { handleMetricTypeChange(value) { this.target.metricType = value; - this.onMetricTypeChange(); + this.setMetricType(); + this.$scope.refresh(); + this.getLabels(); } initSegments(hideGroupBys: boolean) { @@ -191,12 +193,6 @@ export class StackdriverFilterCtrl { } } - async onMetricTypeChange() { - this.setMetricType(); - this.$scope.refresh(); - this.getLabels(); - } - setMetricType() { const { valueType, metricKind, unit } = this.metricDescriptors.find( m => m.type === this.templateSrv.replace(this.target.metricType)