联调 技术监督 草稿功能
This commit is contained in:
@@ -68,7 +68,7 @@
|
||||
for="-"
|
||||
label="关联电站:"
|
||||
v-if="form.customSubstationFlag == 0"
|
||||
prop="substation"
|
||||
:prop="dynamicProp"
|
||||
style="display: flex; align-items: center"
|
||||
>
|
||||
<el-cascader
|
||||
@@ -95,7 +95,8 @@
|
||||
:render-after-expand="false"
|
||||
/> -->
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="关联电站:" v-if="form.customSubstationFlag == 1" prop="substation">
|
||||
|
||||
<el-form-item for="-" label="关联电站:" v-if="form.customSubstationFlag == 1" :prop="dynamicProp">
|
||||
<el-input v-model="form.substation" placeholder="请输入关联电站"></el-input>
|
||||
</el-form-item>
|
||||
<!-- <el-form :model="form" label-width="auto"> -->
|
||||
@@ -135,13 +136,15 @@
|
||||
<template #footer v-if="title != '查看计划'">
|
||||
<div class="dialog-footer">
|
||||
<el-button @click="cancelFn">取消</el-button>
|
||||
<el-button type="primary" @click="submitFn">确定</el-button>
|
||||
|
||||
<el-button type="primary" @click="submitFn(true)">保存</el-button>
|
||||
<el-button type="primary" @click="submitFn(false)">提交审批</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive, nextTick } from 'vue'
|
||||
import { ref, computed, nextTick } from 'vue'
|
||||
import {
|
||||
addSurvey,
|
||||
auditSurvey,
|
||||
@@ -161,6 +164,13 @@ const dictData = useDictData()
|
||||
const supvTypeOptionList = dictData.getBasicData('supv_type')
|
||||
const title = ref('')
|
||||
const planAddition = ref(false)
|
||||
|
||||
const dynamicProp = computed(() => {
|
||||
return supvTypeOptionList.filter(item => item.id === form.value.supvType)[0]?.code == 'Technical_Super'
|
||||
? ''
|
||||
: 'substation'
|
||||
})
|
||||
|
||||
const defaultProps = ref({
|
||||
label: 'name',
|
||||
value: 'id',
|
||||
@@ -247,13 +257,43 @@ const detailById = (id: any) => {
|
||||
})
|
||||
}
|
||||
// 提交
|
||||
const submitFn = () => {
|
||||
const submitFn = (flag: boolean) => {
|
||||
if (flag) {
|
||||
const addForm = JSON.parse(JSON.stringify(form.value))
|
||||
|
||||
if (form.value.customSubstationFlag == 0) {
|
||||
addForm.substation = addForm.substation.length==0?'': addForm.substation.join(',')
|
||||
}
|
||||
addForm.saveOrCheckflag = '1'
|
||||
if (title.value == '计划新增') {
|
||||
addSurveyPlan(addForm).then(res => {
|
||||
cancelFn()
|
||||
emit('onsubmit')
|
||||
})
|
||||
}
|
||||
} else {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
let filePath = ''
|
||||
audit(filePath)
|
||||
//选择系统变电站
|
||||
const addForm = JSON.parse(JSON.stringify(form.value))
|
||||
if (form.value.customSubstationFlag == 0) {
|
||||
addForm.substation = addForm.substation.length==0?'': addForm.substation.join(',')
|
||||
}
|
||||
addForm.saveOrCheckflag = '2'
|
||||
if (title.value == '计划新增') {
|
||||
addSurveyPlan(addForm).then(res => {
|
||||
cancelFn()
|
||||
emit('onsubmit')
|
||||
})
|
||||
} else {
|
||||
updateSurveyPlan(addForm).then(res => {
|
||||
cancelFn()
|
||||
emit('onsubmit')
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
// 修改关联电站
|
||||
const changeArea = () => {
|
||||
@@ -268,23 +308,6 @@ const changeArea = () => {
|
||||
treeData.value = list
|
||||
}
|
||||
const audit = (filePath: any) => {
|
||||
//选择系统变电站
|
||||
const addForm = JSON.parse(JSON.stringify(form.value))
|
||||
if (form.value.customSubstationFlag == 0) {
|
||||
addForm.substation = addForm.substation.join(',')
|
||||
}
|
||||
if (title.value == '计划新增') {
|
||||
addSurveyPlan(addForm).then(res => {
|
||||
cancelFn()
|
||||
emit('onsubmit')
|
||||
})
|
||||
} else {
|
||||
updateSurveyPlan(addForm).then(res => {
|
||||
cancelFn()
|
||||
emit('onsubmit')
|
||||
})
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
// 上传文件
|
||||
|
||||
@@ -1,6 +1,16 @@
|
||||
<template>
|
||||
<TableHeader area datePicker nextFlag ref="TableHeaderRef">
|
||||
<template #select>
|
||||
<el-form-item label="监督类型">
|
||||
<el-select v-model="tableStore.table.params.supvType" clearable placeholder="请选择流程状态">
|
||||
<el-option
|
||||
v-for="item in supvTypeOptionList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="流程状态">
|
||||
<el-select v-model="tableStore.table.params.status" clearable placeholder="请选择流程状态">
|
||||
<el-option
|
||||
@@ -101,12 +111,14 @@ const tableStore = new TableStore({
|
||||
render: 'tag',
|
||||
minWidth: 80,
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -133,11 +145,25 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return !row.processInstanceId
|
||||
},
|
||||
click: row => {
|
||||
flag.value = true
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
@@ -175,6 +201,7 @@ const tableStore = new TableStore({
|
||||
})
|
||||
|
||||
tableStore.table.params.status = ''
|
||||
tableStore.table.params.supvType = ''
|
||||
provide('tableStore', tableStore)
|
||||
// 新增计划
|
||||
const add = () => {
|
||||
|
||||
@@ -2,6 +2,16 @@
|
||||
<template>
|
||||
<TableHeader area datePicker nextFlag ref="TableHeaderRef">
|
||||
<template v-slot:select>
|
||||
<el-form-item label="监督类型">
|
||||
<el-select v-model="tableStore.table.params.supvType" clearable placeholder="请选择流程状态">
|
||||
<el-option
|
||||
v-for="item in supvTypeOptionList"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="流程状态">
|
||||
<el-select v-model="tableStore.table.params.status" clearable placeholder="请选择流程状态">
|
||||
<el-option
|
||||
@@ -103,6 +113,7 @@ const tableStore = new TableStore({
|
||||
render: 'tag',
|
||||
minWidth: 140,
|
||||
custom: {
|
||||
0: 'warning',
|
||||
6: 'primary',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
@@ -110,6 +121,7 @@ const tableStore = new TableStore({
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
6: '新增',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
@@ -120,7 +132,7 @@ const tableStore = new TableStore({
|
||||
{
|
||||
field: 'createBy',
|
||||
title: '填报人',
|
||||
minWidth: 80,
|
||||
minWidth: 120,
|
||||
formatter: (row: any) => {
|
||||
return dictData.state.userList.filter(item => item.id == row.cellValue)[0]?.name
|
||||
}
|
||||
@@ -151,13 +163,29 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 6 || row.status == 4
|
||||
return row.status == 6 || !row.processInstanceId
|
||||
},
|
||||
click: row => {
|
||||
// planTestRef.value.open('查看计划', row)
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '编辑',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
@@ -194,6 +222,7 @@ const tableStore = new TableStore({
|
||||
})
|
||||
|
||||
tableStore.table.params.status = ''
|
||||
tableStore.table.params.supvType = ''
|
||||
|
||||
provide('tableStore', tableStore)
|
||||
// 新增计划
|
||||
|
||||
@@ -1080,7 +1080,7 @@ const disabledDate = time => {
|
||||
return false
|
||||
}
|
||||
//提交
|
||||
const confirmForm = (flag?: boolean) => {
|
||||
const confirmForm = (flag: boolean) => {
|
||||
if (flag) {
|
||||
//整理上传文件的数据
|
||||
// userType==0,1
|
||||
@@ -1138,10 +1138,11 @@ const confirmForm = (flag?: boolean) => {
|
||||
}
|
||||
}
|
||||
confirmFormData.saveOrCheckflag = '1'
|
||||
confirmFormData.id = resendId.value
|
||||
if (title.value != '用户档案录入') confirmFormData.id = resendId.value
|
||||
|
||||
submitFormData(confirmFormData).then(res => {
|
||||
ElMessage({
|
||||
message: '保存成功',
|
||||
message: '保存成功!',
|
||||
type: 'success'
|
||||
})
|
||||
ruleFormRef.value.resetFields()
|
||||
@@ -1149,7 +1150,7 @@ const confirmForm = (flag?: boolean) => {
|
||||
close()
|
||||
})
|
||||
} else {
|
||||
console.log(123213);
|
||||
|
||||
|
||||
ruleFormRef.value.validate((valid: any) => {
|
||||
if (valid) {
|
||||
@@ -1314,7 +1315,7 @@ const confirmForm = (flag?: boolean) => {
|
||||
confirmFormData.saveOrCheckflag = '2'
|
||||
if (title.value == '用户档案录入') {
|
||||
submitFormData(confirmFormData).then(res => {
|
||||
if (res.code == 'A0000') {
|
||||
|
||||
ElMessage({
|
||||
message: '新增成功',
|
||||
type: 'success'
|
||||
@@ -1322,14 +1323,14 @@ const confirmForm = (flag?: boolean) => {
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
close()
|
||||
}
|
||||
|
||||
})
|
||||
} else {
|
||||
console.log(confirmFormData)
|
||||
confirmFormData.id = resendId.value
|
||||
|
||||
updateFormData(confirmFormData).then(res => {
|
||||
if (res.code == 'A0000') {
|
||||
|
||||
ElMessage({
|
||||
message: '重新发起成功',
|
||||
type: 'success'
|
||||
@@ -1337,7 +1338,7 @@ const confirmForm = (flag?: boolean) => {
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
close()
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -158,7 +158,7 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.processInstanceId == null
|
||||
return !row.processInstanceId
|
||||
},
|
||||
click: row => {
|
||||
flag.value = true
|
||||
|
||||
@@ -48,7 +48,9 @@
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="submit">确认</el-button>
|
||||
<!-- <el-button type="primary" @click="submit">确认</el-button> -->
|
||||
<el-button type="primary" @click="submit(true)">保存</el-button>
|
||||
<el-button type="primary" @click="submit(false)">提交审批</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -84,7 +86,8 @@ const form = ref({
|
||||
deviceType: '1',
|
||||
devOriginalStatus: '0',
|
||||
devStatus: '',
|
||||
propertyNo: ''
|
||||
propertyNo: '',
|
||||
saveOrCheckflag: ''
|
||||
})
|
||||
|
||||
//form表单校验规则
|
||||
@@ -114,7 +117,7 @@ const open = async (text: string, tempData?: any) => {
|
||||
}
|
||||
form.value.deviceType = form.value.deviceType + ''
|
||||
changeDevStatus(form.value.deviceId, true)
|
||||
form.value.devStatus = form.value.devStatus + ''
|
||||
form.value.devStatus = form.value.devStatus ? form.value.devStatus + '' : ''
|
||||
} else {
|
||||
resetForm()
|
||||
// 在此处恢复默认表单
|
||||
@@ -133,9 +136,19 @@ const open = async (text: string, tempData?: any) => {
|
||||
/**
|
||||
* 提交用户表单数据
|
||||
*/
|
||||
const submit = () => {
|
||||
const submit = (flag: boolean) => {
|
||||
if (flag) {
|
||||
form.value.saveOrCheckflag = '1'
|
||||
|
||||
addRunningDevice(form.value).then(res => {
|
||||
ElMessage.success('保存成功!')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
} else {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
form.value.saveOrCheckflag = '2'
|
||||
if (form.value.devOriginalStatus == form.value.devStatus) {
|
||||
if (form.value.devOriginalStatus == '0') {
|
||||
ElMessage.warning('终端当前状态就是运行,无需变更!')
|
||||
@@ -146,20 +159,23 @@ const submit = () => {
|
||||
}
|
||||
} else {
|
||||
if (form.value.id) {
|
||||
await quitRunningDeviceUpdate(form.value)
|
||||
await quitRunningDeviceUpdate(form.value).then(res => {
|
||||
ElMessage.success('重新发起成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
} else {
|
||||
await addRunningDevice(form.value)
|
||||
await addRunningDevice(form.value).then(res => {
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -176,6 +192,7 @@ const changeDevStatus = async (event: any, flag?: boolean) => {
|
||||
await getDeviceDetailData(event).then(res => {
|
||||
//给当前终端赋值初始运行状态
|
||||
runFlag.value = res.data.runFlag + ''
|
||||
form.value.devOriginalStatus = runFlag.value
|
||||
if (!flag) form.value.devStatus = ''
|
||||
devStatuData.value = devStatusList.value.filter(item => item.value != res.data.runFlag)
|
||||
})
|
||||
|
||||
@@ -76,14 +76,17 @@ const tableStore = new TableStore({
|
||||
1: 'warning',
|
||||
2: 'danger',
|
||||
3: 'warning',
|
||||
4: 'info'
|
||||
4: 'info',
|
||||
null: 'primary'
|
||||
},
|
||||
|
||||
replaceValue: {
|
||||
0: '运行',
|
||||
1: '检修',
|
||||
2: '停运',
|
||||
3: '调试',
|
||||
4: '退运'
|
||||
4: '退运',
|
||||
null: '/'
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -92,16 +95,20 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
4: 'warning',
|
||||
null: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
4: '已取消'
|
||||
4: '已取消',
|
||||
null: '/'
|
||||
}
|
||||
},
|
||||
{ field: 'createTime', title: '开始时间', minWidth: 170 },
|
||||
@@ -130,6 +137,19 @@ const tableStore = new TableStore({
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
deviceQuitPopup.value.open('编辑', row)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -22,17 +22,17 @@
|
||||
<el-form-item label="监测点当前状态:">
|
||||
<el-select v-model="runFlag" disabled placeholder="请选择监测点" clearable class="select">
|
||||
<el-option
|
||||
v-for="item in runFlagData"
|
||||
:key="item.name"
|
||||
v-for="item in runFlagList "
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.name"
|
||||
:value="item.id"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="变更状态:" prop="devStatus">
|
||||
<el-select v-model="form.devStatus" placeholder="请选择监测点变更状态" clearable class="select">
|
||||
<el-option
|
||||
v-for="item in runFlagList"
|
||||
v-for="item in runFlagData"
|
||||
:key="item.id"
|
||||
:label="item.name"
|
||||
:value="item.id"
|
||||
@@ -59,7 +59,9 @@
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="submit">确认</el-button>
|
||||
<!-- <el-button type="primary" @click="submit">确认</el-button> -->
|
||||
<el-button type="primary" @click="submit(true)">保存</el-button>
|
||||
<el-button type="primary" @click="submit(false)">提交审批</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -90,14 +92,15 @@ const form = ref({
|
||||
deviceType: '2',
|
||||
devOriginalStatus: '0',
|
||||
devStatus: '',
|
||||
saveOrCheckflag: '',
|
||||
propertyNo: ''
|
||||
})
|
||||
const runFlagList = [
|
||||
{ id: 0, name: '投运' },
|
||||
{ id: 1, name: '检修' },
|
||||
{ id: 2, name: '停运' },
|
||||
{ id: 3, name: '调试' },
|
||||
{ id: 4, name: '退运' }
|
||||
{ id: '0', name: '投运' },
|
||||
{ id: '1', name: '检修' },
|
||||
{ id: '2', name: '停运' },
|
||||
{ id: '3', name: '调试' },
|
||||
{ id: '4', name: '退运' }
|
||||
]
|
||||
|
||||
//form表单校验规则
|
||||
@@ -128,7 +131,7 @@ const open = async (text: string, tempData?: any) => {
|
||||
}
|
||||
form.value.deviceType = form.value.deviceType + ''
|
||||
changeDevStatus(form.value.deviceId, true)
|
||||
form.value.devStatus = form.value.devStatus
|
||||
form.value.devStatus = form.value.devStatus ? form.value.devStatus + '' : ''
|
||||
} else {
|
||||
resetForm()
|
||||
// 在此处恢复默认表单
|
||||
@@ -145,9 +148,19 @@ const open = async (text: string, tempData?: any) => {
|
||||
/**
|
||||
* 提交用户表单数据
|
||||
*/
|
||||
const submit = () => {
|
||||
const submit = (flag: boolean) => {
|
||||
if (flag) {
|
||||
form.value.saveOrCheckflag = '1'
|
||||
|
||||
addRunningDevice(form.value).then(res => {
|
||||
ElMessage.success('保存成功!')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
} else {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
form.value.saveOrCheckflag = '2'
|
||||
if (form.value.devOriginalStatus == '4') {
|
||||
ElMessage.warning('终端当前状态就是退运,无需变更!')
|
||||
} else {
|
||||
@@ -166,6 +179,7 @@ const submit = () => {
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -198,7 +212,8 @@ const changeDevStatus = async (event: any, flag?: any) => {
|
||||
// form.value.devOriginalStatus = '4'
|
||||
// break
|
||||
// }
|
||||
runFlag.value = res.data.runFlag
|
||||
runFlag.value = runFlagList.filter(item => item.name == res.data.runFlag)[0].id
|
||||
form.value.devOriginalStatus = runFlag.value
|
||||
if (!flag) form.value.devStatus = ''
|
||||
runFlagData.value = runFlagList.filter(item => item.name != res.data.runFlag)
|
||||
})
|
||||
|
||||
@@ -75,14 +75,16 @@ const tableStore = new TableStore({
|
||||
1: 'warning',
|
||||
2: 'danger',
|
||||
3: 'warning',
|
||||
4: 'info'
|
||||
4: 'info',
|
||||
null: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '运行',
|
||||
1: '检修',
|
||||
2: '停运',
|
||||
3: '调试',
|
||||
4: '退运'
|
||||
4: '退运',
|
||||
null: '/'
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -95,14 +97,16 @@ const tableStore = new TableStore({
|
||||
1: 'warning',
|
||||
2: 'danger',
|
||||
3: 'warning',
|
||||
4: 'info'
|
||||
4: 'info',
|
||||
null: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '运行',
|
||||
1: '检修',
|
||||
2: '停运',
|
||||
3: '调试',
|
||||
4: '退运'
|
||||
4: '退运',
|
||||
null:'/'
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -111,12 +115,14 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -150,6 +156,19 @@ const tableStore = new TableStore({
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
deviceQuitPopup.value.open('编辑', row)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -85,6 +85,7 @@ const tableStore = new TableStore({
|
||||
minWidth: '150',
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
@@ -92,6 +93,7 @@ const tableStore = new TableStore({
|
||||
5: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -154,6 +156,27 @@ const tableStore = new TableStore({
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
feedbackPopup.value.open(
|
||||
'编辑',
|
||||
row.id,
|
||||
row.status,
|
||||
row.issueDetail,
|
||||
row.problemPath,
|
||||
row.takeStep,
|
||||
row.reportPath
|
||||
)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -51,7 +51,9 @@
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="close">取消</el-button>
|
||||
<el-button type="primary" @click="submit">确认</el-button>
|
||||
<!-- <el-button type="primary" @click="submit">确认</el-button> -->
|
||||
<el-button type="primary" @click="submit(true)">保存</el-button>
|
||||
<el-button type="primary" @click="submit(false)">提交审批</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -165,7 +167,22 @@ const close = () => {
|
||||
/**
|
||||
* 提交用户表单数据
|
||||
*/
|
||||
const submit = () => {
|
||||
const submit = (flag: boolean) => {
|
||||
if (flag) {
|
||||
let subForm = JSON.parse(JSON.stringify(form.value))
|
||||
subForm = {
|
||||
...subForm,
|
||||
reportPath: reportFilePath.value
|
||||
}
|
||||
subForm.saveOrCheckflag = '1'
|
||||
//此时该告警单处于待反馈状态
|
||||
addFeedback(subForm).then(res => {
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
} else {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
let subForm = JSON.parse(JSON.stringify(form.value))
|
||||
@@ -179,21 +196,25 @@ const submit = () => {
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
subForm.saveOrCheckflag = '2'
|
||||
if (form.value.status == '3') {
|
||||
await updateFeedback(subForm)
|
||||
await updateFeedback(subForm).then(res => {
|
||||
ElMessage.success('重新发起成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
} else {
|
||||
//此时该告警单处于待反馈状态
|
||||
await addFeedback(subForm)
|
||||
await addFeedback(subForm).then(res => {
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
defineExpose({ open })
|
||||
|
||||
@@ -77,6 +77,7 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
@@ -84,6 +85,7 @@ const tableStore = new TableStore({
|
||||
5: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -111,7 +113,22 @@ const tableStore = new TableStore({
|
||||
return !row.processInstanceId
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '编辑',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '报告上传',
|
||||
@@ -125,6 +142,7 @@ const tableStore = new TableStore({
|
||||
FormRef.value.open('报告上次', row)
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -32,7 +32,8 @@
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button @click="close()">取消</el-button>
|
||||
<el-button type="primary" @click="confirmForm()">确定</el-button>
|
||||
<el-button type="primary" @click="confirmForm(true)">保存</el-button>
|
||||
<el-button type="primary" @click="confirmForm(false)">提交审批</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -55,7 +56,7 @@ const props = defineProps({
|
||||
const dictData = useDictData()
|
||||
const dialogFormVisible = ref(false)
|
||||
const form: any = ref({})
|
||||
const ruleFormRef = ref(null)
|
||||
const ruleFormRef: any = ref(null)
|
||||
//定义切换form类型
|
||||
const selectFormType = ref('')
|
||||
selectFormType.value = '0'
|
||||
@@ -91,12 +92,12 @@ const open = (text: any, row: any) => {
|
||||
dialogFormVisible.value = true
|
||||
title.value = text
|
||||
form.value.id = row.id
|
||||
form.value.reason=row.reason
|
||||
form.value.reason = row.reason
|
||||
}
|
||||
const close = () => {
|
||||
//重置表单内容
|
||||
//取消表单校验状态
|
||||
ruleFormRef.value && ruleFormRef.value.resetFields()
|
||||
ruleFormRef.value && ruleFormRef.value?.resetFields()
|
||||
dialogFormVisible.value = false
|
||||
emits('onSubmit')
|
||||
resetForm()
|
||||
@@ -110,12 +111,24 @@ const disabledDate = time => {
|
||||
return time.getTime() < Date.now() - 8.64e7 // 8.64e7 毫秒数代表一天
|
||||
}
|
||||
//提交
|
||||
const confirmForm = () => {
|
||||
const confirmForm = (flag: boolean) => {
|
||||
if (flag) {
|
||||
// 提交监测点信息
|
||||
|
||||
//提交监测点联调信息
|
||||
form.value.saveOrCheckflag = '1'
|
||||
addMointorPointTempLinedebug(form.value).then(res => {
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
close()
|
||||
})
|
||||
} else {
|
||||
// 提交监测点信息
|
||||
ruleFormRef.value.validate(valid => {
|
||||
if (valid) {
|
||||
//提交监测点联调信息
|
||||
if (title.value != '重新发起') {
|
||||
form.value.saveOrCheckflag = '2'
|
||||
if (!(title.value == '重新发起' || title.value == '编辑')) {
|
||||
addMointorPointTempLinedebug(form.value).then(res => {
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
@@ -133,6 +146,7 @@ const confirmForm = () => {
|
||||
return false
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
|
||||
@@ -92,6 +92,7 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
@@ -99,6 +100,7 @@ const tableStore = new TableStore({
|
||||
5: 'primary'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -127,6 +129,19 @@ const tableStore = new TableStore({
|
||||
return !row.processInstanceId
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
debugForms.value.open('编辑', row)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'productSetting',
|
||||
title: '申请联调',
|
||||
|
||||
@@ -352,7 +352,8 @@
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button @click="close()">取消</el-button>
|
||||
<el-button type="primary" @click="confirmForm()">确定</el-button>
|
||||
<el-button type="primary" @click="confirmForm(true)">保存</el-button>
|
||||
<el-button type="primary" @click="confirmForm(false)">提交审批</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -974,8 +975,12 @@ const open = async (row: any) => {
|
||||
form.value.businessType = businessTypeList.value.filter(
|
||||
(item: any) => item.name == res.data.businessType
|
||||
)[0]?.id
|
||||
mainWiringDiagram.value = JSON.parse(JSON.stringify(res.data.mainWiringDiagram))
|
||||
form.value.mainWiringDiagram = JSON.parse(
|
||||
mainWiringDiagram.value =
|
||||
res.data.mainWiringDiagram.length == 0 ? [] : JSON.parse(JSON.stringify(res.data.mainWiringDiagram))
|
||||
form.value.mainWiringDiagram =
|
||||
res.data.mainWiringDiagram.length == 0
|
||||
? []
|
||||
: JSON.parse(
|
||||
JSON.stringify([
|
||||
{
|
||||
name: res.data.mainWiringDiagram.split('/')[2]
|
||||
@@ -1057,7 +1062,40 @@ const disabledDate = time => {
|
||||
}
|
||||
const activeName = ref('0')
|
||||
//提交
|
||||
const confirmForm = () => {
|
||||
const confirmForm = (flag: boolean) => {
|
||||
if (flag) {
|
||||
form.value.reportDate = window.XEUtils.toDateString(form.value.reportDate, 'yyyy-MM-dd')
|
||||
let confirmFormData = JSON.parse(JSON.stringify(form.value))
|
||||
if (!form.value.pt1 || !form.value.pt2) {
|
||||
return ElMessage({
|
||||
message: '请输入PT变比',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
if (!form.value.ct1 || !form.value.ct2) {
|
||||
return ElMessage({
|
||||
message: '请输入CT变比',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
//提交终端信息
|
||||
confirmFormData = {
|
||||
...confirmFormData,
|
||||
lineFilePath: form.value.lineFilePath?.length == 0 ? '' : lineFilePath?.value, //监测点信息
|
||||
mainWiringDiagram: form.value.mainWiringDiagram?.length == 0 ? '' : mainWiringDiagram.value //主接线图
|
||||
}
|
||||
confirmFormData.saveOrCheckflag = '1'
|
||||
if (title.value != '监测点信息') confirmFormData.id = resendId.value
|
||||
addMointorPointFormData(confirmFormData).then(res => {
|
||||
ElMessage({
|
||||
message: '保存成功!',
|
||||
type: 'success'
|
||||
})
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
close()
|
||||
})
|
||||
} else {
|
||||
// 先判断提交终端信息与监测点信息
|
||||
// 提交监测点信息
|
||||
ruleFormRef.value.validate(valid => {
|
||||
@@ -1081,11 +1119,12 @@ const confirmForm = () => {
|
||||
//提交终端信息
|
||||
confirmFormData = {
|
||||
...confirmFormData,
|
||||
lineFilePath: lineFilePath?.value, //监测点信息
|
||||
mainWiringDiagram: mainWiringDiagram.value //主接线图
|
||||
lineFilePath: form.value.lineFilePath?.length == 0 ? null : lineFilePath?.value, //监测点信息
|
||||
mainWiringDiagram: form.value.mainWiringDiagram?.length == 0 ? null : mainWiringDiagram.value //主接线图
|
||||
// pt1: form.value.pt1 / form.value.pt2, //PT变比
|
||||
// ct1: form.value.ct1 / form.value.ct2 //CT变比
|
||||
}
|
||||
confirmFormData.saveOrCheckflag = '2'
|
||||
if (title.value == '监测点信息') {
|
||||
addMointorPointFormData(confirmFormData).then(res => {
|
||||
ElMessage({
|
||||
@@ -1116,6 +1155,7 @@ const confirmForm = () => {
|
||||
return false
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
|
||||
@@ -89,12 +89,14 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -113,11 +115,30 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return !row.processInstanceId
|
||||
},
|
||||
click: row => {
|
||||
flag.value = true
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '编辑',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -590,7 +590,8 @@
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button @click="close()">取消</el-button>
|
||||
<el-button type="primary" @click="confirmForm()">确定</el-button>
|
||||
<el-button type="primary" @click="confirmForm(true)">保存</el-button>
|
||||
<el-button type="primary" @click="confirmForm(false)">提交审批</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -1421,7 +1422,56 @@ const close = async () => {
|
||||
resetForm()
|
||||
}
|
||||
//提交
|
||||
const confirmForm = () => {
|
||||
const confirmForm = async (flag: boolean) => {
|
||||
if (flag) {
|
||||
// 提交终端信息
|
||||
|
||||
//整理上传文件的数据
|
||||
devReportForm.value.reporter = adminInfo.$state.id
|
||||
devReportForm.value.orgId = adminInfo.$state.deptId
|
||||
let confirmFormData = JSON.parse(JSON.stringify(devReportForm.value))
|
||||
//提交终端信息 form.value
|
||||
confirmFormData = {
|
||||
...confirmFormData,
|
||||
acceptanceInspectionReport:
|
||||
form.value.acceptanceInspectionReport.length == 0 ? '' : acceptanceInspectionReport.value, //验收检验报告
|
||||
// acceptanceInspectionReportSingle: acceptanceInspectionReportSingle.value, //验收检验报告单
|
||||
deviceFilePath: form.value.deviceFilePath.length == 0 ? '' : deviceFilePath?.value, //终端台账信息
|
||||
factoryInspectionReport:
|
||||
form.value.factoryInspectionReport.length == 0 ? '' : factoryInspectionReport.value, //出厂检验报告
|
||||
informationSecurityTestReport:
|
||||
form.value.informationSecurityTestReport.length == 0 ? '' : informationSecurityTestReport.value, //信息安全检测报告
|
||||
performanceTestReport: form.value.performanceTestReport.length == 0 ? '' : performanceTestReport.value, //性能检测报告
|
||||
typeExperimentReport: form.value.typeExperimentReport.length == 0 ? '' : typeExperimentReport.value, //型式实验报告
|
||||
otherAttachments: form.value.otherAttachments.length == 0 ? '' : otherAttachments?.value //其他附件
|
||||
}
|
||||
|
||||
confirmFormData.saveOrCheckflag = '1'
|
||||
confirmFormData.reporter = adminInfo.$state.id
|
||||
confirmFormData.orgId = adminInfo.$state.deptId
|
||||
confirmFormData.supervisionTempDeviceReportParam.commissioningTime =
|
||||
confirmFormData?.supervisionTempDeviceReportParam?.commissioningTime?.replace('T', ' ') || ''
|
||||
|
||||
let powerCompanID = powerCompanyList.value.filter(item => item.name == form.value.powerCompany)[0]?.id
|
||||
confirmFormData.supervisionTempDeviceReportParam.terminalIp = form.value.terminalIp
|
||||
confirmFormData.supervisionTempDeviceReportParam.powerCompany = powerCompanID
|
||||
? powerCompanID
|
||||
: form.value.powerCompany
|
||||
|
||||
if (title.value != '终端信息') confirmFormData.id = resendId.value
|
||||
|
||||
await addTerminalFormData(confirmFormData).then((res: any) => {
|
||||
if (res.code == 'A0000') {
|
||||
ElMessage({
|
||||
message: '保存成功!',
|
||||
type: 'success'
|
||||
})
|
||||
ruleFormRef.value.resetFields()
|
||||
resetForm()
|
||||
close()
|
||||
}
|
||||
})
|
||||
} else {
|
||||
// 提交终端信息
|
||||
ruleFormRef.value.validate(valid => {
|
||||
if (valid) {
|
||||
@@ -1432,15 +1482,20 @@ const confirmForm = () => {
|
||||
//提交终端信息
|
||||
confirmFormData = {
|
||||
...confirmFormData,
|
||||
acceptanceInspectionReport: acceptanceInspectionReport.value, //验收检验报告
|
||||
acceptanceInspectionReport:
|
||||
form.value.acceptanceInspectionReport.length == 0 ? '' : acceptanceInspectionReport.value, //验收检验报告
|
||||
// acceptanceInspectionReportSingle: acceptanceInspectionReportSingle.value, //验收检验报告单
|
||||
deviceFilePath: deviceFilePath?.value, //终端台账信息
|
||||
factoryInspectionReport: factoryInspectionReport.value, //出厂检验报告
|
||||
informationSecurityTestReport: informationSecurityTestReport.value, //信息安全检测报告
|
||||
performanceTestReport: performanceTestReport.value, //性能检测报告
|
||||
typeExperimentReport: typeExperimentReport.value, //型式实验报告
|
||||
otherAttachments: otherAttachments?.value //其他附件
|
||||
deviceFilePath: form.value.deviceFilePath.length == 0 ? '' : deviceFilePath?.value, //终端台账信息
|
||||
factoryInspectionReport:
|
||||
form.value.factoryInspectionReport.length == 0 ? '' : factoryInspectionReport.value, //出厂检验报告
|
||||
informationSecurityTestReport:
|
||||
form.value.informationSecurityTestReport.length == 0 ? '' : informationSecurityTestReport.value, //信息安全检测报告
|
||||
performanceTestReport:
|
||||
form.value.performanceTestReport.length == 0 ? '' : performanceTestReport.value, //性能检测报告
|
||||
typeExperimentReport: form.value.typeExperimentReport.length == 0 ? '' : typeExperimentReport.value, //型式实验报告
|
||||
otherAttachments: form.value.otherAttachments.length == 0 ? '' : otherAttachments?.value //其他附件
|
||||
}
|
||||
confirmFormData.saveOrCheckflag = '2'
|
||||
if (title.value == '终端信息') {
|
||||
addTerminalFormData(confirmFormData).then((res: any) => {
|
||||
if (res.code == 'A0000') {
|
||||
@@ -1476,6 +1531,7 @@ const confirmForm = () => {
|
||||
return false
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
defineExpose({ open })
|
||||
</script>
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
<!---终端入网检测-->
|
||||
<template>
|
||||
<TableHeader area datePicker nextFlag ref="TableHeaderRef">
|
||||
<template #select>
|
||||
@@ -96,12 +95,14 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -157,11 +158,30 @@ const tableStore = new TableStore({
|
||||
type: 'primary',
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return !row.processInstanceId
|
||||
},
|
||||
click: row => {
|
||||
flag.value = true
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '编辑',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
|
||||
@@ -56,10 +56,11 @@ import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import { addRunTest } from '@/api/supervision-boot/lineRunTest'
|
||||
import { formatDate } from '@/utils/formatTime'
|
||||
import { VxeTablePropTypes } from 'vxe-table'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
const dictData = useDictData()
|
||||
const statusSelect = dictData.statusSelect()
|
||||
const { push } = useRouter()
|
||||
|
||||
const adminInfo = useAdminInfo()
|
||||
const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
|
||||
@@ -107,12 +108,14 @@ const tableStore = new TableStore({
|
||||
minWidth: 100,
|
||||
render: 'tag',
|
||||
custom: {
|
||||
0: 'warning',
|
||||
1: 'primary',
|
||||
2: 'success',
|
||||
3: 'danger',
|
||||
4: 'warning'
|
||||
},
|
||||
replaceValue: {
|
||||
0: '待提交审批',
|
||||
1: '审批中',
|
||||
2: '审批通过',
|
||||
3: '审批不通过',
|
||||
@@ -145,10 +148,22 @@ const tableStore = new TableStore({
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
},
|
||||
disabled: row => {
|
||||
return row.testRunState != 2
|
||||
return row.testRunState != 2 || !row.processInstanceId
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '编辑',
|
||||
type: 'primary',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.createBy != adminInfo.$state.id || !(row.status == 0)
|
||||
},
|
||||
click: row => {
|
||||
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'productSetting',
|
||||
title: '重新试运行',
|
||||
|
||||
Reference in New Issue
Block a user