From c40794c2b90b729acdff03a99f4f1e881ceb96c9 Mon Sep 17 00:00:00 2001 From: Erik Sundell Date: Tue, 30 Oct 2018 14:48:07 +0100 Subject: [PATCH] stackdriver: improve default state handling --- .../components/MetricTypePicker.tsx | 3 +- .../stackdriver/components/ServicePicker.tsx | 9 ++- .../stackdriver/components/SimpleDropdown.tsx | 2 +- .../components/TemplateQueryComponent.tsx | 55 ++++++++++++++----- 4 files changed, 52 insertions(+), 17 deletions(-) diff --git a/public/app/plugins/datasource/stackdriver/components/MetricTypePicker.tsx b/public/app/plugins/datasource/stackdriver/components/MetricTypePicker.tsx index 6c6917b6d78..f5a566a1e6e 100644 --- a/public/app/plugins/datasource/stackdriver/components/MetricTypePicker.tsx +++ b/public/app/plugins/datasource/stackdriver/components/MetricTypePicker.tsx @@ -4,6 +4,7 @@ import { getMetricTypesByService } from '../functions'; interface Props { onMetricTypeChange: any; selectedService: string; + selectedMetricType: string; metricDescriptors: any[]; } @@ -23,7 +24,7 @@ const MetricTypePicker: SFC = props => {
Metric Types
- {filterMetricTypes().map((qt, i) => (