实时数据-实时趋势页面调试

This commit is contained in:
zhujiyan
2024-07-31 10:42:04 +08:00
parent a545692e33
commit 44684c99ed
9 changed files with 658 additions and 380 deletions

View File

@@ -1,15 +1,15 @@
<template>
<div class="header_btn">
<el-button type="primary" size="small" @click="handleWaveFormAnalysis(0)" v-if="!isWaveCharts">
<!-- <el-button type="primary" size="small" @click="handleWaveFormAnalysis(0)" v-if="!isWaveCharts">
波形解析
</el-button>
</el-button> -->
<el-button type="primary" size="small" @click="handleBack" v-if="isWaveCharts" :icon="ArrowLeft">
返回
</el-button>
</div>
<div class="view">
<Table ref="tableRef" v-if="!isWaveCharts" />
<waveFormAnalysis ref="waveFormAnalysisRef" v-if="isWaveCharts" />
<waveFormAnalysis ref="waveFormAnalysisRef" v-if="isWaveCharts" :wp="wp" />
</div>
</template>
<script lang="ts" setup>
@@ -19,7 +19,16 @@ import TableStore from '@/utils/tableStore'
import Table from '@/components/table/index.vue'
import waveFormAnalysis from './components/waveFormAnalysis.vue'
import { ArrowLeft } from '@element-plus/icons-vue'
import { analyseWave } from '@/api/common'
const tableParams: any = ref({})
const refheader = ref()
const view = ref(true)
const view2 = ref(false)
const showBoxi = ref(true)
const bxactiveName = ref('ssbx')
const boxoList = ref({})
const wp = ref({})
const value = ref(1)
const tableStore: any = new TableStore({
url: '/cs-device-boot/csGroup/deviceDataByType',
publicHeight: 210,
@@ -79,8 +88,25 @@ const tableStore: any = new TableStore({
type: 'primary',
icon: 'el-icon-Check',
render: 'basicButton',
click: row => {
handleWaveFormAnalysis(row)
// disabled: row => {
// return !row.wavePath && row.evtParamTm < 20
// },
click: async row => {
row.loading = true
boxoList.value = row
await analyseWave(row.eventId)
.then(res => {
row.loading = false
if (res != undefined) {
wp.value = res.data
view.value = false
view2.value = true
}
})
.catch(() => {
row.loading = false
})
handleWaveFormAnalysis(wp.value)
}
}
]
@@ -105,9 +131,11 @@ const getTableParams = (val: any) => {
tableStore.index()
}
//波形解析组件
const waveFormAnalysisRef = ref()
const handleWaveFormAnalysis = (val: any) => {
console.log(val, '波形解析')
isWaveCharts.value = true
waveFormAnalysisRef.value.getWpData(val)
}
//返回
const handleBack = () => {