检测流程样式调整

This commit is contained in:
GYYM
2024-11-20 21:30:05 +08:00
parent d673fc8685
commit b992b2653a
9 changed files with 1035 additions and 48 deletions

View File

@@ -10,7 +10,7 @@ export namespace Plan {
name: string; //检测计划名称 name: string; //检测计划名称
pattern: string; //模式,字典表(数字、模拟、比对) pattern: string; //模式,字典表(数字、模拟、比对)
father_Plan_Id?: string; //父计划ID father_Plan_Id?: string; //父计划ID
dataSource_Id: string; //数据源ID dataSource_Id: string[]; //数据源ID
script_Id: string; //检测脚本ID script_Id: string; //检测脚本ID
error_Sys_Id: string;//误差体系ID error_Sys_Id: string;//误差体系ID
test_State: string; //检测状态 test_State: string; //检测状态
@@ -30,6 +30,7 @@ export namespace Plan {
source_Id: string[]; source_Id: string[];
device_Id?: string[]; device_Id?: string[];
testSourceList?: string[];//临时测试 testSourceList?: string[];//临时测试
dataSource_Ids:string;
} }
// // 检测计划列表 // // 检测计划列表
// export interface PlanList { // export interface PlanList {

View File

@@ -246,7 +246,8 @@ const planData = ref<Plan.PlanAndSourceBO[]>([
'pattern':'1', 'pattern':'1',
"source_Id" : ['1'], "source_Id" : ['1'],
"testSourceName":'标准源-福禄克-6100A', "testSourceName":'标准源-福禄克-6100A',
'dataSource_Id':'1', 'dataSource_Id':['1'],
'dataSource_Ids':'实时数据',
'script_Id':'1', 'script_Id':'1',
'error_Sys_Id':'1', 'error_Sys_Id':'1',
'test_State':'1', 'test_State':'1',
@@ -260,7 +261,8 @@ const planData = ref<Plan.PlanAndSourceBO[]>([
"source_Id" : ['5','6','7','8'], "source_Id" : ['5','6','7','8'],
"testSourceName":'高精度设备-PQV520-1', "testSourceName":'高精度设备-PQV520-1',
'father_Plan_Id':'1', 'father_Plan_Id':'1',
'dataSource_Id':'2', 'dataSource_Id':['5'],
'dataSource_Ids':'分钟统计数据CP95值',
'script_Id':'2', 'script_Id':'2',
'error_Sys_Id':'2', 'error_Sys_Id':'2',
'test_State':'2', 'test_State':'2',
@@ -277,7 +279,8 @@ const planData = ref<Plan.PlanAndSourceBO[]>([
"source_Id" : ['3'], "source_Id" : ['3'],
"testSourceName":'标准源-丹迪克-DKLN1', "testSourceName":'标准源-丹迪克-DKLN1',
'father_Plan_Id':'1', 'father_Plan_Id':'1',
'dataSource_Id':'3', 'dataSource_Id':['1'],
'dataSource_Ids':'实时数据',
'script_Id':'3', 'script_Id':'3',
'error_Sys_Id':'3', 'error_Sys_Id':'3',
'test_State':'1', 'test_State':'1',

View File

@@ -27,22 +27,22 @@
<div class="dialog-right"> <div class="dialog-right">
<el-collapse v-model="collapseActiveName" accordion> <el-collapse v-model="collapseActiveName" accordion>
<el-collapse-item title="源通讯校验" name="1"> <el-collapse-item title="源通讯校验" name="1">
<div> <div class = "div-log">
暂无数据等待检测开始 暂无数据等待检测开始
</div> </div>
</el-collapse-item> </el-collapse-item>
<el-collapse-item title="设备通讯校验" name="2"> <el-collapse-item title="设备通讯校验" name="2">
<div> <div class = "div-log">
暂无数据等待检测开始 暂无数据等待检测开始
</div> </div>
</el-collapse-item> </el-collapse-item>
<el-collapse-item title="协议校验" name="3"> <el-collapse-item title="协议校验" name="3">
<div> <div class = "div-log">
暂无数据等待检测开始 暂无数据等待检测开始
</div> </div>
</el-collapse-item> </el-collapse-item>
<el-collapse-item title="相序校验" name="4"> <el-collapse-item title="相序校验" name="4">
<div> <div class = "div-log">
暂无数据等待检测开始 暂无数据等待检测开始
</div> </div>
</el-collapse-item> </el-collapse-item>
@@ -153,6 +153,7 @@ watch(ts, function (newValue, oldValue) {
<style scoped> <style scoped>
.test-dialog{ .test-dialog{
height: 350px;
display: flex; display: flex;
flex-direction: row; /* 横向排列 */ flex-direction: row; /* 横向排列 */
@@ -162,10 +163,15 @@ watch(ts, function (newValue, oldValue) {
} */ } */
} }
.dialog-left{ .dialog-left{
width: 15%;
margin-left: 20px; margin-left: 20px;
} }
.dialog-right{ .dialog-right{
margin-left: 20px; margin-left: 20px;
width: 500px width: 80%;
height: 100%;
}
.div-log{
height: 100px;
} }
</style> </style>

View File

@@ -115,14 +115,14 @@
v-if="form.activeTabs === 3" v-if="form.activeTabs === 3"
>生成</el-button >生成</el-button
> >
<el-button <!-- <el-button
type="primary" type="primary"
link link
:icon="View" :icon="View"
@click="openDrawer('数据查看', scope.row)" @click="openDrawer('数据查看', scope.row)"
v-if="form.activeTabs === 4" v-if="form.activeTabs === 4"
>数据查看</el-button >数据查看</el-button
> > -->
<el-button <el-button
type="primary" type="primary"
link link

View File

@@ -0,0 +1,67 @@
<template>
<el-table
:data="tableData"
:row-class-name="tableRowClassName" row-key="id" height="300px" :header-cell-style="{ background: '#003078', color: '#eee', textAlign: 'center' } " style="width: 100%" border v-on:cell-click="handleClick"
>
<el-table-column prop="date" label="Date" width="180" />
<el-table-column prop="name" label="Name" width="180" />
<el-table-column prop="address" label="Address" />
</el-table>
</template>
<script lang="ts" setup>
interface User {
date: string
name: string
address: string
}
const handleClick = (row:any) => {
console.log(111)
};
const tableRowClassName = ({
row,
rowIndex,
}: {
row: User
rowIndex: number
}) => {
if (rowIndex === 1) {
return 'warning-row'
} else if (rowIndex === 3) {
return 'success-row'
}
return ''
}
const tableData: User[] = [
{
date: '2016-05-03',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-02',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-04',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-01',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
]
</script>
<style>
.el-table .warning-row {
--el-table-tr-bg-color: var(--el-color-warning-light-9);
}
.el-table .success-row {
--el-table-tr-bg-color: var(--el-color-success-light-9);
}
</style>

View File

@@ -27,12 +27,141 @@
> >
</div> </div>
<!-- background: '#f5f7fa', color: '#606266' -->
<!-- v-on:cell-click="handleClick" -->
<div class="dialog-content"> <div class="dialog-content">
<el-table :data="errorData" :header-cell-style="{ textAlign: 'center' } " :cell-style="{ textAlign: 'center' }" style="width: 100%" border v-on:cell-click="handleClick">
<el-table-column fixed prop="deviceName" label="检测项目" /> <el-table :key="tableKey" :data="tableData" :row-class-name="tableRowClassName" row-key="id" height="545px" :header-cell-style="{ background: '#003078', color: '#eee', textAlign: 'center' } " :cell-style="{ textAlign: 'center' }" style="width: 100%" border>
<el-table-column prop="updataTime" label="被检通道1" /> <!-- <el-table :data="tableData" :row-class-name="tableRowClassName" row-key="id" height="545px" :header-cell-style="{ background: '#003078', color: '#eee', textAlign: 'center' } " style="width: 100%" border> -->
<el-table-column prop="ErrorValue" label="被检通道2" /> <el-table-column fixed prop="scriptItemName" label="检测项目" class="table-first-column" />
<el-table-column prop="Result" label="被检通道3" />
<el-table-column label="被检通道1" >
<template #default="scope">
<el-tooltip :content="scope.row.resultType1==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType1=='info'"
:type="scope.row.resultType1"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue1 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道2">
<template #default="scope">
<el-tooltip :content="scope.row.resultType2==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType2=='info'"
:type="scope.row.resultType2"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue2 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道3">
<template #default="scope">
<el-tooltip :content="scope.row.resultType3==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType3=='info'"
:type="scope.row.resultType3"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue3 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道4">
<template #default="scope">
<el-tooltip :content="scope.row.resultType4==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType4=='info'"
:type="scope.row.resultType4"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue4 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column p label="被检通道5">
<template #default="scope">
<el-tooltip :content="scope.row.resultType5==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType5=='info'"
:type="scope.row.resultType5"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue5 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道6">
<template #default="scope">
<el-tooltip :content="scope.row.resultType6==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
tip
:disabled = "scope.row.resultType6=='info'"
:type="scope.row.resultType6"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue6 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道7">
<template #default="scope">
<el-tooltip :content="scope.row.resultType7==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType7=='info'"
:type="scope.row.resultType7"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue7 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="被检通道8">
<template #default="scope">
<el-tooltip :content="scope.row.resultType8==='info' ? '暂无数据' : '点击查看详情'" placement="top">
<el-button
:disabled = "scope.row.resultType8=='info'"
:type="scope.row.resultType8"
size="small"
@click="handleClick(scope.row)"
>
{{ scope.row.resultValue8 }}
</el-button>
</el-tooltip>
</template>
</el-table-column>
<!-- <el-table-column v-for="(item, index) in monitorList" :key="index" :prop="item.prop" :label="item.label">
</el-table-column> -->
</el-table> </el-table>
</div> </div>
<div class="dialog-log"> <div class="dialog-log">
@@ -45,6 +174,7 @@
</el-collapse> </el-collapse>
</div> </div>
</div> </div>
<resultPopup <resultPopup
:visible="resultDialogVisible" :visible="resultDialogVisible"
@update:visible="resultDialogVisible = $event" @update:visible="resultDialogVisible = $event"
@@ -58,7 +188,84 @@
import { VideoPause,Refresh,Close } from '@element-plus/icons-vue' import { VideoPause,Refresh,Close } from '@element-plus/icons-vue'
import resultPopup from './resultPopup.vue' import resultPopup from './resultPopup.vue'
import dataCheckSingleChannelSingleTestPopup from './dataCheckSingleChannelSingleTestPopup.vue' import dataCheckSingleChannelSingleTestPopup from './dataCheckSingleChannelSingleTestPopup.vue'
import { log } from 'console';
import temptest from './temptest.vue'
const currentRow = ref<{ id: number; scriptItemName: string; name: string; address: string; hasChildren?: boolean; children?: User[] } | null>(null);
// const currentRow = ref(null); // 用于存储当前选中的行
const monitorList = ref([
{
deviceID: '1',
deviceName: '被检设备1',
monitorIdx: 1,
label:'被检设备1通道1',
prop: 'Result1',
},
{
deviceID: '1',
deviceName: '被检设备1',
monitorIdx: 2,
label:'被检设备1通道2',
prop: 'Result2',
},
{
deviceID: '2',
deviceName: '被检设备2',
monitorIdx: 1,
label:'被检设备2通道1',
prop: 'Result3',
},
{
deviceID: '2',
deviceName: '被检设备2',
monitorIdx: 2,
label:'被检设备2通道2',
prop: 'Result4',
}
])
const tableData1= [
{
date: '2016-05-03',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-02',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-04',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
{
date: '2016-05-01',
name: 'Tom',
address: 'No. 189, Grove St, Los Angeles',
},
]
const tableKey = ref(0);
const currentIdx = ref(0);
const tableRowClassName = ({
row,
rowIndex,
}: {
row: any
rowIndex: number
}) => {
// console.log(currentIdx.value,rowIndex,row)
if (row.id === currentIdx.value.toString()) {
return 'warning-row'
}
// else if (rowIndex === 3) {
// return 'success-row'
// }
return ''
}
const percentage = ref(0); const percentage = ref(0);
const customColors = [ const customColors = [
{ color: "#5cb87a", percentage: 100 }, //绿 { color: "#5cb87a", percentage: 100 }, //绿
@@ -67,7 +274,45 @@ const customColors = [
const isPause = ref<boolean>(false); const isPause = ref<boolean>(false);
const resultDialogVisible = ref(false) const resultDialogVisible = ref(false)
const dataCheckSingleChannelSingleTestDialogVisable = ref(false); const dataCheckSingleChannelSingleTestDialogVisable = ref(false);
function clear() {
}
const updateTableData = (id: string, field: string, value: any) => {
const item = tableData.value.find(item => item.id === id);
if (item) {
item[field] = value;
}
};
let timer: any = ref("");
const handlePauseTest = () => { const handlePauseTest = () => {
timer.value = setInterval(() => {
currentIdx.value++;
updateTableData(currentIdx.value.toString(),"resultType1","success")
updateTableData(currentIdx.value.toString(),"resultValue1","√")
tableKey.value ++;
if (percentage.value < 100) {
percentage.value = Math.trunc(currentIdx.value/12 * 100);
} else {
clearInterval(timer.value)
clear();
ElMessageBox.confirm(
'检测全部结束,你可以停留在此页面查看检测结果,或返回首页进行复检、报告生成和归档等操作',
'检测完成',
{
confirmButtonText: '确定',
type: 'success',
})
}
}, 5000);
return;
if (!isPause.value) { if (!isPause.value) {
} else { } else {
@@ -82,36 +327,675 @@ const handleFinishTest = () => {
}; };
const handleClick = (row:any) => { const handleClick = (row:any) => {
console.log(111) console.log(111,row)
dataCheckSingleChannelSingleTestDialogVisable.value = true; dataCheckSingleChannelSingleTestDialogVisable.value = true;
}; };
const errorData = ref([ interface User {
id: number
scriptItemName: string
name: string
address: string
hasChildren?: boolean
children?: User[]
}
//resultType2: 'success',
// resultValue2:'√',
// resultType3: 'danger',
// resultValue3:'×',
const tableData = ref([
{ {
deviceName: '额定条件下频率检测42.5Hz', id: '1',
updataTime: '', scriptItemName: '频率',
ErrorValue:'×', resultType1: 'info',
Result: '/', resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '1-1',
scriptItemName: '额定条件下的测量',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '1-1-1',
scriptItemName: '频率42.5Hz',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
}, },
{ {
deviceName: '额定条件下频率检测50Hz', id: '1-1-2',
updataTime: '/', scriptItemName: '频率50Hz',
ErrorValue:'', resultType1: 'info',
Result: '×', resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
}, },
{ {
deviceName: '额定条件下频率检测50.05Hz', id: '1-1-3',
updataTime: '—', scriptItemName: '频率50.5Hz',
ErrorValue:'', resultType1: 'info',
Result: '', resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
}, },
{ {
deviceName: '额定条件下频率检测57.5Hz', id: '1-1-4',
updataTime: '—', scriptItemName: '频率57.5Hz',
ErrorValue:'', resultType1: 'info',
Result: '', resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
}, },
]) ],
},
{
id: '1-2',
scriptItemName: '电压对频率测量的影响',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '1-2-1',
scriptItemName: '频率50.5Hz 电压10%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
],
},
{
id: '1-3',
scriptItemName: '谐波对频率测量的影响',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '1-3-1',
scriptItemName: '频率50.5Hz 谐波电压h3 10%Un;h7 10%Un;h11 10%Un;h15 4%Un; h19 5%Un; h23 5%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
],
},
],
},
{
id: '2',
scriptItemName: '电压',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '2-1',
scriptItemName: '额定条件下的测量',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '2-1-1',
scriptItemName: '频率50Hz 电压10%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '2-1-2',
scriptItemName: '频率50Hz 电压45%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '2-1-3',
scriptItemName: '频率50Hz 电压80%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '2-1-4',
scriptItemName: '频率50Hz 电压115%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '2-1-5',
scriptItemName: '频率50Hz 电压150%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
],
},
{
id: '2-2',
scriptItemName: '频率对电压测量的影响',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '2-2-1',
scriptItemName: '频率42.5Hz 电压80%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
],
},
{
id: '2-3',
scriptItemName: '谐波对电压测量的影响',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
children: [
{
id: '2-3-1',
scriptItemName: '频率50Hz 电压80%Un 谐波电压h3 10%Un;h7 10%Un;h11 10%Un;h15 4%Un; h19 5%Un; h23 5%Un',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
],
},
],
},
{
id: '3',
scriptItemName: '谐波电压',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '4',
scriptItemName: '谐波电流',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '5',
scriptItemName: '谐波有功功率',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '6',
scriptItemName: '间谐波电压',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '7',
scriptItemName: '间谐波电流',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '8',
scriptItemName: '暂态',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '9',
scriptItemName: '电流',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '10',
scriptItemName: '电压不平衡度',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '11',
scriptItemName: '电流不平衡度',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
{
id: '12',
scriptItemName: '短时闪变',
resultType1: 'info',
resultValue1:'-',
resultType2: 'info',
resultValue2:'-',
resultType3: 'info',
resultValue3:'-',
resultType4: 'info',
resultValue4:'-',
resultType5: 'info',
resultValue5:'-',
resultType6: 'info',
resultValue6:'-',
resultType7: 'info',
resultValue7:'-',
resultType8: 'info',
resultValue8:'-',
},
])
// const selectRow = (id: number) => {
// console.log(id);
// const row = tableData.find(item => item.id === id);
// console.log(row);
// if (row) {
// currentRow.value = row ;
// }
// };
// selectRow(2)
const currentStepStatus = ref<'error' | 'finish' | 'wait' | 'success' | 'process'>('finish'); const currentStepStatus = ref<'error' | 'finish' | 'wait' | 'success' | 'process'>('finish');
@@ -157,6 +1041,16 @@ watch(ts, function (newValue, oldValue) {
</script> </script>
<style scoped> <style scoped>
.el-table .warning-row {
--el-table-tr-bg-color: var(--el-color-warning-light-9);
}
.el-table .success-row {
--el-table-tr-bg-color: var(--el-color-success-light-9);
}
/* .table-first-column{
min-width: 250px !important;
text-align: left !important;
} */
.dialog{ .dialog{
display: flex; display: flex;
flex-direction: column; flex-direction: column;

View File

@@ -1,10 +1,11 @@
<template> <template>
<el-dialog :title="dialogTitle" :model-value="visible" @close="handleCancel" v-bind="dialogBig" width="1200px" height="900px"> <el-dialog :title="dialogTitle" :model-value="visible" @close="handleCancel" v-bind="dialogBig" width="1200px" height="1200px">
<!-- simple --> <!-- simple -->
<!-- :style="{color:node.label=='未检测'?'#F56C6C':node.label=='检测中'?'#E6A23C':'#67C23A'}" --> <!-- :style="{color:node.label=='未检测'?'#F56C6C':node.label=='检测中'?'#E6A23C':'#67C23A'}" -->
<el-steps class="test-head-steps" :space="200" :active="stepsActiveIndex" process-status="finish" finish-status="success" > <el-steps class="test-head-steps" simple :space="200" :active="stepsActiveIndex" process-status="finish" finish-status="success" >
<el-step title="预检测" :icon="stepsActiveIndex > 0 ? SuccessFilled : Edit" style="height:100px" /> <!-- style="height:100px" -->
<el-step title="预检测" :icon="stepsActiveIndex > 0 ? SuccessFilled : Edit" />
<el-step title="守时检测" :icon="stepsActiveIndex > 1 ? SuccessFilled :UploadFilled"/> <el-step title="守时检测" :icon="stepsActiveIndex > 1 ? SuccessFilled :UploadFilled"/>
<el-step title="系数校准" :icon="stepsActiveIndex > 2 ? SuccessFilled :Picture" /> <el-step title="系数校准" :icon="stepsActiveIndex > 2 ? SuccessFilled :Picture" />
<el-step title="正式检测" :icon="stepsActiveIndex > 3 ? SuccessFilled :Picture" /> <el-step title="正式检测" :icon="stepsActiveIndex > 3 ? SuccessFilled :Picture" />
@@ -376,10 +377,25 @@ const detectionOptions = ref([
<style scoped> <style scoped>
.test-head-steps{ .test-head-steps{
height: 200px; height: 50px;
margin-bottom: 20px; margin-bottom: 20px;
} }
.el-step__icon.is-text {
border-radius: 50%;
border: 4px solid;
width: 50px;
height: 50px;
border-color: inherit;
}
.el-step__icon.is-icon {
border-radius: 50%;
border: 4px solid;
width: 50px;
height: 50px;
border-color: inherit;
}
.test-head-steps .el-step__line{ .test-head-steps .el-step__line{
height:50px !important; height:50px !important;
} }
@@ -390,9 +406,9 @@ const detectionOptions = ref([
} }
.test-head-steps .el-step__icon{ .test-head-steps .el-step__icon{
width: 80px !important; width: 48px !important;
height:80px !important; height:48px !important;
font-size: 40px !important; /* 调整图标大小 */ font-size: 48px !important; /* 调整图标大小 */
line-height: 80px !important; /* 使图标居中 */ line-height: 80px !important; /* 使图标居中 */
} }

View File

@@ -17,7 +17,7 @@
</el-select> </el-select>
</el-form-item> --> </el-form-item> -->
<el-form-item label='检测源' prop='source_Id' :label-width='100'> <el-form-item label='检测源' prop='source_Id' :label-width='100'>
<el-select v-model="formData.source_Id" multiple placeholder="请选择检测源"> <el-select v-model="formData.source_Id" multiple collapse-tags placeholder="请选择检测源">
<el-option <el-option
v-for="plan in sourceDataList" v-for="plan in sourceDataList"
:key="plan.id" :key="plan.id"
@@ -27,7 +27,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="数据源" prop="dataSource_Id" :label-width="100"> <el-form-item label="数据源" prop="dataSource_Id" :label-width="100">
<el-select v-model="formData.dataSource_Id" placeholder="请选择数据源" autocomplete="off" :disabled="isReadOnly"> <el-select v-model="formData.dataSource_Id" multiple collapse-tags placeholder="请选择数据源" autocomplete="off" :disabled="isReadOnly">
<el-option <el-option
v-for="plan in testSoureDataList" v-for="plan in testSoureDataList"
:key="plan.id" :key="plan.id"
@@ -57,7 +57,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label='被检设备' :label-width='100' prop='device_Id'> <el-form-item label='被检设备' :label-width='100' prop='device_Id'>
<el-select v-model="formData.device_Id" multiple placeholder="请选择被检设备"> <el-select v-model="formData.device_Id" multiple collapse-tags placeholder="请选择被检设备">
<el-option <el-option
v-for="plan in deviceDataList" v-for="plan in deviceDataList"
:key="plan.id" :key="plan.id"

View File

@@ -217,11 +217,11 @@ const columns = reactive<ColumnProps<Plan.PlanAndSourceBO>[]>([
}, },
}, },
{ {
prop: 'dataSource_Id', prop: 'dataSource_Ids',
label: '数据源', label: '数据源',
width: 200, width: 200,
enum: testSoureDataList, // enum: testSoureDataList,
fieldNames: { label: 'label', value: 'id' }, // fieldNames: { label: 'label', value: 'id' },
}, },
{ {
prop: 'test_State', prop: 'test_State',