业务流程添加重新发起&取消
This commit is contained in:
@@ -45,7 +45,7 @@
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="用户性质:" prop="userType">
|
||||
<el-select v-model="form.userType" placeholder="请选择用户性质" @change="changeUserType()">
|
||||
<el-select :disabled="resendId!=''" v-model="form.userType" placeholder="请选择用户性质" @change="changeUserType()">
|
||||
<el-option
|
||||
v-for="(item, index) in userTypeList"
|
||||
:label="item.label"
|
||||
@@ -927,6 +927,8 @@ const open = async (row: any) => {
|
||||
}
|
||||
form.value.orgId = adminInfo.$state.deptName
|
||||
})
|
||||
}else{
|
||||
resendId.value=''
|
||||
}
|
||||
}
|
||||
// 处理上传文件回显
|
||||
|
||||
@@ -2,10 +2,7 @@
|
||||
<TableHeader ref="TableHeaderRef">
|
||||
<template #select>
|
||||
<el-form-item label="用户名称">
|
||||
<el-input
|
||||
v-model="tableStore.table.params.projectName"
|
||||
placeholder="请输入用户名称"
|
||||
></el-input>
|
||||
<el-input v-model="tableStore.table.params.projectName" placeholder="请输入用户名称"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属地市">
|
||||
<el-select v-model="tableStore.table.params.city" clearable placeholder="请选择所属地市">
|
||||
@@ -43,9 +40,14 @@ import Audit from './audit.vue'
|
||||
import addForm from './addForm.vue'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
import { getLoadTypeUserList } from '@/api/process-boot/interference'
|
||||
import { cancelFormData } from '@/api/supervision-boot/interfere/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import { ElMessageBox } from 'element-plus/es'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
const dictData = useDictData()
|
||||
const { push } = useRouter()
|
||||
|
||||
const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
const areaOptionList = dictData.getBasicData('jibei_area')
|
||||
@@ -141,7 +143,7 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2
|
||||
return row.createBy != adminInfo.$state.id || row.status !=3
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
@@ -157,9 +159,11 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4
|
||||
return row.createBy != adminInfo.$state.id || row.status !=1
|
||||
},
|
||||
click: row => {}
|
||||
click: row => {
|
||||
cancelLeave(row)
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -210,6 +214,27 @@ const exportEvent = () => {
|
||||
})
|
||||
})
|
||||
}
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelFormData(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
tableStore.index()
|
||||
})
|
||||
@@ -252,6 +277,4 @@ const getUserTypeName = (userType: any) => {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
</style>
|
||||
<style scoped lang="scss"></style>
|
||||
|
||||
@@ -362,7 +362,12 @@ import { genFileId, ElMessage } from 'element-plus'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
import { uploadFile } from '@/api/system-boot/file'
|
||||
import { addPlanFormData, getUserByDeptId, getPlanDetailsById,updatePlanFormData } from '@/api/supervision-boot/plan/index'
|
||||
import {
|
||||
addPlanFormData,
|
||||
getUserByDeptId,
|
||||
getPlanDetailsById,
|
||||
updatePlanFormData
|
||||
} from '@/api/supervision-boot/plan/index'
|
||||
import Area from '@/components/form/area/index.vue'
|
||||
const emits = defineEmits(['onSubmit'])
|
||||
const dictData = useDictData()
|
||||
@@ -557,15 +562,17 @@ watch(
|
||||
immediate: true
|
||||
}
|
||||
)
|
||||
const resendId=ref('')
|
||||
const resendId = ref('')
|
||||
const open = (row: any) => {
|
||||
title.value = row.title;
|
||||
dialogFormVisible.value = true;
|
||||
resendId.value=row.row.planId;
|
||||
title.value = row.title
|
||||
dialogFormVisible.value = true
|
||||
if (row.row) {
|
||||
getPlanDetailsById({ id: row.row.planId}).then(res => {
|
||||
resendId.value = row.row.planId
|
||||
getPlanDetailsById({ id: row.row.planId }).then(res => {
|
||||
form.value = res.data
|
||||
})
|
||||
} else {
|
||||
resendId.value = ''
|
||||
}
|
||||
}
|
||||
const close = () => {
|
||||
@@ -667,11 +674,12 @@ const confirmForm = () => {
|
||||
})
|
||||
} else {
|
||||
console.log(confirmFormData)
|
||||
confirmFormData.id=resendId.value;
|
||||
confirmFormData.id = resendId.value
|
||||
confirmFormData.planSupvDate = confirmFormData.planSupvDate.replace('T', ' ')
|
||||
updatePlanFormData(confirmFormData).then(res => {
|
||||
if (res.code == 'A0000') {
|
||||
ElMessage({
|
||||
message: '新建技术监督计划成功',
|
||||
message: '重新发起成功',
|
||||
type: 'success'
|
||||
})
|
||||
ruleFormRef.value.resetFields()
|
||||
|
||||
@@ -46,7 +46,10 @@ import addForm from './components/addForm.vue'
|
||||
import effectProblem from './components/effectProblem/index.vue'
|
||||
import { planDetailsAudit, sendAlarm } from '@/api/supervision-boot/plan/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
import { cancelPlanFormData } from '@/api/supervision-boot/plan/index'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
defineOptions({
|
||||
name: 'plan'
|
||||
})
|
||||
@@ -169,30 +172,12 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
click: row => {
|
||||
console.log(row.processInstanceId,"000000000");
|
||||
handleDetails(row.processInstanceId)
|
||||
handleDetails(row.processInstanceId, row.historyInstanceId)
|
||||
},
|
||||
disabled: row => {
|
||||
return !row.processInstanceId
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
type: 'warning',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '重新发起',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
name: 'productSetting',
|
||||
title: '实施问题',
|
||||
@@ -216,7 +201,24 @@ const tableStore = new TableStore({
|
||||
handleAudit(row)
|
||||
}
|
||||
},
|
||||
|
||||
{
|
||||
name: 'edit',
|
||||
title: '重新发起',
|
||||
type: 'warning',
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return (
|
||||
row.createBy != adminInfo.$state.id || row.status !=3
|
||||
)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
title: '重新发起',
|
||||
row: row
|
||||
})
|
||||
}
|
||||
},
|
||||
{
|
||||
name: 'cancel',
|
||||
title: '取消',
|
||||
@@ -224,10 +226,12 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4
|
||||
return (
|
||||
row.createBy != adminInfo.$state.id || row.status != 1
|
||||
)
|
||||
},
|
||||
click: row => {
|
||||
// cancelLeave(row)
|
||||
cancelLeave(row)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -299,17 +303,19 @@ onMounted(() => {
|
||||
tableStore.index()
|
||||
})
|
||||
//
|
||||
const handleDetails = (id: any) => {
|
||||
const handleDetails = (id: any, historyInstanceId: any) => {
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
id: id
|
||||
state: {
|
||||
id: id,
|
||||
historyInstanceId
|
||||
}
|
||||
})
|
||||
}
|
||||
/** 提交审核按钮 */
|
||||
const handleAudit = (row: any) => {
|
||||
planDetailsAudit({ id: row.planId }).then(res => {
|
||||
ElMessage.success('提交审核成功!')
|
||||
tableStore.index()
|
||||
})
|
||||
}
|
||||
@@ -320,6 +326,26 @@ const handleAlarmForm = (row: any) => {
|
||||
tableStore.index()
|
||||
})
|
||||
}
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelPlanFormData(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
// 实施问题按钮
|
||||
const effectProblemList = ref()
|
||||
const effectProblemForm: any = ref({})
|
||||
@@ -333,5 +359,4 @@ const handleEffectProblem = (row: any) => {
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
@@ -1,21 +1,17 @@
|
||||
<template>
|
||||
<TableHeader datePicker ref='TableHeaderRef'>
|
||||
|
||||
<TableHeader datePicker ref="TableHeaderRef">
|
||||
<template #operation>
|
||||
|
||||
<!-- <el-button icon="el-icon-Plus" type="primary" @click="add">新增</el-button>-->
|
||||
<!-- <el-button icon="el-icon-Delete" type="primary">删除</el-button>-->
|
||||
<!-- <el-button icon="el-icon-Download" type="primary">导出</el-button>-->
|
||||
|
||||
</template>
|
||||
</TableHeader>
|
||||
<!--表格-->
|
||||
<Table ref='tableRef' />
|
||||
<Table ref="tableRef" />
|
||||
<!--弹框-->
|
||||
<feedback-popup ref='feedbackPopup' />
|
||||
|
||||
<feedback-popup ref="feedbackPopup" />
|
||||
</template>
|
||||
<script setup lang='ts'>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, provide, nextTick } from 'vue'
|
||||
import TableStore from '@/utils/tableStore'
|
||||
import Table from '@/components/table/index.vue'
|
||||
@@ -23,7 +19,10 @@ import TableHeader from '@/components/table/header/index.vue'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import FeedbackPopup from '@/views/pqs/supervise/technology/feedbackPopup.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
import { cancelFeedback } from '@/api/supervision-boot/leaflet'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
const { push } = useRouter()
|
||||
|
||||
const feedbackPopup = ref()
|
||||
@@ -44,7 +43,9 @@ const tableStore = new TableStore({
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'problemType', title: '告警单问题来源', minWidth: '150',
|
||||
field: 'problemType',
|
||||
title: '告警单问题来源',
|
||||
minWidth: '150',
|
||||
render: 'tag',
|
||||
custom: {
|
||||
1: 'warning',
|
||||
@@ -61,7 +62,9 @@ const tableStore = new TableStore({
|
||||
},
|
||||
{ field: 'leafletName', title: '单据名称', minWidth: '150' },
|
||||
{
|
||||
field: 'status', title: '告警单状态', minWidth: '150',
|
||||
field: 'status',
|
||||
title: '告警单状态',
|
||||
minWidth: '150',
|
||||
render: 'tag',
|
||||
custom: {
|
||||
1: 'primary',
|
||||
@@ -107,7 +110,7 @@ const tableStore = new TableStore({
|
||||
return row.status !== 5
|
||||
},
|
||||
click: row => {
|
||||
feedbackPopup.value.open('填报反馈单', row.id, row.status, row.issueDetail,row.problemPath)
|
||||
feedbackPopup.value.open('填报反馈单', row.id, row.status, row.issueDetail, row.problemPath)
|
||||
}
|
||||
},
|
||||
|
||||
@@ -121,7 +124,7 @@ const tableStore = new TableStore({
|
||||
return row.status == 5
|
||||
},
|
||||
click: row => {
|
||||
handleAudit(row.processInstanceId)
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -131,10 +134,19 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2 || row.status == 4 || row.status == 5
|
||||
return row.createBy != adminInfo.$state.id || row.status != 3
|
||||
},
|
||||
click: row => {
|
||||
// deviceQuitPopup.value.open('重新发起', row)
|
||||
feedbackPopup.value.open(
|
||||
'重新发起告警单',
|
||||
row.id,
|
||||
row.status,
|
||||
row.issueDetail,
|
||||
row.problemPath,
|
||||
row.takeStep,
|
||||
row.reportPath
|
||||
)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -144,13 +156,12 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4 || row.status == 5
|
||||
return row.createBy != adminInfo.$state.id || row.status != 1
|
||||
},
|
||||
click: row => {
|
||||
// cancelLeave(row)
|
||||
cancelLeave(row)
|
||||
}
|
||||
}
|
||||
|
||||
]
|
||||
}
|
||||
],
|
||||
@@ -160,24 +171,44 @@ const tableStore = new TableStore({
|
||||
}
|
||||
})
|
||||
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelFeedback(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
tableStore.table.params.status = ''
|
||||
|
||||
provide('tableStore', tableStore)
|
||||
|
||||
|
||||
onMounted(() => {
|
||||
tableStore.index()
|
||||
})
|
||||
|
||||
/** 流程实例详情 */
|
||||
const handleAudit = (instanceId: any) => {
|
||||
const handleAudit = (instanceId: any, historyInstanceId: any) => {
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
id: instanceId
|
||||
state: {
|
||||
id: instanceId,
|
||||
historyInstanceId
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang='scss'></style>
|
||||
<style scoped lang="scss"></style>
|
||||
|
||||
@@ -17,7 +17,10 @@ import TableHeader from '@/components/table/header/index.vue'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import FeedbackPopup from '@/views/pqs/supervise/technology/feedbackPopup.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
import { cancelFeedback } from '@/api/supervision-boot/leaflet'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
const { push } = useRouter()
|
||||
const tableRef = ref()
|
||||
const TableHeaderRef = ref()
|
||||
@@ -113,7 +116,7 @@ const tableStore = new TableStore({
|
||||
return row.status == 5
|
||||
},
|
||||
click: row => {
|
||||
handleAudit(row.processInstanceId)
|
||||
handleAudit(row.processInstanceId,row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -123,10 +126,11 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2 || row.status == 4 || row.status == 5
|
||||
return row.createBy != adminInfo.$state.id || row.status != 3
|
||||
},
|
||||
click: row => {
|
||||
// deviceQuitPopup.value.open('重新发起', row)
|
||||
feedbackPopup.value.open('重新发起预警单', row.id, row.status, row.issueDetail,row.problemPath,row.takeStep,row.reportPath)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -136,10 +140,10 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4 || row.status == 5
|
||||
return row.createBy != adminInfo.$state.id || row.status != 1
|
||||
},
|
||||
click: row => {
|
||||
// cancelLeave(row)
|
||||
cancelLeave(row)
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -156,13 +160,33 @@ provide('tableStore', tableStore)
|
||||
onMounted(() => {
|
||||
tableStore.index()
|
||||
})
|
||||
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelFeedback(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
/** 流程实例详情 */
|
||||
const handleAudit = (instanceId: any) => {
|
||||
const handleAudit = (instanceId: any,historyInstanceId:any) => {
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
id: instanceId
|
||||
id: instanceId,
|
||||
historyInstanceId
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1,77 +1,70 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
draggable
|
||||
class='cn-operate-dialog'
|
||||
v-model='dialogVisible'
|
||||
:title='title'
|
||||
width='450px'
|
||||
top='30vh'
|
||||
>
|
||||
<el-dialog draggable class="cn-operate-dialog" v-model="dialogVisible" :title="title" width="450px" top="30vh">
|
||||
<el-scrollbar>
|
||||
<el-form :inline='false' :model='formData' label-width='120px' :rules='rules' ref='formRef'>
|
||||
|
||||
<el-form-item label='问题详情:'>
|
||||
<el-form :inline="false" :model="form" label-width="120px" :rules="rules" ref="formRef">
|
||||
<el-form-item label="问题详情:">
|
||||
<el-input
|
||||
v-model='formData.issueDetail'
|
||||
autocomplete='off'
|
||||
type='textarea'
|
||||
:autosize='{minRows:2,maxRows:6}'
|
||||
v-model="form.issueDetail"
|
||||
autocomplete="off"
|
||||
type="textarea"
|
||||
:autosize="{ minRows: 2, maxRows: 6 }"
|
||||
readonly
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label='问题附件:' v-if='showFile'>
|
||||
<el-form-item label="问题附件:" v-if="showFile">
|
||||
<el-icon>
|
||||
<Link />
|
||||
</el-icon>
|
||||
<a :href='problemDetail.problemPath' target='_blank'>{{ problemDetail.problemName }}</a>
|
||||
<a :href="problemDetail.problemPath" target="_blank">{{ problemDetail.problemName }}</a>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label='采取的措施:' prop='takeStep'>
|
||||
<el-form-item label="采取的措施:" prop="takeStep">
|
||||
<el-input
|
||||
v-model='formData.takeStep'
|
||||
autocomplete='off'
|
||||
placeholder='请输入采取的措施'
|
||||
type='textarea'
|
||||
v-model="form.takeStep"
|
||||
autocomplete="off"
|
||||
placeholder="请输入采取的措施"
|
||||
type="textarea"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label='反馈报告:' prop='reportPath'>
|
||||
<el-form-item label="反馈报告:" class="uploadFile" prop="reportPath">
|
||||
<el-upload
|
||||
ref='uploadRef'
|
||||
action=''
|
||||
accept='.doc,.docx,.xlsx,.xls,.pdf'
|
||||
:limit='1'
|
||||
:on-exceed='handleExceed'
|
||||
:on-change='choose'
|
||||
:auto-upload='false'
|
||||
v-model:file-list="form.reportPath"
|
||||
ref="uploadRef"
|
||||
action=""
|
||||
:accept="acceptType"
|
||||
:limit="1"
|
||||
:on-exceed="handleExceed"
|
||||
:on-change="choose"
|
||||
:auto-upload="false"
|
||||
:on-progress="uploadFileName('reportPath')"
|
||||
:on-remove="removeFile"
|
||||
>
|
||||
<template #trigger>
|
||||
<el-button type='primary'>上传文件</el-button>
|
||||
<el-button type="primary">上传文件</el-button>
|
||||
</template>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
</el-scrollbar>
|
||||
|
||||
<template #footer>
|
||||
<span class='dialog-footer'>
|
||||
<el-button @click='dialogVisible = false'>取消</el-button>
|
||||
<el-button type='primary' @click='submit'>确认</el-button>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="close">取消</el-button>
|
||||
<el-button type="primary" @click="submit">确认</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script lang='ts' setup>
|
||||
<script lang="ts" setup>
|
||||
import { ref, inject, reactive, nextTick } from 'vue'
|
||||
import { ElMessage, genFileId, UploadProps, UploadRawFile } from 'element-plus'
|
||||
import TableStore from '@/utils/tableStore' // 若不是列表页面弹框可删除
|
||||
import { getFileNameAndFilePath, uploadFile } from '@/api/system-boot/file'
|
||||
import { addFeedback } from '@/api/supervision-boot/leaflet'
|
||||
import { addFeedback, updateFeedback } from '@/api/supervision-boot/leaflet'
|
||||
import { Link } from '@element-plus/icons-vue'
|
||||
|
||||
//.doc,.docx,.xlsx,.xls,.pdf
|
||||
const acceptType = ref('')
|
||||
//下拉数据源
|
||||
const title = ref('')
|
||||
const tableStore = inject('tableStore') as TableStore
|
||||
@@ -80,12 +73,12 @@ const formRef = ref()
|
||||
const uploadRef = ref()
|
||||
const dialogVisible = ref(false)
|
||||
// 注意不要和表单ref的命名冲突
|
||||
const formData = reactive({
|
||||
const form = ref({
|
||||
id: '',
|
||||
status: '',
|
||||
issueDetail: '',
|
||||
takeStep: '',
|
||||
reportPath: ''
|
||||
reportPath: []
|
||||
})
|
||||
//附件是否显示
|
||||
const showFile = ref(false)
|
||||
@@ -96,11 +89,12 @@ const problemDetail = reactive({
|
||||
})
|
||||
|
||||
//处理成效报告
|
||||
const reportPath = ref('')
|
||||
const reportFilePath: any = ref('')
|
||||
|
||||
//form表单校验规则
|
||||
const rules = {
|
||||
takeStep: [{ required: true, message: '请输入采取的措施', trigger: 'blur' }]
|
||||
takeStep: [{ required: true, message: '请输入采取的措施', trigger: 'blur' }],
|
||||
reportPath: [{ required: true, message: '请上传处理成效报告', trigger: 'blur' }]
|
||||
}
|
||||
const resetForm = () => {
|
||||
if (formRef.value) {
|
||||
@@ -108,19 +102,35 @@ const resetForm = () => {
|
||||
}
|
||||
}
|
||||
|
||||
const open = async (text: string, id: string, status: any, issueDetail: string, problemPath?: string, takeStep?: string, reportPath?: string) => {
|
||||
const open = async (
|
||||
text: string,
|
||||
id: string,
|
||||
status: any,
|
||||
issueDetail: string,
|
||||
problemPath?: string,
|
||||
takeStep?: string,
|
||||
reportPath?: string
|
||||
) => {
|
||||
title.value = text
|
||||
resetForm()
|
||||
console.log(66666,reportPath);
|
||||
if (takeStep) {
|
||||
formData.takeStep = takeStep
|
||||
form.value.takeStep = takeStep
|
||||
}
|
||||
uploadRef.value?.clearFiles()
|
||||
// uploadRef.value?.clearFiles()
|
||||
if (reportPath) {
|
||||
formData.reportPath = reportPath
|
||||
form.value.reportPath = JSON.parse(
|
||||
JSON.stringify([
|
||||
{
|
||||
name: reportPath?.split('/')[2]
|
||||
}
|
||||
])
|
||||
)
|
||||
}
|
||||
formData.id = id
|
||||
formData.status = status
|
||||
formData.issueDetail = issueDetail
|
||||
form.value.id = id
|
||||
form.value.status = status
|
||||
form.value.issueDetail = issueDetail
|
||||
reportFilePath.value = reportPath
|
||||
//判断附件是否存在,如果存在则回显出让用户可以点击下载
|
||||
if (problemPath) {
|
||||
let arrPath = problemPath.split(',')
|
||||
@@ -129,33 +139,52 @@ const open = async (text: string, id: string, status: any, issueDetail: string,
|
||||
problemDetail.problemName = res.data.fileName
|
||||
})
|
||||
showFile.value = true
|
||||
}else{
|
||||
} else {
|
||||
showFile.value = false
|
||||
}
|
||||
|
||||
dialogVisible.value = true
|
||||
}
|
||||
|
||||
//移除文件上传
|
||||
const removeFile = (file: any, uploadFiles: any) => {
|
||||
console.log(file, uploadFiles)
|
||||
}
|
||||
const close = () => {
|
||||
dialogVisible.value = false
|
||||
form.value = {
|
||||
id: '',
|
||||
status: '',
|
||||
issueDetail: '',
|
||||
takeStep: '',
|
||||
reportPath: []
|
||||
}
|
||||
resetForm()
|
||||
}
|
||||
/**
|
||||
* 提交用户表单数据
|
||||
*/
|
||||
const submit = () => {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
if (!reportPath.value) {
|
||||
let subForm = JSON.parse(JSON.stringify(form.value))
|
||||
subForm = {
|
||||
...subForm,
|
||||
reportPath: reportFilePath.value
|
||||
}
|
||||
if (!reportFilePath.value) {
|
||||
return ElMessage({
|
||||
message: '请上传处理成效报告',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
if (formData.status == '3') {
|
||||
// await quitRunningDeviceUpdate(formData)
|
||||
if (form.value.status == '3') {
|
||||
await updateFeedback(subForm)
|
||||
ElMessage.success('重新发起成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
} else {
|
||||
//此时该告警单处于待反馈状态
|
||||
await addFeedback(formData)
|
||||
await addFeedback(subForm)
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
@@ -167,16 +196,14 @@ const submit = () => {
|
||||
|
||||
defineExpose({ open })
|
||||
|
||||
|
||||
let uploadName = ref('')
|
||||
const choose = (e: any) => {
|
||||
uploadFile(e.raw, '/supervision/').then(res => {
|
||||
reportPath.value = res.data.name
|
||||
formData.reportPath = res.data.name
|
||||
reportFilePath.value = res.data.name
|
||||
form.value.reportPath = res.data.name
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
const handleExceed: UploadProps['onExceed'] = files => {
|
||||
uploadRef.value!.clearFiles()
|
||||
const file = files[0] as UploadRawFile
|
||||
@@ -190,7 +217,7 @@ const uploadFileName = val => {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang='scss'>
|
||||
<style scoped lang="scss">
|
||||
.el-upload-list__item {
|
||||
transition: none !important;
|
||||
}
|
||||
@@ -198,6 +225,4 @@ const uploadFileName = val => {
|
||||
.el-select {
|
||||
min-width: 180px;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
|
||||
@@ -7,7 +7,9 @@
|
||||
<el-tab-pane label="预警单列表" name="3">
|
||||
<earlyWarn v-if="activeName == '3'" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="告警单列表" name="4"><alarm v-if="activeName == '4'" /></el-tab-pane>
|
||||
<el-tab-pane label="告警单列表" name="4">
|
||||
<alarm v-if="activeName == '4'" />
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -38,7 +38,12 @@ import { setTempLinedebugLedgerSync } from '@/api/supervision-boot/jointDebugLis
|
||||
import debug from './debug.vue'
|
||||
import { any } from 'vue-types'
|
||||
const dictData = useDictData()
|
||||
const { push } = useRouter()
|
||||
const { push, beforeEach } = useRouter()
|
||||
beforeEach((to, from) => {
|
||||
if (from.path == '/bpm/instanceDetail') {
|
||||
console.log('联调333')
|
||||
}
|
||||
})
|
||||
const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
const areaOptionList = dictData.getBasicData('jibei_area')
|
||||
|
||||
@@ -161,33 +161,33 @@
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="PT变比:" prop="ptRatio">
|
||||
<el-form-item for="-" label="PT变比:" prop="pt1">
|
||||
<el-input
|
||||
style="width: 48%"
|
||||
v-model="form.ptRatio"
|
||||
v-model="form.pt1"
|
||||
autocomplete="off"
|
||||
placeholder="请输入PT变比"
|
||||
oninput="value=value.replace(/[^0-9.]/g,'')"
|
||||
/>
|
||||
<el-input
|
||||
style="width: 48%"
|
||||
v-model="form.ptRatio2"
|
||||
v-model="form.pt2"
|
||||
autocomplete="off"
|
||||
placeholder="请输入PT变比"
|
||||
oninput="value=value.replace(/[^0-9.]/g,'')"
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item for="-" label="CT变比:" prop="ctRatio">
|
||||
<el-form-item for="-" label="CT变比:" prop="ct1">
|
||||
<el-input
|
||||
v-model="form.ctRatio"
|
||||
v-model="form.ct1"
|
||||
style="width: 48%"
|
||||
autocomplete="off"
|
||||
oninput="value=value.replace(/[^0-9.]/g,'')"
|
||||
placeholder="请输入CT变比"
|
||||
/>
|
||||
<el-input
|
||||
v-model="form.ctRatio2"
|
||||
v-model="form.ct2"
|
||||
style="width: 48%"
|
||||
autocomplete="off"
|
||||
oninput="value=value.replace(/[^0-9.]/g,'')"
|
||||
@@ -304,8 +304,8 @@
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="是否参与统计:" prop="isStatistical">
|
||||
<el-radio-group v-model="form.isStatistical">
|
||||
<el-radio value="1">是</el-radio>
|
||||
<el-radio value="0">否</el-radio>
|
||||
<el-radio :value="1">是</el-radio>
|
||||
<el-radio :value="0">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item for="-" label="对象名称(对端):" prop="objName">
|
||||
@@ -316,8 +316,8 @@
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="是否并网点:" prop="isGridConnectionPoint">
|
||||
<el-radio-group v-model="form.isGridConnectionPoint">
|
||||
<el-radio value="1">是</el-radio>
|
||||
<el-radio value="0">否</el-radio>
|
||||
<el-radio :value="1">是</el-radio>
|
||||
<el-radio :value="0">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item for="-" label="主接线图:" prop="mainWiringDiagram" class="uploadFile">
|
||||
@@ -427,15 +427,15 @@ const operationStatusList = [
|
||||
//定义接线方式下拉框数据
|
||||
const ptTypeList = [
|
||||
{
|
||||
id: '0',
|
||||
id: 0,
|
||||
name: '星型接法'
|
||||
},
|
||||
{
|
||||
id: '1',
|
||||
id: 1,
|
||||
name: '三角型接法'
|
||||
},
|
||||
{
|
||||
id: '2',
|
||||
id: 2,
|
||||
name: '开口三角型接法'
|
||||
}
|
||||
]
|
||||
@@ -527,16 +527,16 @@ const resetForm = () => {
|
||||
//监测点信息实体
|
||||
businessType: '', // 干扰源类别
|
||||
connectedBus: '', // 接入母线
|
||||
ctRatio: '300', //CT变比
|
||||
ctRatio2: '5', //CT变比2
|
||||
ptRatio: 1, // PT变比
|
||||
ptRatio2: 1, // PT变比2
|
||||
ct1: 300, //CT变比1
|
||||
ct2: 5, //CT变比2
|
||||
pt1: 1, // PT变比1
|
||||
pt2: 1, // PT变比2
|
||||
shortCapacity: '10', // 短路容量
|
||||
dealCapacity: '10', //协议容量
|
||||
devCapacity: '10', //设备容量
|
||||
standardCapacity: '10', //基准容量
|
||||
isGridConnectionPoint: '0', //是否并网点
|
||||
isStatistical: '0', // 是否参与统计
|
||||
isGridConnectionPoint: 0, //是否并网点
|
||||
isStatistical: 0, // 是否参与统计
|
||||
lineId: '', // 监测点编码
|
||||
lineName: '', // 监测点名称
|
||||
loadType: '', //干扰源类型
|
||||
@@ -558,18 +558,22 @@ const resetForm = () => {
|
||||
userNameList.value = res.data
|
||||
//初始化
|
||||
let obj = res.data[0]
|
||||
form.value = {
|
||||
...form.value,
|
||||
city: obj.city,
|
||||
reporter: obj.reporter,
|
||||
reporterName: obj.reporterName,
|
||||
reportDate: obj.reportDate,
|
||||
orgId: obj.orgId,
|
||||
orgName: obj.orgName,
|
||||
expectedProductionDate: obj.expectedProductionDate,
|
||||
userName: userNameList.value[0]?.projectName,
|
||||
userId: userNameList.value[0]?.id,
|
||||
objName: userNameList.value[0]?.projectName
|
||||
|
||||
console.log(obj,"99999999");
|
||||
if (title.value != '重新发起') {
|
||||
form.value = {
|
||||
...form.value,
|
||||
city: obj.city,
|
||||
reporter: obj.reporter,
|
||||
reporterName: obj.reporterName,
|
||||
reportDate: obj.reportDate,
|
||||
orgId: obj.orgId,
|
||||
orgName: obj.orgName,
|
||||
expectedProductionDate: obj.expectedProductionDate,
|
||||
userName: userNameList.value[0]?.projectName,
|
||||
userId: userNameList.value[0]?.id,
|
||||
objName: userNameList.value[0]?.projectName
|
||||
}
|
||||
}
|
||||
})
|
||||
changevoltageDeviationLimit()
|
||||
@@ -594,12 +598,12 @@ const changevoltageDeviationLimit = async () => {
|
||||
}
|
||||
//PT变比 电压<0.48kv 1:1 电压>0.48 *1000/100
|
||||
if (Number(val) <= 0.48) {
|
||||
form.value.ptRatio = 1
|
||||
form.value.ptRatio2 = 1
|
||||
form.value.pt1 = 1
|
||||
form.value.pt2 = 1
|
||||
}
|
||||
if (Number(val) > 0.48) {
|
||||
form.value.ptRatio = val * 10
|
||||
form.value.ptRatio2 = 1
|
||||
form.value.pt1 = val * 10
|
||||
form.value.pt2 = 1
|
||||
}
|
||||
}
|
||||
findAllMonitoringTerminalList()
|
||||
@@ -637,6 +641,8 @@ const changeUserName = () => {
|
||||
let obj: any = projectList.value.find((item: any) => {
|
||||
return form.value.userName == item.id
|
||||
})
|
||||
// console.log(userNameList.value,11111,projectList.value);
|
||||
console.log(obj,"88888888");
|
||||
form.value = {
|
||||
...form.value,
|
||||
city: obj?.city,
|
||||
@@ -761,14 +767,14 @@ const rules = ref({
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
ctRatio: [
|
||||
ct1: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入CT变化',
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
ptRatio: [
|
||||
pt1: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入PT变化',
|
||||
@@ -867,37 +873,35 @@ const rules = ref({
|
||||
}
|
||||
]
|
||||
})
|
||||
watch(
|
||||
() => form.value,
|
||||
(val, oldVal) => {},
|
||||
{
|
||||
deep: true,
|
||||
immediate: true
|
||||
}
|
||||
)
|
||||
const resendId = ref('')
|
||||
const rowValue:any=ref({})
|
||||
const open = (row: any) => {
|
||||
dialogFormVisible.value = true
|
||||
title.value = row.title
|
||||
//初始化数据
|
||||
resetForm()
|
||||
title.value = row.title
|
||||
nextTick(() => {
|
||||
if (row.row) {
|
||||
resendId.value = row.row.id
|
||||
getTempLineDetailsById({ id: row.row.id }).then(res => {
|
||||
form.value = res.data
|
||||
form.value.loadType = loadTypeList.value.filter((item: any) => item.name == res.data.loadType)[0]?.id
|
||||
form.value.businessType = businessTypeList.value.filter(
|
||||
(item: any) => item.name == res.data.businessType
|
||||
)[0]?.id
|
||||
form.value.mainWiringDiagram = [
|
||||
if (row.row) {
|
||||
resendId.value = row.row.id
|
||||
rowValue.value=row.row
|
||||
getTempLineDetailsById({ id: row.row.id }).then(res => {
|
||||
form.value = res.data
|
||||
form.value.loadType = loadTypeList.value.filter((item: any) => item.name == res.data.loadType)[0]?.id
|
||||
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(
|
||||
JSON.stringify([
|
||||
{
|
||||
name: res.data.mainWiringDiagram.split('/')[2]
|
||||
}
|
||||
]
|
||||
mainWiringDiagram.value = res.data.mainWiringDiagram
|
||||
})
|
||||
}
|
||||
])
|
||||
)
|
||||
})
|
||||
} else {
|
||||
resendId.value = ''
|
||||
}
|
||||
})
|
||||
}
|
||||
const close = () => {
|
||||
@@ -911,6 +915,27 @@ const close = () => {
|
||||
onMounted(() => {
|
||||
console.log()
|
||||
})
|
||||
|
||||
watch(
|
||||
() => projectList.value,
|
||||
(val, oldVal) => {
|
||||
if(val&&val.length!=0&&resendId.value){
|
||||
let obj: any = projectList.value.find((item: any) => {
|
||||
return rowValue.value.createBy == item.createBy
|
||||
})
|
||||
console.log(projectList.value, '000000', obj, rowValue.value.createBy)
|
||||
form.value = {
|
||||
...form.value,
|
||||
reporter: obj?.reporter,
|
||||
reporterName: obj?.reporterName
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
deep: true,
|
||||
immediate: true
|
||||
}
|
||||
)
|
||||
// 上传报告
|
||||
const uploadRef = ref()
|
||||
const handleExceed: UploadProps['onExceed'] = files => {
|
||||
@@ -959,9 +984,15 @@ const confirmForm = () => {
|
||||
//处理填报日期时间格式
|
||||
form.value.reportDate = window.XEUtils.toDateString(form.value.reportDate, 'yyyy-MM-dd')
|
||||
let confirmFormData = JSON.parse(JSON.stringify(form.value))
|
||||
if (!mainWiringDiagram.value) {
|
||||
if (!form.value.pt1 || !form.value.pt2) {
|
||||
return ElMessage({
|
||||
message: '请上传主接线图',
|
||||
message: '请输入PT变比',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
if (!form.value.ct1 || !form.value.ct2) {
|
||||
return ElMessage({
|
||||
message: '请输入CT变比',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
@@ -969,9 +1000,9 @@ const confirmForm = () => {
|
||||
confirmFormData = {
|
||||
...confirmFormData,
|
||||
lineFilePath: lineFilePath?.value, //监测点信息
|
||||
mainWiringDiagram: mainWiringDiagram.value, //主接线图
|
||||
ptRatio: form.value.ptRatio / form.value.ptRatio2, //PT变比
|
||||
ctRatio: form.value.ctRatio / form.value.ctRatio2 //CT变比
|
||||
mainWiringDiagram: mainWiringDiagram.value //主接线图
|
||||
// pt1: form.value.pt1 / form.value.pt2, //PT变比
|
||||
// ct1: form.value.ct1 / form.value.ct2 //CT变比
|
||||
}
|
||||
if (title.value == '监测点信息') {
|
||||
addMointorPointFormData(confirmFormData).then(res => {
|
||||
@@ -985,6 +1016,7 @@ const confirmForm = () => {
|
||||
})
|
||||
} else {
|
||||
confirmFormData.id = resendId.value
|
||||
console.log(confirmFormData, '99999999999')
|
||||
updateMointorPointFormData(confirmFormData).then(res => {
|
||||
if (res.code == 'A0000') {
|
||||
ElMessage({
|
||||
|
||||
@@ -62,10 +62,10 @@
|
||||
{{ detailData.standardCapacity }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="CT变比">
|
||||
{{ detailData.ctRatio }}
|
||||
{{ detailData.ct1 }}{{ detailData.ct2?'/'+detailData.ct2:'' }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="PT变比">
|
||||
{{ detailData.ptRatio }}
|
||||
{{ detailData.pt1 }}{{ detailData.pt2?'/'+detailData.pt2:'' }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="监测点编码">
|
||||
{{ detailData.lineId }}
|
||||
|
||||
@@ -35,8 +35,21 @@ import { useRouter } from 'vue-router'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
import { getLoadTypeUserList } from '@/api/process-boot/interference'
|
||||
import addForm from './addForm.vue'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import { ElMessageBox } from 'element-plus/es'
|
||||
import { cancelMointorPointFormData } from '@/api/supervision-boot/monitorpoint/index'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
const dictData = useDictData()
|
||||
const { push } = useRouter()
|
||||
const { push, beforeEach } = useRouter()
|
||||
beforeEach((to, from) => {
|
||||
if (from.path == '/bpm/instanceDetail') {
|
||||
if (to.path == '/admin/terminalNetwotk') {
|
||||
console.log('监测点2222')
|
||||
}
|
||||
}
|
||||
})
|
||||
const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
const areaOptionList = dictData.getBasicData('jibei_area')
|
||||
@@ -94,7 +107,7 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-EditPen',
|
||||
render: 'basicButton',
|
||||
click: row => {
|
||||
handleAudit(row.processInstanceId,row.historyInstanceId)
|
||||
handleAudit(row.processInstanceId, row.historyInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -104,7 +117,9 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2
|
||||
return (
|
||||
row.createBy != adminInfo.$state.id || row.status !=3
|
||||
)
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
@@ -120,10 +135,10 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4
|
||||
return row.createBy != adminInfo.$state.id || row.status !=1
|
||||
},
|
||||
click: row => {
|
||||
// cancelLeave(row)
|
||||
cancelLeave(row)
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -150,7 +165,26 @@ const addFormModel = () => {
|
||||
})
|
||||
}, 0)
|
||||
}
|
||||
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelMointorPointFormData(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
const exportEvent = () => {
|
||||
let form = JSON.parse(JSON.stringify(tableStore.table.params))
|
||||
form.pageNum = 1
|
||||
@@ -173,16 +207,15 @@ onMounted(() => {
|
||||
})
|
||||
|
||||
/** 处理审批按钮 */
|
||||
const handleAudit = (instanceId: any,historyInstanceId:any) => {
|
||||
const handleAudit = (instanceId: any, historyInstanceId: any) => {
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
state: {
|
||||
id: instanceId,
|
||||
historyInstanceId
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
@@ -727,7 +727,6 @@ const getFrontEndMachineList = () => {
|
||||
})
|
||||
}
|
||||
const changeSubstationFlag = () => {
|
||||
console.log(form.value.customSubstaionFlag)
|
||||
//处理所属变电站手都输入/下拉数据
|
||||
if (form.value.customSubstaionFlag == '0') {
|
||||
form.value.substationName = substationList.value.find((item: any) => {
|
||||
@@ -1378,6 +1377,8 @@ const open = async (row: any) => {
|
||||
performanceTestReport.value = res.data.performanceTestReport
|
||||
informationSecurityTestReport.value = res.data.informationSecurityTestReport
|
||||
otherAttachments.value = res.data.otherAttachments
|
||||
form.value.reporter = adminInfo.$state.name
|
||||
form.value.orgId = adminInfo.$state.deptName
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -1423,10 +1424,11 @@ const confirmForm = () => {
|
||||
}
|
||||
})
|
||||
} else {
|
||||
confirmFormData.reporter = adminInfo.$state.id
|
||||
confirmFormData.orgId = adminInfo.$state.deptId
|
||||
console.log(confirmFormData)
|
||||
form.value.orgId = adminInfo.$state.deptName
|
||||
confirmFormData.supervisionTempDeviceReportParam.commissioningTime =
|
||||
confirmFormData.supervisionTempDeviceReportParam.commissioningTime.replace('T', ' ')
|
||||
confirmFormData.supervisionTempDeviceReportParam.commissioningTime.replace('T', ' ')
|
||||
confirmFormData.id = resendId.value
|
||||
updateTerminalFormData(confirmFormData).then((res: any) => {
|
||||
if (res.code == 'A0000') {
|
||||
|
||||
@@ -19,9 +19,22 @@ import TableHeader from '@/components/table/header/index.vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useDictData } from '@/stores/dictData'
|
||||
import { getLoadTypeUserList } from '@/api/process-boot/interference'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import { ElMessageBox } from 'element-plus/es'
|
||||
import { cancelTerminalFormData } from '@/api/supervision-boot/terminal/index'
|
||||
import addForm from './addForm.vue'
|
||||
import { useAdminInfo } from '@/stores/adminInfo'
|
||||
//获取登陆用户姓名和部门
|
||||
const adminInfo = useAdminInfo()
|
||||
const dictData = useDictData()
|
||||
const { push } = useRouter()
|
||||
const { push, beforeEach } = useRouter()
|
||||
beforeEach((to, from) => {
|
||||
if (from.path == '/bpm/instanceDetail') {
|
||||
if (to.path == '/admin/terminalNetwotk') {
|
||||
console.log('终端1111')
|
||||
}
|
||||
}
|
||||
})
|
||||
const TableHeaderRef = ref()
|
||||
const tableRef = ref()
|
||||
const areaOptionList = dictData.getBasicData('jibei_area')
|
||||
@@ -134,7 +147,7 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 1 || row.status == 2
|
||||
return row.createBy != adminInfo.$state.id || row.status != 3
|
||||
},
|
||||
click: row => {
|
||||
addForms.value.open({
|
||||
@@ -150,10 +163,10 @@ const tableStore = new TableStore({
|
||||
icon: 'el-icon-Open',
|
||||
render: 'basicButton',
|
||||
disabled: row => {
|
||||
return row.status == 3 || row.status == 2 || row.status == 4
|
||||
return row.createBy != adminInfo.$state.id || row.status != 1
|
||||
},
|
||||
click: row => {
|
||||
// cancelLeave(row)
|
||||
cancelLeave(row)
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -179,7 +192,26 @@ const addFormModel = () => {
|
||||
})
|
||||
}, 0)
|
||||
}
|
||||
|
||||
/**取消流程操作*/
|
||||
const cancelLeave = async (row: any) => {
|
||||
// 二次确认
|
||||
const { value } = await ElMessageBox.prompt('请输入取消原因', '取消流程', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格
|
||||
inputErrorMessage: '取消原因不能为空'
|
||||
})
|
||||
// 发起取消
|
||||
let data = {
|
||||
id: row.id,
|
||||
processInstanceId: row.processInstanceId,
|
||||
reason: value
|
||||
}
|
||||
await cancelTerminalFormData(data)
|
||||
ElMessage.success('取消成功')
|
||||
// 加载数据
|
||||
tableStore.index()
|
||||
}
|
||||
const exportEvent = () => {
|
||||
let form = JSON.parse(JSON.stringify(tableStore.table.params))
|
||||
form.pageNum = 1
|
||||
|
||||
Reference in New Issue
Block a user