From 09e4f6786c8bcd1c7db105d833e65b03eb5ff8eb Mon Sep 17 00:00:00 2001 From: Fine Date: Sat, 3 Jun 2023 15:04:36 +0800 Subject: [PATCH] fix: expressions --- src/views/dashboard/configuration/widget/metric/Index.vue | 8 +++++++- src/views/dashboard/graphs/ServiceList.vue | 1 - 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/views/dashboard/configuration/widget/metric/Index.vue b/src/views/dashboard/configuration/widget/metric/Index.vue index 0b96beb0..860ffa08 100644 --- a/src/views/dashboard/configuration/widget/metric/Index.vue +++ b/src/views/dashboard/configuration/widget/metric/Index.vue @@ -86,7 +86,7 @@ limitations under the License. --> /> - {{ states.tips[index] }} + {{ states.tips[index] }}
{{ t("visualization") }}
@@ -210,6 +210,11 @@ limitations under the License. --> } }); if (isExpression.value) { + if (states.metrics && states.metrics[0]) { + queryMetrics(); + } else { + emit("update", {}); + } return; } const metrics: any = states.metricList.filter((d: { value: string; type: string }) => @@ -487,6 +492,7 @@ limitations under the License. --> metricConfig: backupMetricConfig.value, }); backupMetricConfig.value = config; + queryMetrics(); } async function changeExpression(event: any, index: number) { const params = event.target.textContent; diff --git a/src/views/dashboard/graphs/ServiceList.vue b/src/views/dashboard/graphs/ServiceList.vue index 7f936e4a..53f4c684 100644 --- a/src/views/dashboard/graphs/ServiceList.vue +++ b/src/views/dashboard/graphs/ServiceList.vue @@ -127,7 +127,6 @@ limitations under the License. --> queryServices(); async function queryServices() { - console.log(props.config); chartLoading.value = true; const resp = await selectorStore.fetchServices(dashboardStore.layerId);