瀏覽代碼

部门主任归档信息撤回功能

徐滕 2 周之前
父節點
當前提交
dee64d8fec
共有 1 個文件被更改,包括 28 次插入0 次删除
  1. 28 0
      src/views/program/registered/ProjectList.vue

+ 28 - 0
src/views/program/registered/ProjectList.vue

@@ -371,6 +371,12 @@
                 v-if="hasPermission('project:achieve:edit') && (scope.row.archiveStatus === '5' || scope.row.archiveStatus === '7') && scope.row.cancellationStatus !== '5'"
                 text type="primary" @click="archiveEdit(scope.row)">归档修改</el-button>
 
+
+				<!-- 项目归档撤回-->
+				<el-button
+					v-if="hasPermission('project:achieve:break') &&  (scope.row.archiveStatus === '5' || scope.row.archiveStatus === '7')"
+					text type="primary" @click="archiveRebackOnbmzr(scope.row)">项目归档撤回</el-button>
+
               <!--一级校审ftl文件下载-->
               <!--              <el-button v-if="hasPermission('program:registered:edit')" text type="primary"  icon="el-icon-circle-check"  @click="downloadFirstAuditTpl(scope.row)">一级校审下载</el-button>-->
               <!--              <el-button v-if="hasPermission('program:registered:edit')" text type="primary"  icon="el-icon-circle-check"  @click="downloadSecondAuditTpl(scope.row)">二级校审下载</el-button>-->
@@ -1176,6 +1182,28 @@ export default {
         })
       })
     },
+    // 部门主任撤回已审核完成的项目归档信息
+    archiveRebackOnbmzr(row) {
+      this.$confirm(`确定要撤回该报告归档吗?`, '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(async () => {
+        await this.programProjectListInfoService.findByIdArchive(row.archiveId).then((data) => {
+          if (data.status !== '5' && data.status !== '7') { // status的值不等于“审核中”,就弹出提示
+            this.$message.error('报告归档当前为非完成状态,无法进行撤回')
+            this.refreshList()
+          } else {
+            processService.revokeProcIns(row.procInsIdArchive).then((data) => {
+              let form = { status: '3', id: row.archiveId }
+              this.programProjectListInfoService.updateStatusByArchiveId(form)
+              this.$message.success(data)
+              this.refreshList()
+            })
+          }
+        })
+      })
+    },
     // 下载一级校审
     downloadFirstAuditTpl(row) {
       // this.$utils.downloadExcel('/sys/project/import/template')