正式检测页面修改

This commit is contained in:
caozehui
2024-12-18 15:56:59 +08:00
parent 4cfca89895
commit 2715871017
5 changed files with 660 additions and 367 deletions

View File

@@ -1,177 +1,44 @@
<template>
<div class="table-container table-main">
<el-table :data="tableData" stripe border :header-cell-style="{ textAlign: 'center' } " :cell-style="{ textAlign: 'center' }" height="335px" style="width: 100%" >
<el-table-column prop="id" 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" />
<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>
</div>
</el-collapse-item>
</el-collapse>
</div>
</template>
<script lang="tsx" setup>
import{ElMessage, FormInstance,FormItemRule}from'element-plus'
import { defineProps, defineEmits, reactive,watch,ref, Ref } from 'vue';
import { dialogBig,dialogMiddle} from '@/utils/elementBind'
//import IndicatorTypeDialog from "@/views/machine/errorSystem/components/IndicatorTypeDialog.vue"; // 导入子组件
import {CirclePlus, Delete, EditPen,FolderOpened,CopyDocument} from '@element-plus/icons-vue'
import { useDictStore } from '@/stores/modules/dict'
const tableData = ref([
{
id: 1,
updateTime: "2024-10-10 09:30:00",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 2,
updateTime: "2024-10-10 09:30:03",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 3,
updateTime: "2024-10-10 09:30:06",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 4,
updateTime: "2024-10-10 09:30:09",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 5,
updateTime: "2024-10-10 09:30:12",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 6,
updateTime: "2024-10-10 09:30:15",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 7,
updateTime: "2024-10-10 09:30:18",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 8,
updateTime: "2024-10-10 09:30:21",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 9,
updateTime: "2024-10-10 09:30:24",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 10,
updateTime: "2024-10-10 09:30:27",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 11,
updateTime: "2024-10-10 09:30:30",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 12,
updateTime: "2024-10-10 09:30:33",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 13,
updateTime: "2024-10-10 09:30:36",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 14,
updateTime: "2024-10-10 09:30:39",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 15,
updateTime: "2024-10-10 09:30:42",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 16,
updateTime: "2024-10-10 09:30:45",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 17,
updateTime: "2024-10-10 09:30:48",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 18,
updateTime: "2024-10-10 09:30:51",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 19,
updateTime: "2024-10-10 09:30:54",
L1:57.73,
L2:57.73,
L3:57.73,
},
{
id: 20,
updateTime: "2024-10-10 09:30:57",
L1:57.73,
L2:57.73,
L3:57.73,
},
])
import type {RawData} from "@/api/check/interface";
const {tableData} = defineProps<{
tableData:RawData[]
}>()
const activeName = ref('通道1')
// 清空数据
const clear = () => {
activeName.value = '通道1'
}
defineExpose({
clear
})
</script>
<style scoped>
.table-container {
overflow-y: auto; /* 允许垂直滚动 */
overflow-x: hidden; /* 隐藏水平滚动条 */
}
</style>