From afe2d0dba5d6e42d7999b62836ed5e4bea75391a Mon Sep 17 00:00:00 2001 From: zyh Date: Mon, 14 Nov 2022 16:00:18 +0800 Subject: [PATCH] =?UTF-8?q?feat=EF=BC=9ANEZ-2383=20chart=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=94=AF=E6=8C=81=20repeat=20=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E9=A1=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/rightBox/chart/chartRightBox.vue | 5 ++ .../rightBox/chart/otherChartConfig.vue | 46 ++++++++++++++++++- .../src/components/page/dashboard/panel.vue | 2 +- 3 files changed, 51 insertions(+), 2 deletions(-) diff --git a/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue b/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue index 04a3e10b7..bf2945f95 100644 --- a/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue +++ b/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue @@ -580,6 +580,11 @@ export default { result: '' } } + if (obj.type === 'group' && !obj.param.repeat) { + obj.param.repeat = { + variable: '' + } + } // this.editChart.varType = 1 if (obj.param.enable.legend && !obj.param.legend) { obj.param.legend = { placement: 'bottom', values: [], show: true } diff --git a/nezha-fronted/src/components/common/rightBox/chart/otherChartConfig.vue b/nezha-fronted/src/components/common/rightBox/chart/otherChartConfig.vue index 159ebc567..3ed9642d7 100644 --- a/nezha-fronted/src/components/common/rightBox/chart/otherChartConfig.vue +++ b/nezha-fronted/src/components/common/rightBox/chart/otherChartConfig.vue @@ -247,6 +247,46 @@ + +
+
+ {{$t('dashboard.repeat')}} + +
+ +
+ + + + + + +
+
+
@@ -320,7 +360,8 @@ export default { link: this.chartConfig.param.link, collapse: true, enable: { - visibility: false + visibility: false, + repeat: false }, showHeader: this.chartConfig.param.showHeader, visibility: { @@ -328,6 +369,9 @@ export default { operator: 'equal', varValue: '', result: 'show' + }, + repeat: { + variable: '' } } break diff --git a/nezha-fronted/src/components/page/dashboard/panel.vue b/nezha-fronted/src/components/page/dashboard/panel.vue index 77dabbace..32af35f83 100644 --- a/nezha-fronted/src/components/page/dashboard/panel.vue +++ b/nezha-fronted/src/components/page/dashboard/panel.vue @@ -42,7 +42,7 @@ -