Browse Source

预警监督流程改造--取消通知报审人流程

main
buaixuexideshitongxue 1 month ago
parent
commit
fc864828e9
  1. 8
      src/api/warning/index.ts
  2. 48
      src/views/warning/edit.vue
  3. 18
      src/views/warning/index.vue

8
src/api/warning/index.ts

@ -45,3 +45,11 @@ export function getWarningInformList(id){
url:`/warning/getWarningInformList/${id}` url:`/warning/getWarningInformList/${id}`
}) })
} }
export function auditEndWarningApi(body){
return request.post({
url:'/reportFlow/auditEndWarning',
body
})
}

48
src/views/warning/edit.vue

@ -3,7 +3,14 @@ import useUserStore from "@/stores/modules/user";
import {FlowWarningEnum} from '@/enums/flowWarningEnums' import {FlowWarningEnum} from '@/enums/flowWarningEnums'
import {getDetail} from "@/api/report/index"; import {getDetail} from "@/api/report/index";
import {getReportFlow} from "@/api/report/flow"; import {getReportFlow} from "@/api/report/flow";
import {addOrUpData,getWarningDetail,getWarningRecord,getWarningAudit,getWarningInformList} from '@/api/warning/index' import {
addOrUpData,
getWarningDetail,
getWarningRecord,
getWarningAudit,
getWarningInformList,
auditEndWarningApi
} from '@/api/warning/index'
import useCatchStore from "@/stores/modules/catch"; import useCatchStore from "@/stores/modules/catch";
import {listPolice} from "@/api/system/police"; import {listPolice} from "@/api/system/police";
import {timeFormat} from "@/utils/util"; import {timeFormat} from "@/utils/util";
@ -73,7 +80,9 @@ const getReportDetailFun =async (id)=>{
await getWarningDetailFun(data.id) await getWarningDetailFun(data.id)
}else{ }else{
// //
console.log("==============")
console.log(res.project)
res.project.warningState=="1"? recordDisplay.value=true: recordDisplay.value=false
} }
} }
@ -139,7 +148,23 @@ const warningInformFun = async ()=>{
loading.value=false; loading.value=false;
dialog.value=true dialog.value=true
} }
//
const auditEndWarning = async ()=>{
await formDataRef.value.validate();
loading.value=true;
const body={
reportId:formData.value.reportProject.id
}
const res= await auditEndWarningApi(body)
feedback.msgSuccess("操作成功")
router.push({
path: "/warning",
query: {
refresh: Date.now()
}
})
loading.value=false;
}
const closePage = ()=>{ const closePage = ()=>{
if (route.query.isEdit) { if (route.query.isEdit) {
@ -172,7 +197,7 @@ const addOrUpDataFun = async ()=>{
} }
// //
async function SubmitFun(){ async function SubmitFun(){
await formDataRef.value.validate(); await formDataRef.value.validate();
await feedback.confirm("是否提交审计数据?"); await feedback.confirm("是否提交审计数据?");
@ -255,11 +280,16 @@ async function getAuditTableFun(){
reportFlowTable.value = res; reportFlowTable.value = res;
} }
async function getAuditTableInformFun(){ async function getAuditTableInformFun(type){
// //
reportFlowDialog.value = true reportFlowDialog.value = true
reportFlowLoading.value=true reportFlowLoading.value=true
const res = await getReportFlow({id:formData.value.record.id,code:'inform'}); let res;
if (type){
res= await getReportFlow({id:formData.value.reportProject.id,code:type});
}else {
res = await getReportFlow({id:formData.value.record.id,code:'inform'});
}
reportFlowLoading.value=false reportFlowLoading.value=false
reportFlowTable.value = res; reportFlowTable.value = res;
} }
@ -698,13 +728,15 @@ const ensureSupervisionTime = () => {
</div> </div>
<div class="flex end mt-20" v-if="route.query.isEdit && !recordDisplay "> <div class="flex end mt-20" v-if="route.query.isEdit && !recordDisplay ">
<el-button type="primary" @click="addOrUpDataFun">保存</el-button> <el-button type="primary" @click="addOrUpDataFun">保存</el-button>
<el-button type="primary" @click="warningInformFun">通知报审单位</el-button> <!-- <el-button type="primary" @click="warningInformFun">通知报审单位</el-button>-->
<el-button type="primary" @click="getAuditTableInformFun('end')">签收审批记录</el-button>
<el-button type="warning" @click="auditEndWarning">结束</el-button>
<el-button type="primary" @click="SubmitFun">提交至领导</el-button> <el-button type="primary" @click="SubmitFun">提交至领导</el-button>
<el-button @click="closePage" >取消</el-button> <el-button @click="closePage" >取消</el-button>
</div> </div>
<div class="flex end mt-20" v-else> <div class="flex end mt-20" v-else>
<el-button type="primary" @click="getAuditTableFun">领导审批记录</el-button> <el-button type="primary" @click="getAuditTableFun">领导审批记录</el-button>
<el-button type="primary" @click="getAuditTableInformFun">签收审批记录</el-button> <el-button type="primary" @click="getAuditTableInformFun('end')">签收审批记录</el-button>
<el-button type="primary" v-if="isAudit && (codeData !='inform')" @click="passFun">通过</el-button> <el-button type="primary" v-if="isAudit && (codeData !='inform')" @click="passFun">通过</el-button>
<el-button type="primary" v-if="isAudit && (codeData =='inform')" @click="passInformFun">签收</el-button> <el-button type="primary" v-if="isAudit && (codeData =='inform')" @click="passInformFun">签收</el-button>
<el-button type="danger" v-if="isAudit" @click="rejectFun">驳回</el-button> <el-button type="danger" v-if="isAudit" @click="rejectFun">驳回</el-button>

18
src/views/warning/index.vue

@ -126,15 +126,15 @@ watch(()=>route.query.load,(val)=>{
min-width="120" min-width="120"
show-overflow-tooltip show-overflow-tooltip
/> />
<el-table-column label="数据状态" width="110"> <!-- <el-table-column label="数据状态" width="110">-->
<template #default="{ row }"> <!-- <template #default="{ row }">-->
<!-- //1 2 ,0--> <!-- &lt;!&ndash; //1 2 ,0&ndash;&gt;-->
<p v-if="row.stateData == '1'">已下发问题</p> <!-- <p v-if="row.stateData == '1'">已下发问题</p>-->
<p v-else-if ="row.stateData == '2'" >已提交审核</p> <!-- <p v-else-if ="row.stateData == '2'" >已提交审核</p>-->
<p v-else >待预警</p> <!-- <p v-else >待预警</p>-->
</template> <!-- </template>-->
</el-table-column> <!-- </el-table-column>-->
<el-table-column <el-table-column
label="项目类别" label="项目类别"
min-width="120" min-width="120"
@ -230,7 +230,7 @@ watch(()=>route.query.load,(val)=>{
<el-table-column label="操作" fixed="right" min-width="120px"> <el-table-column label="操作" fixed="right" min-width="120px">
<template #default="{ row }"> <template #default="{ row }">
<p v-if="row.stateData == '1'">已下发问题</p> <p v-if="row.stateData == '1'">已下发问题</p>
<el-button v-else-if ="row.stateData == '2'" @click="editFun(row)">查看</el-button> <el-button v-else-if ="row.warningState == '1'" @click="editFun(row)">查看</el-button>
<el-button v-else type="primary" @click="editFun(row)">预警</el-button> <el-button v-else type="primary" @click="editFun(row)">预警</el-button>
</template> </template>
</el-table-column> </el-table-column>

Loading…
Cancel
Save