催办接口完成

This commit is contained in:
2026-09-23 14:05:32 +08:00
parent 86a3520ecb
commit c73d5ba8a6
5 changed files with 36 additions and 12 deletions
+8
View File
@@ -44,3 +44,11 @@ export function useAiAnalysisApi(id: number, stepId: number, params: {action: st
data: params data: params
}); });
} }
// 催办
export function urgeApi(id: number) {
return request({
url: `/api/changes/${id}/urge`,
method: 'post',
});
}
+9 -3
View File
@@ -7,6 +7,7 @@ import { tagTextColor, tagBgColor, tagBorderColor, getTimeRangeStamp, formatTime
import { systemConfigApi } from '@/service/api/system'; import { systemConfigApi } from '@/service/api/system';
import { orgListApi } from '@/service/api/user'; import { orgListApi } from '@/service/api/user';
import { changeLedgerListApi } from '@/service/api/changeLedger'; import { changeLedgerListApi } from '@/service/api/changeLedger';
import { urgeApi } from '@/service/api/change';
const { routerPushByKey } = useRouterPush(); const { routerPushByKey } = useRouterPush();
const themeStore = useThemeStore(); const themeStore = useThemeStore();
@@ -237,8 +238,13 @@ const downloadFiles = (r:any,type:string) => {
} }
// 催办 // 催办
const urge = (r:any) => { const urge = async (r:any) => {
window.$message?.info('还差接口'); loading.value = true;
const {error} = await urgeApi(r.id);
if(!error){
window.$message?.success('催办成功');
}
loading.value = false;
} }
// 分页改变 // 分页改变
@@ -478,7 +484,7 @@ onMounted(async () => {
<!-- 已关闭 --> <!-- 已关闭 -->
<NButton v-if="r.status==='CLOSED'" size="small" ghost type="success" class="text-xs" @click="downloadFiles(r,'closed')">下载归档包</NButton> <NButton v-if="r.status==='CLOSED'" size="small" ghost type="success" class="text-xs" @click="downloadFiles(r,'closed')">下载归档包</NButton>
<!-- 催办(超期) --> <!-- 催办(超期) -->
<NButton v-if="r.overdue_days" size="small" ghost type="error" class="text-xs" @click="urge(r)">催办</NButton> <NButton v-if="r.overdue_days && r.status!=='CLOSED' && r.status!=='WITHDRAWN' && r.status!=='REJECTED'" size="small" ghost type="error" :disabled="loading" class="text-xs" @click="urge(r)">催办</NButton>
<NButton size="small" type="primary" class="text-xs" @click="jumpTo(r)">详情</NButton> <NButton size="small" type="primary" class="text-xs" @click="jumpTo(r)">详情</NButton>
<NButton size="small" type="default" class="text-xs" @click="openProgress(r)">进度</NButton> <NButton size="small" type="default" class="text-xs" @click="openProgress(r)">进度</NButton>
</div> </div>
+9 -4
View File
@@ -7,7 +7,7 @@ import { useRoute } from 'vue-router';
import { getColorWithOpacity, tagTextColor, tagBgColor, tagBorderColor, formatTimestamp } from '@/utils/common'; import { getColorWithOpacity, tagTextColor, tagBgColor, tagBorderColor, formatTimestamp } from '@/utils/common';
import { AiError, aiTypeJudge } from "@/service/api/ai"; import { AiError, aiTypeJudge } from "@/service/api/ai";
import { systemConfigApi } from '@/service/api/system'; import { systemConfigApi } from '@/service/api/system';
import { getChangeDetailApi } from '@/service/api/change'; import { getChangeDetailApi, urgeApi } from '@/service/api/change';
import { myTasksDisposalSubmitApi, myTasksAddItemApi } from '@/service/api/myTasks'; import { myTasksDisposalSubmitApi, myTasksAddItemApi } from '@/service/api/myTasks';
import previewComponent from '@/components/previewFile/index.vue' import previewComponent from '@/components/previewFile/index.vue'
@@ -225,9 +225,14 @@ const openPreview = (file:any) => {
} }
// 催办 // 催办
const handleReminder = (m: any) => { const handleReminder = async (m: any) => {
window.$message?.info('还差接口') if(loading.value) return;
window.$message?.success(`已催办 ${m.user_name}(系统消息 + 企业微信 + 短信),连续 2 次未响应将上报部门负责人`) loading.value = true;
const {error} = await urgeApi(currentId.value);
if(!error){
window.$message?.success('催办成功');
}
loading.value = false;
} }
// 更新选中审批人 user_id // 更新选中审批人 user_id
+9 -4
View File
@@ -7,7 +7,7 @@ import { useRoute } from 'vue-router';
import { tagTextColor, tagBgColor, tagBorderColor, downloadFileFun } from '@/utils/common'; import { tagTextColor, tagBgColor, tagBorderColor, downloadFileFun } from '@/utils/common';
import { AiError, aiTypeJudge } from "@/service/api/ai"; import { AiError, aiTypeJudge } from "@/service/api/ai";
import { systemConfigApi } from '@/service/api/system'; import { systemConfigApi } from '@/service/api/system';
import { getChangeDetailApi } from '@/service/api/change'; import { getChangeDetailApi, urgeApi } from '@/service/api/change';
import previewComponent from '@/components/previewFile/index.vue' import previewComponent from '@/components/previewFile/index.vue'
const themeStore = useThemeStore(); const themeStore = useThemeStore();
@@ -197,9 +197,14 @@ const openPreview = (file:any) => {
} }
// 催办 // 催办
const handleReminder = (m: any) => { const handleReminder = async (m: any) => {
window.$message?.info('还差接口') if(loading.value) return;
window.$message?.success(`已催办 ${m.user_name}(系统消息 + 企业微信 + 短信),连续 2 次未响应将上报部门负责人`) loading.value = true;
const {error} = await urgeApi(currentId.value);
if(!error){
window.$message?.success('催办成功');
}
loading.value = false;
} }
// 匹配评分依据 // 匹配评分依据
+1 -1
View File
@@ -1,3 +1,4 @@
<!-- PSSR监督 -->
<script setup lang="ts"> <script setup lang="ts">
import { ref, onMounted } from 'vue'; import { ref, onMounted } from 'vue';
import { Icon } from '@iconify/vue' import { Icon } from '@iconify/vue'
@@ -146,7 +147,6 @@ onMounted(() => {
<template> <template>
<NSpace vertical :size="16"> <NSpace vertical :size="16">
<!-- PSSR监督 -->
<NSpin :show="loading" size="small"> <NSpin :show="loading" size="small">
<NCard :bordered="false" size="small" :style="{ borderRadius: themeStore.themeRadius + 'px' }"> <NCard :bordered="false" size="small" :style="{ borderRadius: themeStore.themeRadius + 'px' }">
<div <div