From 381b1d8bc7c2eb7b35ae7bd18a5eb4b08e1c207d Mon Sep 17 00:00:00 2001 From: wangwenrui Date: Fri, 15 May 2020 17:38:13 +0800 Subject: [PATCH] =?UTF-8?q?feat:endpoint-query=20=E5=9B=BE=E8=A1=A8?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8D=95=E4=BD=8D=E8=BD=AC=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/bottomBox/tabs/endpointQueryTab.vue | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/nezha-fronted/src/components/common/bottomBox/tabs/endpointQueryTab.vue b/nezha-fronted/src/components/common/bottomBox/tabs/endpointQueryTab.vue index 6304e2303..682553449 100644 --- a/nezha-fronted/src/components/common/bottomBox/tabs/endpointQueryTab.vue +++ b/nezha-fronted/src/components/common/bottomBox/tabs/endpointQueryTab.vue @@ -159,11 +159,11 @@
{{$t("project.endpoint.dialogTitle")}}
- +
- + @@ -214,6 +214,7 @@ panelData: [], //chart-box的panel下拉框数据, hideSameLabels: true, sameLabels:['instance','module','project','asset','endpoint','datacenter'], + chartUnit:5 } }, methods: { @@ -236,6 +237,7 @@ metricInfo.elements.push({expression: this.selectedEndpoints[i].element, type: type}); } this.$refs.addChartModal.createData(-1, metricInfo); + this.$refs.addChartModal.setUnit(this.chartUnit) }, dropdownHandler(show) { if (show) { @@ -434,6 +436,12 @@ dialogClose:function(){ this.graphShow=false; }, + chartUnitChange:function(unit){ + this.chartUnit=unit; + this.$nextTick(()=>{ + this.queryChartDate() + }) + }, queryChartDate:function(){ let start = this.searchTime[0]?this.searchTime[0]:this.getTime(-1, 'h'); let end = this.searchTime[1]?this.searchTime[1]:this.getTime(0, 'h')