From f670802868fe3c5cdc46706aa3b0d03493c61fad Mon Sep 17 00:00:00 2001 From: chendaofei <857448963@qq.com> Date: Thu, 24 Jul 2025 09:33:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../online/runningCondition/index.vue | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/src/views/pqs/voltageSags/monitoringPoint/online/runningCondition/index.vue b/src/views/pqs/voltageSags/monitoringPoint/online/runningCondition/index.vue index 27a36f6c..d2e6d4cc 100644 --- a/src/views/pqs/voltageSags/monitoringPoint/online/runningCondition/index.vue +++ b/src/views/pqs/voltageSags/monitoringPoint/online/runningCondition/index.vue @@ -71,16 +71,10 @@ const init = () => { const initFirst = () => { let months = new Array() let handle = new Array() - let year = firstData.value[0].year + let year = firstData.value[0].dateView for (let i = 0; i < firstData.value.length; i++) { - if (formData.timeFlag == 0) { - months[i] = firstData.value[i].month - months[0] = firstData.value[i].month + '\n' + '(' + year + ')' - } else { - months[i] = firstData.value[i].month + '-' + firstData.value[i].day - months[0] = firstData.value[i].month + '-' + firstData.value[i].day + '\n' + '(' + year + ')' - } + months[i] = firstData.value[i].dateView handle.push(firstData.value[i].onlineRate) } firstOptions.value = { @@ -107,9 +101,9 @@ const initFirst = () => { fontSize: 14 }, backgroundColor: 'rgba(0,0,0,0.55)', - formatter: function (params: any) { + formatter: function(params: any) { let tips = '' - tips += '时间:' + year + '-' + params[0].name + '
' + tips += '时间:' + year + '
' for (let i = 0; i < params.length; i++) { if (params[i].value == 3.14159) { tips += '在线率' + ':暂无数据
' @@ -236,7 +230,7 @@ const initSecond = () => { fontSize: 14 }, backgroundColor: 'rgba(0,0,0,0.55)', - formatter: function (params: any) { + formatter: function(params: any) { let res = '' res += `${params[0].value[0]}:${params[0].value[1] == '0' ? '中断' : '正常'}` //params[0].value[0] + ':' //+ params[0].value[1] == '0' ? '中断' : '正常' @@ -272,7 +266,7 @@ const initSecond = () => { color: 'blue' }, // 这里重新定义就可以 - formatter: function (value: number) { + formatter: function(value: number) { let texts = [] if (value === 2) { texts.push('退出')