联调 试运行 编辑功能 修改 在线监测页面
This commit is contained in:
@@ -1,6 +1,17 @@
|
||||
<template>
|
||||
<el-dialog draggable class="cn-operate-dialog" v-model="dialogVisible" :title="title" width="550px" top="20vh">
|
||||
<el-form :inline="false" :model="form" label-width="120px" :rules="rules" ref="formRef">
|
||||
<el-form-item for="-" label="本次定检时间:" prop="nowCheckTime">
|
||||
<el-date-picker
|
||||
v-model="form.nowCheckTime"
|
||||
placeholder="选择日期"
|
||||
format="YYYY-MM-DD"
|
||||
style="width: 100%"
|
||||
value-format="YYYY-MM-DD"
|
||||
type="date"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item for="-" label="报告文件:" class="uploadFile" prop="reportPath">
|
||||
<el-upload
|
||||
v-model:file-list="form.reportPath"
|
||||
@@ -56,12 +67,14 @@ const dialogVisible = ref(false)
|
||||
const form: any = ref({
|
||||
id: '',
|
||||
reportPath: [],
|
||||
description: ''
|
||||
description: '',
|
||||
nowCheckTime: ''
|
||||
})
|
||||
|
||||
//form表单校验规则
|
||||
const rules = {
|
||||
reportPath: [{ required: true, message: '请上传文件', trigger: 'change' }],
|
||||
nowCheckTime: [{ required: true, message: '请选择定检时间', trigger: 'change' }],
|
||||
description: [{ required: true, message: '请输入描述', trigger: 'blur' }]
|
||||
}
|
||||
|
||||
@@ -77,6 +90,7 @@ const open = async (text: string, tempData?: any) => {
|
||||
} else {
|
||||
form.value.reportPath = [{ name: tempData.checkFilePath.split('/')[2] }]
|
||||
form.value.description = tempData.description
|
||||
form.value.nowCheckTime = tempData.nowCheckTime
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,16 @@
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="处理状态">
|
||||
<el-select v-model="tableStore.table.params.state" clearable placeholder="请选处理状态">
|
||||
<el-option
|
||||
v-for="item in stateSelect"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</TableHeader>
|
||||
<Table ref="tableRef" />
|
||||
@@ -45,6 +55,16 @@ const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
const FormRef = ref()
|
||||
const statusSelect = dictData.statusSelect()
|
||||
const stateSelect = [
|
||||
{
|
||||
id: 0,
|
||||
name: '未处理'
|
||||
},
|
||||
{
|
||||
id: 1,
|
||||
name: '已处理'
|
||||
}
|
||||
]
|
||||
//申请联调
|
||||
const debugForms = ref()
|
||||
const tableStore = new TableStore({
|
||||
@@ -60,14 +80,27 @@ const tableStore = new TableStore({
|
||||
field: 'deviceName',
|
||||
title: '终端名称'
|
||||
},
|
||||
{
|
||||
field: 'thisTimeCheck',
|
||||
title: '本次定检时间'
|
||||
},
|
||||
{
|
||||
field: 'nextTimeCheck',
|
||||
title: '下次定检时间'
|
||||
},
|
||||
{
|
||||
field: 'overdueDay',
|
||||
title: '逾期天数',
|
||||
type: 'html',
|
||||
formatter: (row: any) => {
|
||||
return `<span style='color: ${
|
||||
row.row.overdueDay > 10 ? 'red' : row.row.overdueDay > 3 ? 'yellow' : ''
|
||||
};text-decoration: none'>${row.row.overdueDay}</span>`
|
||||
|
||||
let text = row.row.status == 2
|
||||
? '/'
|
||||
: `<span style='color: ${
|
||||
row.row.overdueDay > 10 ? 'red' : row.row.overdueDay > 3 ? 'yellow' : ''
|
||||
};text-decoration: none'>${row.row.overdueDay}</span>`
|
||||
|
||||
return text
|
||||
}
|
||||
},
|
||||
|
||||
@@ -113,7 +146,7 @@ const tableStore = new TableStore({
|
||||
return !row.processInstanceId
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
{
|
||||
name: 'edit',
|
||||
title: '报告上传',
|
||||
@@ -182,6 +215,7 @@ const tableStore = new TableStore({
|
||||
}
|
||||
})
|
||||
tableStore.table.params.status = ''
|
||||
tableStore.table.params.state = ''
|
||||
tableStore.table.params.searchValue = ''
|
||||
|
||||
provide('tableStore', tableStore)
|
||||
|
||||
Reference in New Issue
Block a user