预告警问题详情查看
This commit is contained in:
@@ -94,7 +94,7 @@ const tableStore = new TableStore({
|
||||
render: 'basicButton',
|
||||
click: row => {
|
||||
// handleAudit(row.processInstanceId)
|
||||
ElMessage.warning("待打通生成管理系统接口!")
|
||||
ElMessage.warning('待打通生成管理系统接口!')
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -107,7 +107,7 @@ const tableStore = new TableStore({
|
||||
return row.status !== 5
|
||||
},
|
||||
click: row => {
|
||||
feedbackPopup.value.open('填报反馈单',row.id,row.status)
|
||||
feedbackPopup.value.open('填报反馈单', row.id, row.status, row.issueDetail,row.problemPath)
|
||||
}
|
||||
},
|
||||
|
||||
@@ -121,7 +121,7 @@ const tableStore = new TableStore({
|
||||
return row.status == 5
|
||||
},
|
||||
click: row => {
|
||||
handleAudit(row.processInstanceId)
|
||||
handleAudit(row.processInstanceId)
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -171,12 +171,12 @@ onMounted(() => {
|
||||
|
||||
/** 流程实例详情 */
|
||||
const handleAudit = (instanceId: any) => {
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
id: instanceId
|
||||
}
|
||||
})
|
||||
push({
|
||||
name: 'BpmProcessInstanceDetail',
|
||||
query: {
|
||||
id: instanceId
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ const tableStore = new TableStore({
|
||||
return row.status !== 5
|
||||
},
|
||||
click: row => {
|
||||
feedbackPopup.value.open('填报反馈单', row.id, row.status)
|
||||
feedbackPopup.value.open('填报反馈单', row.id, row.status, row.issueDetail,row.problemPath)
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1,58 +1,76 @@
|
||||
<template>
|
||||
<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-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='采取的措施:' prop='takeStep'>
|
||||
<el-input
|
||||
v-model='formData.takeStep'
|
||||
autocomplete='off'
|
||||
placeholder='请输入采取的措施'
|
||||
type='textarea'
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label='问题详情:'>
|
||||
<el-input
|
||||
v-model='formData.issueDetail'
|
||||
autocomplete='off'
|
||||
type='textarea'
|
||||
:autosize='{minRows:2,maxRows:6}'
|
||||
readonly
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label='反馈报告:' prop='reportPath'>
|
||||
<el-upload
|
||||
ref='uploadRef'
|
||||
action=''
|
||||
accept='.doc,.docx,.xlsx,.xls,.pdf'
|
||||
:limit='1'
|
||||
:on-exceed='handleExceed'
|
||||
:on-change='choose'
|
||||
:auto-upload='false'
|
||||
:on-progress="uploadFileName('reportPath')"
|
||||
>
|
||||
<template #trigger>
|
||||
<el-button type='primary'>上传文件</el-button>
|
||||
</template>
|
||||
</el-upload>
|
||||
</el-form-item>
|
||||
<el-form-item label='问题附件:' v-if='showFile'>
|
||||
<el-icon>
|
||||
<Link />
|
||||
</el-icon>
|
||||
<a :href='problemDetail.problemPath' target='_blank'>{{ problemDetail.problemName }}</a>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
</el-scrollbar>
|
||||
<el-form-item label='采取的措施:' prop='takeStep'>
|
||||
<el-input
|
||||
v-model='formData.takeStep'
|
||||
autocomplete='off'
|
||||
placeholder='请输入采取的措施'
|
||||
type='textarea'
|
||||
/>
|
||||
</el-form-item>
|
||||
|
||||
<template #footer>
|
||||
<el-form-item label='反馈报告:' prop='reportPath'>
|
||||
<el-upload
|
||||
ref='uploadRef'
|
||||
action=''
|
||||
accept='.doc,.docx,.xlsx,.xls,.pdf'
|
||||
:limit='1'
|
||||
:on-exceed='handleExceed'
|
||||
:on-change='choose'
|
||||
:auto-upload='false'
|
||||
:on-progress="uploadFileName('reportPath')"
|
||||
>
|
||||
<template #trigger>
|
||||
<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>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
<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 { uploadFile } from '@/api/system-boot/file'
|
||||
import { getFileNameAndFilePath, uploadFile } from '@/api/system-boot/file'
|
||||
import { addFeedback } from '@/api/supervision-boot/leaflet'
|
||||
import { Link } from '@element-plus/icons-vue'
|
||||
|
||||
//下拉数据源
|
||||
const title = ref('')
|
||||
@@ -63,10 +81,18 @@ const uploadRef = ref()
|
||||
const dialogVisible = ref(false)
|
||||
// 注意不要和表单ref的命名冲突
|
||||
const formData = reactive({
|
||||
id: '',
|
||||
status: '',
|
||||
takeStep: '',
|
||||
reportPath: ''
|
||||
id: '',
|
||||
status: '',
|
||||
issueDetail: '',
|
||||
takeStep: '',
|
||||
reportPath: ''
|
||||
})
|
||||
//附件是否显示
|
||||
const showFile = ref(false)
|
||||
|
||||
const problemDetail = reactive({
|
||||
problemPath: '',
|
||||
problemName: ''
|
||||
})
|
||||
|
||||
//处理成效报告
|
||||
@@ -74,56 +100,69 @@ const reportPath = ref('')
|
||||
|
||||
//form表单校验规则
|
||||
const rules = {
|
||||
takeStep: [{ required: true, message: '请输入采取的措施', trigger: 'blur' }]
|
||||
takeStep: [{ required: true, message: '请输入采取的措施', trigger: 'blur' }]
|
||||
}
|
||||
const resetForm = () => {
|
||||
if (formRef.value) {
|
||||
formRef.value.resetFields()
|
||||
}
|
||||
if (formRef.value) {
|
||||
formRef.value.resetFields()
|
||||
}
|
||||
}
|
||||
|
||||
const open = async (text: string, id: string, status: any, takeStep?: string, reportPath?: string) => {
|
||||
title.value = text
|
||||
resetForm()
|
||||
if (takeStep) {
|
||||
formData.takeStep = takeStep
|
||||
}
|
||||
uploadRef.value?.clearFiles()
|
||||
if (reportPath) {
|
||||
formData.reportPath = reportPath
|
||||
}
|
||||
formData.id = id
|
||||
formData.status = status
|
||||
dialogVisible.value = true
|
||||
const open = async (text: string, id: string, status: any, issueDetail: string, problemPath?: string, takeStep?: string, reportPath?: string) => {
|
||||
title.value = text
|
||||
resetForm()
|
||||
if (takeStep) {
|
||||
formData.takeStep = takeStep
|
||||
}
|
||||
uploadRef.value?.clearFiles()
|
||||
if (reportPath) {
|
||||
formData.reportPath = reportPath
|
||||
}
|
||||
formData.id = id
|
||||
formData.status = status
|
||||
formData.issueDetail = issueDetail
|
||||
//判断附件是否存在,如果存在则回显出让用户可以点击下载
|
||||
if (problemPath) {
|
||||
let arrPath = problemPath.split(',')
|
||||
await getFileNameAndFilePath({ filePath: arrPath[0] }).then(res => {
|
||||
problemDetail.problemPath = res.data.url
|
||||
problemDetail.problemName = res.data.fileName
|
||||
})
|
||||
showFile.value = true
|
||||
}else{
|
||||
showFile.value = false
|
||||
}
|
||||
|
||||
dialogVisible.value = true
|
||||
}
|
||||
|
||||
/**
|
||||
* 提交用户表单数据
|
||||
*/
|
||||
const submit = () => {
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
if (!reportPath.value) {
|
||||
return ElMessage({
|
||||
message: '请上传处理成效报告',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
if (formData.status == '3') {
|
||||
// await quitRunningDeviceUpdate(formData)
|
||||
ElMessage.success('重新发起成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
} else {
|
||||
//此时该告警单处于待反馈状态
|
||||
await addFeedback(formData)
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
}
|
||||
}
|
||||
})
|
||||
formRef.value.validate(async (valid: any) => {
|
||||
if (valid) {
|
||||
if (!reportPath.value) {
|
||||
return ElMessage({
|
||||
message: '请上传处理成效报告',
|
||||
type: 'warning'
|
||||
})
|
||||
}
|
||||
if (formData.status == '3') {
|
||||
// await quitRunningDeviceUpdate(formData)
|
||||
ElMessage.success('重新发起成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
} else {
|
||||
//此时该告警单处于待反馈状态
|
||||
await addFeedback(formData)
|
||||
//查询进线数据,避免一直处于loading状态
|
||||
ElMessage.success('申请成功')
|
||||
tableStore.index()
|
||||
dialogVisible.value = false
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
defineExpose({ open })
|
||||
@@ -131,33 +170,33 @@ 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
|
||||
})
|
||||
uploadFile(e.raw, '/supervision/').then(res => {
|
||||
reportPath.value = res.data.name
|
||||
formData.reportPath = res.data.name
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
const handleExceed: UploadProps['onExceed'] = files => {
|
||||
uploadRef.value!.clearFiles()
|
||||
const file = files[0] as UploadRawFile
|
||||
file.uid = genFileId()
|
||||
uploadRef.value!.handleStart(file)
|
||||
uploadRef.value!.clearFiles()
|
||||
const file = files[0] as UploadRawFile
|
||||
file.uid = genFileId()
|
||||
uploadRef.value!.handleStart(file)
|
||||
}
|
||||
|
||||
//上传报告改变
|
||||
const uploadFileName = val => {
|
||||
uploadName.value = val
|
||||
uploadName.value = val
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang='scss'>
|
||||
.el-upload-list__item {
|
||||
transition: none !important;
|
||||
transition: none !important;
|
||||
}
|
||||
|
||||
.el-select {
|
||||
min-width: 180px;
|
||||
min-width: 180px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,55 +1,55 @@
|
||||
<!-- 流程详情页面 tab切换 -->
|
||||
<template>
|
||||
<div class="default-main" style="overflow: hidden;">
|
||||
<div class='default-main' style='overflow: hidden;'>
|
||||
<!--返回按钮-->
|
||||
<back-component style="margin: 8px; position: absolute; z-index: 10; top: -3px; right: 2px" />
|
||||
<el-tabs type="border-card" v-model="tab" @tab-click="handleClickTab">
|
||||
<el-tab-pane label="流程审核" name="流程审核" v-if="runningTasks.length > 0">
|
||||
<back-component style='margin: 8px; position: absolute; z-index: 10; top: -3px; right: 2px' />
|
||||
<el-tabs type='border-card' v-model='tab' @tab-click='handleClickTab'>
|
||||
<el-tab-pane label='流程审核' name='流程审核' v-if='runningTasks.length > 0'>
|
||||
<el-card
|
||||
v-for="(item, index) in runningTasks"
|
||||
:key="index"
|
||||
v-loading="processInstanceLoading"
|
||||
class="box-card"
|
||||
v-for='(item, index) in runningTasks'
|
||||
:key='index'
|
||||
v-loading='processInstanceLoading'
|
||||
class='box-card'
|
||||
>
|
||||
<template #header>
|
||||
<span class="el-icon-picture-outline">当前任务【{{ item.name }}】</span>
|
||||
<span class='el-icon-picture-outline'>当前任务【{{ item.name }}】</span>
|
||||
</template>
|
||||
<el-col :offset="6" :span="16">
|
||||
<el-col :offset='6' :span='16'>
|
||||
<el-form
|
||||
:ref="'form' + index"
|
||||
:model="auditForms[index]"
|
||||
:rules="auditRule"
|
||||
label-width="100px"
|
||||
:model='auditForms[index]'
|
||||
:rules='auditRule'
|
||||
label-width='100px'
|
||||
>
|
||||
<el-form-item v-if="processInstance && processInstance.name" label="流程名">
|
||||
<el-form-item v-if='processInstance && processInstance.name' label='流程名'>
|
||||
{{ processInstance.name }}
|
||||
</el-form-item>
|
||||
<el-form-item v-if="processInstance && processInstance.startUser" label="发起人">
|
||||
<el-form-item v-if='processInstance && processInstance.startUser' label='发起人'>
|
||||
{{ processInstance?.startUser.name }}
|
||||
</el-form-item>
|
||||
<el-form-item v-if="processInstance && processInstance.startUser" label="发起部门">
|
||||
<el-form-item v-if='processInstance && processInstance.startUser' label='发起部门'>
|
||||
{{ processInstance?.startUser.deptName }}
|
||||
</el-form-item>
|
||||
|
||||
<el-card v-if="runningTasks[index].formId != null" class="mb-15px !-mt-10px">
|
||||
<el-card v-if='runningTasks[index].formId != null' class='mb-15px !-mt-10px'>
|
||||
<template #header>
|
||||
<span class="el-icon-picture-outline">
|
||||
<span class='el-icon-picture-outline'>
|
||||
{{ runningTasks[index]?.formName }}
|
||||
</span>
|
||||
</template>
|
||||
<form-create
|
||||
v-model="approveForms[index].value"
|
||||
v-model:api="approveFormFApis[index]"
|
||||
:option="approveForms[index].option"
|
||||
:rule="approveForms[index].rule"
|
||||
v-model='approveForms[index].value'
|
||||
v-model:api='approveFormFApis[index]'
|
||||
:option='approveForms[index].option'
|
||||
:rule='approveForms[index].rule'
|
||||
/>
|
||||
</el-card>
|
||||
|
||||
<el-form-item label="审批建议" prop="reason" style="margin-top: 15px">
|
||||
<el-form-item label='审批建议' prop='reason' style='margin-top: 15px'>
|
||||
<el-input
|
||||
v-model="auditForms[index].reason"
|
||||
placeholder="请输入审批建议"
|
||||
type="textarea"
|
||||
v-model='auditForms[index].reason'
|
||||
placeholder='请输入审批建议'
|
||||
type='textarea'
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label='抄送人' prop='copyUserIds'>-->
|
||||
@@ -63,10 +63,10 @@
|
||||
<!-- </el-select>-->
|
||||
<!-- </el-form-item>-->
|
||||
</el-form>
|
||||
<div style="margin-bottom: 20px; margin-left: 10%; font-size: 14px">
|
||||
<el-button type="success" :icon="Select" @click="handleAudit(item, true)">通过</el-button>
|
||||
<div style='margin-bottom: 20px; margin-left: 10%; font-size: 14px'>
|
||||
<el-button type='success' :icon='Select' @click='handleAudit(item, true)'>通过</el-button>
|
||||
|
||||
<el-button type="danger" :icon="Close" @click="handleAudit(item, false)">不通过</el-button>
|
||||
<el-button type='danger' :icon='Close' @click='handleAudit(item, false)'>不通过</el-button>
|
||||
|
||||
<!-- <el-button type='primary' @click='openTaskUpdateAssigneeForm(item.id)'>-->
|
||||
<!-- <Icon icon='ep:edit' />-->
|
||||
@@ -80,66 +80,65 @@
|
||||
<!-- <Icon icon='ep:plus' />-->
|
||||
<!-- 加签-->
|
||||
<!-- </el-button>-->
|
||||
|
||||
<el-button type="warning" :icon="Back" @click="handleBack(item)">回退</el-button>
|
||||
<!-- <el-button type="warning" :icon="Back" @click="handleBack(item)">回退</el-button>-->
|
||||
</div>
|
||||
</el-col>
|
||||
</el-card>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="申请信息" name="申请信息">
|
||||
<el-tab-pane label='申请信息' name='申请信息'>
|
||||
<!-- 申请信息 -->
|
||||
<el-card v-loading="processInstanceLoading" class="box-card">
|
||||
<el-card v-loading='processInstanceLoading' class='box-card'>
|
||||
<template #header>
|
||||
<span class="el-icon-document">申请信息【{{ processInstance.name }}】</span>
|
||||
<span class='el-icon-document'>申请信息【{{ processInstance.name }}】</span>
|
||||
</template>
|
||||
<!-- 情况一:流程表单 -->
|
||||
<el-col v-if="processInstance?.processDefinition?.formType === 10" :offset="6" :span="16">
|
||||
<el-col v-if='processInstance?.processDefinition?.formType === 10' :offset='6' :span='16'>
|
||||
<form-create
|
||||
v-model="detailForm.value"
|
||||
v-model:api="fApi"
|
||||
:option="detailForm.option"
|
||||
:rule="detailForm.rule"
|
||||
v-model='detailForm.value'
|
||||
v-model:api='fApi'
|
||||
:option='detailForm.option'
|
||||
:rule='detailForm.rule'
|
||||
/>
|
||||
</el-col>
|
||||
<!-- 情况二:业务表单 -->
|
||||
<div v-if="processInstance?.processDefinition?.formType === 20">
|
||||
<BusinessFormComponent :id="processInstance.businessKey" :applyTitle="processInstance.name" />
|
||||
<div v-if='processInstance?.processDefinition?.formType === 20'>
|
||||
<BusinessFormComponent :id='processInstance.businessKey' :applyTitle='processInstance.name' />
|
||||
</div>
|
||||
</el-card>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="审批记录" name="审批记录">
|
||||
<el-tab-pane label='审批记录' name='审批记录'>
|
||||
<!-- 审批记录 -->
|
||||
<ProcessInstanceTaskList
|
||||
:loading="tasksLoad"
|
||||
:process-instance="processInstance"
|
||||
:tasks="tasks"
|
||||
@refresh="getTaskList"
|
||||
:loading='tasksLoad'
|
||||
:process-instance='processInstance'
|
||||
:tasks='tasks'
|
||||
@refresh='getTaskList'
|
||||
/>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="流程图" name="流程图">
|
||||
<el-tab-pane label='流程图' name='流程图'>
|
||||
<ProcessInstanceBpmnViewer
|
||||
ref="mapRef"
|
||||
:id="`${id}`"
|
||||
:bpmn-xml="bpmnXml"
|
||||
:loading="processInstanceLoading"
|
||||
:process-instance="processInstance"
|
||||
:tasks="tasks"
|
||||
ref='mapRef'
|
||||
:id='`${id}`'
|
||||
:bpmn-xml='bpmnXml'
|
||||
:loading='processInstanceLoading'
|
||||
:process-instance='processInstance'
|
||||
:tasks='tasks'
|
||||
/>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
<ContentWrap>
|
||||
<!-- 弹窗:转派审批人 -->
|
||||
<TaskTransferForm ref="taskTransferFormRef" @success="getDetail" />
|
||||
<TaskTransferForm ref='taskTransferFormRef' @success='getDetail' />
|
||||
<!-- 弹窗:回退节点 -->
|
||||
<TaskReturnForm ref="taskReturnFormRef" @success="getDetail" />
|
||||
<TaskReturnForm ref='taskReturnFormRef' @success='getDetail' />
|
||||
<!-- 弹窗:委派,将任务委派给别人处理,处理完成后,会重新回到原审批人手中-->
|
||||
<TaskDelegateForm ref="taskDelegateForm" @success="getDetail" />
|
||||
<TaskDelegateForm ref='taskDelegateForm' @success='getDetail' />
|
||||
<!-- 弹窗:加签,当前任务审批人为A,向前加签选了一个C,则需要C先审批,然后再是A审批,向后加签B,A审批完,需要B再审批完,才算完成这个任务节点 -->
|
||||
<TaskSignCreateForm ref="taskSignCreateFormRef" @success="getDetail" />
|
||||
<TaskSignCreateForm ref='taskSignCreateFormRef' @success='getDetail' />
|
||||
</ContentWrap>
|
||||
</div>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
<script lang='ts' setup>
|
||||
import { onMounted, provide, ref, getCurrentInstance, reactive, watch, unref, nextTick, markRaw } from 'vue'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import { useUserStore } from '@/stores/modules/user'
|
||||
@@ -275,9 +274,9 @@ const getDetail = () => {
|
||||
getTaskList()
|
||||
}
|
||||
//tab切换
|
||||
const mapRef=ref(null)
|
||||
const handleClickTab = (tab:any, event:any) => {
|
||||
if(tab.props.name=='流程图'){
|
||||
const mapRef = ref(null)
|
||||
const handleClickTab = (tab: any, event: any) => {
|
||||
if (tab.props.name == '流程图') {
|
||||
mapRef.value.getMapList()
|
||||
}
|
||||
}
|
||||
@@ -415,8 +414,8 @@ onMounted(async () => {
|
||||
}
|
||||
})
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-tab-pane{
|
||||
<style lang='scss' scoped>
|
||||
::v-deep .el-tab-pane {
|
||||
height: calc(100vh - 200px) !important;
|
||||
overflow: auto !important;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user