修改正式检测,使其能按照通道进行页面展示

This commit is contained in:
caozehui
2024-12-20 10:19:58 +08:00
parent ebc2ac1a41
commit 93b67fe845
8 changed files with 2206 additions and 2172 deletions

View File

@@ -1,42 +1,28 @@
<template>
<div class="table-main">
<el-collapse v-model="activeName" accordion style="width: 100%;height:335px">
<el-collapse-item v-for="(item, index) in tableData" :key="index+1" :title="'通道'+ (index+1)" :name="'通道'+ (index+1)">
<el-table :data="item.rawDataItems" stripe border :header-cell-style="{ textAlign: 'center' } "
:cell-style="{ textAlign: 'center' }" height="335px" style="width: 100%;max-height: 250px;overflow-y: auto;">
<el-table-column type="index" fixed="left" label="序号" width="70"/>
<el-table-column prop="updateTime" label="数据时间"/>
<el-table-column prop="L1" label="L1V"/>
<el-table-column prop="L2" label="L2V"/>
<el-table-column prop="L3" label="L3V"/>
</el-table>
</el-collapse-item>
</el-collapse>
<el-table :data="tableData" stripe border :header-cell-style="{ textAlign: 'center' } "
:cell-style="{ textAlign: 'center' }" height="335px"
style="width: 100%;">
<el-table-column type="index" label="序号" width="70" fixed="left"/>
<el-table-column prop="updateTime" label="数据时间"/>
<el-table-column prop="L1" label="L1V"/>
<el-table-column prop="L2" label="L2V"/>
<el-table-column prop="L3" label="L3V"/>
</el-table>
</div>
</template>
<script lang="tsx" setup>
import type {RawData} from "@/api/check/interface";
import type {RawDataItem} from "@/api/check/interface";
const {tableData} = defineProps<{
tableData:RawData[]
tableData: RawDataItem[]
}>()
const activeName = ref('通道1')
// 清空数据
const clear = () => {
activeName.value = '通道1'
}
defineExpose({
clear
})
</script>
<style scoped>