修改测试bug
This commit is contained in:
@@ -120,7 +120,13 @@ const init = () => {
|
||||
echartsData.value = {
|
||||
|
||||
options: {
|
||||
|
||||
legend: {
|
||||
right: 70,
|
||||
top: 5,
|
||||
data: res.data.map((item: any[]) => {
|
||||
return item[0]?.anotherName
|
||||
})
|
||||
},
|
||||
grid: {
|
||||
top: '60px',
|
||||
left: '10px',
|
||||
@@ -176,11 +182,7 @@ const init = () => {
|
||||
backgroundColor: 'rgba(0,0,0,0.35)',
|
||||
borderWidth: 0
|
||||
},
|
||||
legend: {
|
||||
data: res.data.map((item: any[]) => {
|
||||
return item[0]?.anotherName
|
||||
})
|
||||
},
|
||||
|
||||
yAxis: {
|
||||
name: `单位:(${arr[0].unit == null ? ' / ' : arr[0].unit})`,
|
||||
type: 'value',
|
||||
@@ -271,6 +273,7 @@ const init = () => {
|
||||
if ((echartsData.value.legend = ['A相', 'B相', 'C相'])) {
|
||||
echartsData.value.color = ['#FFCC00', '#009900', '#CC0000']
|
||||
}
|
||||
|
||||
} else {
|
||||
echartsData.value = null
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
</el-form-item>
|
||||
</template>
|
||||
<template #operation>
|
||||
<!-- <el-button type="primary" :icon="Search" @click="handleSearch">查询</el-button> -->
|
||||
<el-button type="primary" :icon="Search" @click="handleSearch">查询</el-button>
|
||||
<el-button type="primary" :icon="Setting" @click="handleUpDevice">补召</el-button>
|
||||
<el-button :icon="Back" @click="go(-1)">返回</el-button>
|
||||
</template>
|
||||
@@ -54,10 +54,13 @@ import { mainHeight } from '@/utils/layout'
|
||||
import { VxeUI, VxeTableInstance, VxeTableEvents } from 'vxe-table'
|
||||
import {
|
||||
Back,
|
||||
Setting
|
||||
Setting, Search
|
||||
} from '@element-plus/icons-vue'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import mqtt from 'mqtt'
|
||||
defineOptions({
|
||||
name: 'supplementaryRecruitment'
|
||||
})
|
||||
const checkList: any = ref([])
|
||||
// const props = defineProps(['lineId'])
|
||||
const { go } = useRouter() // 路由
|
||||
@@ -161,6 +164,9 @@ const connectMqtt = () => {
|
||||
}
|
||||
mqttRef.value = mqtt.connect(url, options)
|
||||
}
|
||||
const handleSearch = () => {
|
||||
getMakeUpDataList(route.value)
|
||||
}
|
||||
connectMqtt()
|
||||
mqttRef.value.on('connect', () => {
|
||||
// ElMessage.success('连接mqtt服务器成功!')
|
||||
|
||||
@@ -60,7 +60,7 @@ const tableStore: any = new TableStore({
|
||||
},
|
||||
{
|
||||
field: 'featureAmplitude',
|
||||
title: '暂降幅值(%)',
|
||||
title: '暂降(聚升)幅值(%)',
|
||||
minWidth: 100,
|
||||
formatter: (row: any) => {
|
||||
row.cellValue = row.cellValue + '' ? row.cellValue.toFixed(2) : '/'
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<div>
|
||||
<!-- 历史趋势数据 -->
|
||||
<div>
|
||||
<TableHeader ref="tableHeaderRef" :showSearch="false" @selectChange="selectChange" :key="numKey">
|
||||
<template v-slot:select :key="num">
|
||||
<TableHeader ref="tableHeaderRef" :showSearch="false" @selectChange="selectChange" >
|
||||
<template v-slot:select >
|
||||
<el-form-item>
|
||||
<DatePicker ref="datePickerRef"></DatePicker>
|
||||
</el-form-item>
|
||||
@@ -230,7 +230,8 @@ const init = async () => {
|
||||
itemGap: 10,
|
||||
type: 'scroll', // 开启滚动分页
|
||||
// orient: 'vertical', // 垂直排列
|
||||
top: 10,
|
||||
top: 5,
|
||||
right: 70,
|
||||
|
||||
width: 400,
|
||||
height: 50
|
||||
@@ -599,21 +600,10 @@ const onCountChange = (val: any, index: any) => {
|
||||
}
|
||||
}
|
||||
const flag = ref(true)
|
||||
const numKey = ref(0)
|
||||
const onIndexChange = (val: any) => {
|
||||
num.value += 1
|
||||
flag.value = true
|
||||
setTimeout(() => {
|
||||
countData.value.forEach((item: any) => {
|
||||
if (item.countOptions.length > 0) {
|
||||
flag.value = false
|
||||
return
|
||||
}
|
||||
})
|
||||
if (flag.value) {
|
||||
numKey.value += 1
|
||||
}
|
||||
}, 500)
|
||||
|
||||
|
||||
// if (val.length == 0) {
|
||||
// searchForm.value.index = [indexOptions.value[0].id]
|
||||
|
||||
Reference in New Issue
Block a user