修改测试问题
This commit is contained in:
@@ -410,6 +410,20 @@ const initWave = (
|
||||
'#CC00FF',
|
||||
'#FF9999'
|
||||
]
|
||||
}
|
||||
let titlename = ''
|
||||
if (props.boxoList.systemType == 'ZL' || props.boxoList.systemType == 'YPT') {
|
||||
|
||||
|
||||
if (props.wp.channelNames[1].includes('L')) {
|
||||
titlename = '电网侧'
|
||||
}
|
||||
if (props.wp.channelNames[1].includes('S')) {
|
||||
titlename = '负载侧'
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
const option = {
|
||||
@@ -515,7 +529,7 @@ const initWave = (
|
||||
},
|
||||
yAxis: {
|
||||
type: 'value',
|
||||
name: unit,
|
||||
name: unit + (titlename ? '_' + titlename : ''),
|
||||
title: {
|
||||
align: 'high',
|
||||
offset: 0,
|
||||
@@ -694,28 +708,41 @@ const drawPics = (
|
||||
}
|
||||
|
||||
let titlename = ''
|
||||
if (props.boxoList.systemType == 'ZL') {
|
||||
if (props.boxoList.systemType == 'ZL' || props.boxoList.systemType == 'YPT') {
|
||||
const str = waveId.split('e')
|
||||
const str1 = Number(str[1])
|
||||
console.log("🚀 ~ drawPics ~ props.wp.channelNames:", props.wp.channelNames)
|
||||
|
||||
props.wp.channelNames.forEach((element: string, i: number) => {
|
||||
if (i == 4 || i == 7 || i == 10) {
|
||||
if (str1 == 1 && i == 4) {
|
||||
const s = element.split('A')
|
||||
const s1 = s[0] == 'LI' ? '电网侧-电流' : s[0] + '侧' + s[1]
|
||||
titlename = s1 + ' ' + title
|
||||
if ((str1 == 1 && i == 4) || (str1 == 2 && i == 7) || (str1 == 3 && i == 10)) {
|
||||
|
||||
|
||||
if (element.includes('L')) {
|
||||
titlename = '电网侧'
|
||||
}
|
||||
if (str1 == 2 && i == 7) {
|
||||
const s = element.split('A')
|
||||
const s1 = s[0] == 'SU' ? '负载侧-电压' : s[0] + '侧' + s[1]
|
||||
titlename = s1 + ' ' + title
|
||||
}
|
||||
if (str1 == 3 && i == 10) {
|
||||
const s = element.split('A')
|
||||
const s1 = s[0] == 'SI' ? '负载侧-电流' : s[0] + '侧' + s[1]
|
||||
titlename = s1 + ' ' + title
|
||||
if (element.includes('S')) {
|
||||
titlename = '负载侧'
|
||||
}
|
||||
|
||||
// if (str1 == 1 && i == 4) {
|
||||
// const s = element.split('A')
|
||||
// const s1 = s[0] == 'LI' ? '电网侧' : ''//s[0] + '侧' + s[1]
|
||||
// titlename = s1 //+ ' ' + title
|
||||
// }
|
||||
// if (str1 == 2 && i == 7) {
|
||||
// const s = element.split('A')
|
||||
// const s1 = s[0] == 'SU' ? '负载侧' : ''//s[0] + '侧' + s[1]
|
||||
// titlename = s1 //+ ' ' + title
|
||||
// }
|
||||
// if (str1 == 3 && i == 10) {
|
||||
// const s = element.split('A')
|
||||
// const s1 = s[0] == 'SI' ? '负载侧' : ''//s[0] + '侧' + s[1]
|
||||
// titlename = s1 //+ ' ' + title
|
||||
// }
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
}
|
||||
|
||||
const waveIds = document.getElementById(waveId)
|
||||
@@ -830,7 +857,7 @@ const drawPics = (
|
||||
},
|
||||
yAxis: {
|
||||
type: 'value',
|
||||
name: unit,
|
||||
name: unit + (titlename ? '_' + titlename : ''),
|
||||
title: {
|
||||
align: 'high',
|
||||
offset: 0,
|
||||
|
||||
Reference in New Issue
Block a user