From d1ba466efd495012f8b4d55b85fb4b503f2ccfa9 Mon Sep 17 00:00:00 2001
From: "liang.chao" <1360241448@qq.com>
Date: Mon, 8 Dec 2025 16:24:36 +0800
Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/archivesManagement/archivingManage.js | 7 +++
.../components/rightTable.vue | 48 ++++++++++++++++++-
2 files changed, 54 insertions(+), 1 deletion(-)
diff --git a/src/api/archivesManagement/archivingManage.js b/src/api/archivesManagement/archivingManage.js
index 69bf12ef..539c4233 100644
--- a/src/api/archivesManagement/archivingManage.js
+++ b/src/api/archivesManagement/archivingManage.js
@@ -23,3 +23,10 @@ export function submitRectifyNoticeApi(data) {
data: data,
})
}
+export function agreeRectificationApi(data) {
+ return request({
+ url: '/blade-system/archivingManage/agreeRectification',
+ method: 'POST',
+ data: data,
+ })
+}
diff --git a/src/views/archivingManager/components/rightTable.vue b/src/views/archivingManager/components/rightTable.vue
index 229cdfd9..4207886c 100644
--- a/src/views/archivingManager/components/rightTable.vue
+++ b/src/views/archivingManager/components/rightTable.vue
@@ -21,6 +21,13 @@
>
下发整改通知
+
+ 同意归档
+
@@ -131,7 +138,7 @@ import { useRouter } from 'vue-router';
import { ref, reactive, watch, nextTick } from 'vue';
import { ElMessage, ElLoading, ElMessageBox } from 'element-plus';
import { getFileManageApi } from '@/api/archivesManagement/fileManager/fileManager.js';
-import { getArchivingManageFilesApi,submitRectifyNoticeApi } from '@/api/archivesManagement/archivingManage'; // 导入正确的API
+import { getArchivingManageFilesApi,submitRectifyNoticeApi,agreeRectificationApi } from '@/api/archivesManagement/archivingManage';
import ViewFile from '@/views/viewFile/viewFile.vue';
import FileTree from '@/views/common/fileTree.vue'; // 引入文件树组件
@@ -480,6 +487,45 @@ const submitRectifyNotice = async () => {
ElMessage.error('整改通知下发失败');
}
};
+
+// 同意归档方法
+const agreeRectification = async () => {
+ try {
+ // 确认操作
+ await ElMessageBox.confirm(
+ '确定要同意归档吗?此操作不可撤销。',
+ '确认归档',
+ {
+ confirmButtonText: '确定',
+ cancelButtonText: '取消',
+ type: 'warning'
+ }
+ );
+
+ const loading = ElLoading.service({
+ lock: true,
+ text: '正在处理归档,请稍候...',
+ background: 'rgba(0,0,0,0.5)'
+ });
+
+ // 调用同意归档API
+ await agreeRectificationApi({
+ proId: props.projectId // 项目ID
+ });
+
+ loading.close();
+ ElMessage.success('归档同意操作成功');
+
+ // 刷新数据
+ onLoad(page, query);
+ } catch (error) {
+ if (error !== 'cancel') { // 如果不是用户取消操作
+ console.error('同意归档失败:', error);
+ ElMessage.error('归档同意操作失败');
+ }
+ console.log('用户取消操作或操作失败');
+ }
+};