From 7255c3ea900afa6036769f1c25438c7f885172f9 Mon Sep 17 00:00:00 2001
From: GGJ <357021191@qq.com>
Date: Fri, 6 Dec 2024 16:30:16 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=95=8F=E6=84=9F=E5=85=83?=
=?UTF-8?q?=E5=99=A8=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../businessUser/event/toleranceCurve.vue | 54 +++++++++----------
1 file changed, 24 insertions(+), 30 deletions(-)
diff --git a/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue b/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue
index 1674cf6c..072ee05f 100644
--- a/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue
+++ b/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue
@@ -4,32 +4,18 @@
-
+
-
+
-
-
+
+
@@ -59,12 +45,12 @@
+ @change='reDrawPic' />
p.u.
+ @change='reDrawPic' />
ms
@@ -73,12 +59,12 @@
+ @change='reDrawPic' />
p.u.
+ @change='reDrawPic' />
ms
@@ -153,8 +139,9 @@ const search = async (id: string, beginTime: string, endTime: string) => {
unitOptions.value = res.data
if (unitOptions.value.length > 0) {
form.unitId = unitOptions.value[0].id
- unit.value = unitOptions.value[0]
+ unit.value = JSON.parse(JSON.stringify(unitOptions.value[0]))
}
+
})
const data = {
@@ -168,6 +155,13 @@ const search = async (id: string, beginTime: string, endTime: string) => {
reDrawPic()
})
+}
+const changeUnit = (id: any) => {
+ if (id == undefined) return
+ let list = unitOptions.value.filter((item: any) => item.id == id)
+ unit.value = JSON.parse(JSON.stringify(list[0]))
+ reDrawPic()
+
}
const options = ref()
@@ -178,7 +172,7 @@ const initOptions = () => {
left: '10px'
},
tooltip: {
- formatter: function(a: any) {
+ formatter: function (a: any) {
if (a[0].value[3] == undefined) {
return
}
@@ -209,7 +203,7 @@ const initOptions = () => {
series: [
{
type: 'line',
- color:'#ff0000',
+ color: '#ff0000',
data: [
[unit.value.vtcTimeUpper / 1000, 0],
[unit.value.vtcTimeUpper / 1000, unit.value.vtcAmpUpper],
@@ -222,7 +216,7 @@ const initOptions = () => {
},
{
type: 'line',
- color:'#ff0000',
+ color: '#ff0000',
data: [
[unit.value.vtcTimeLower / 1000, 0],
[unit.value.vtcTimeLower / 1000, unit.value.vtcAmpLower],
@@ -261,9 +255,9 @@ const initOptions = () => {
const reDrawPic = () => {
//清洗要显示的数据
if (eventData.value.length > 0) {
- unOverEvent.value=[]
- overEvent.value=[]
- unKnownEvent.value=[]
+ unOverEvent.value = []
+ overEvent.value = []
+ unKnownEvent.value = []
for (let event of eventData.value) {
//判断落在哪个区域内
let eventTime = Number(event.duration) / 1000