gaoluyang
2025-03-07 f112e2c62b6fca7b115dd37e34dc19dbcbc91d15
src/views/CNAS/systemManagement/documentRecords/approvalRecord.vue
@@ -20,9 +20,9 @@
      </div>
      <div class="btn">
        <el-button size="small" type="primary" @click="openAdd('新增')">新增</el-button>
        <el-upload :action="action" :multiple="false" :show-file-list="false" accept='.doc,.docx' :headers="headers"
          :on-change="beforeUpload" :on-error="onError" ref='upload' :on-success="handleSuccessUp"
          style="display:inline-block;margin-left: 20px;">
        <el-upload :action="action" :multiple="false" :show-file-list="false" accept='.doc,.docx'
          :headers="uploadHeader" :on-change="beforeUpload" :on-error="onError" ref='upload'
          :on-success="handleSuccessUp" style="display:inline-block;margin-left: 20px;">
          <el-button type="primary" size="small">导入</el-button></el-upload>
        <el-button size="small" type="primary" @click="handleDown" :loading="outLoading"
          style="display:inline-block;margin-left: 20px;">导出</el-button>
@@ -83,7 +83,6 @@
<script>
import limsTable from "@/components/Table/lims-table.vue";
import { getToken } from "@/utils/auth";
import {
  selectUserCondition,
} from "@/api/business/inspectionTask.js";
@@ -186,11 +185,6 @@
  },
  // 用于上传文件的信息
  computed: {
    headers() {
      return {
        'Authorization': "Bearer " + getToken()
      }
    },
    action() {
      return this.javaApi + '/manageRecordCheck/exportInManageRecordCheck'
    }
@@ -289,10 +283,7 @@
      // queryParams
      exportOutManageRecordCheck(this.queryParams).then(res => {
        this.outLoading = false
        if (res.code == 201) return this.$message.error('导出失败')
        this.$message.success('导出成功')
        let url = this.javaApi + 'word/' + res.message
        this.$download.saveAs(url, '文件审批记录')
        this.$download.downloadFileFromUrl(res.data, '文件审批记录')
      })
    },
    getAuthorizedPerson() {
@@ -305,7 +296,7 @@
          })
        })
        this.personList = data
        this.refreshTable()()
        this.refreshTable()
      })
    },
    // 审核
@@ -320,7 +311,6 @@
          if (action === 'confirm') {
            // 点击“确定”按钮,允许关闭
            checkManageRecordCheck({ id: row.id, checkState: '通过' }).then(res => {
              if (res.code === 201) return
              this.refreshTable()
              done();
              this.$message({
@@ -334,7 +324,6 @@
          } else if (action === 'cancel') {
            // 点击“取消”按钮,不允许关闭
            checkManageRecordCheck({ id: row.id, checkState: '不通过' }).then(res => {
              if (res.code === 201) return
              this.refreshTable()
              done();
              this.$message({
@@ -366,7 +355,6 @@
          if (action === 'confirm') {
            // 点击“确定”按钮,允许关闭
            ratifyManageRecordCheck({ id: row.id, ratifyState: '通过' }).then(res => {
              if (res.code === 201) return
              this.refreshTable()
              done();
              this.$message({
@@ -380,7 +368,6 @@
          } else if (action === 'cancel') {
            // 点击“取消”按钮,不允许关闭
            ratifyManageRecordCheck({ id: row.id, ratifyState: '不通过' }).then(res => {
              if (res.code === 201) return
              this.refreshTable()
              done();
              this.$message({
@@ -417,7 +404,7 @@
      this.upLoading = false;
      if (response.code == 200) {
        this.$message.success('上传成功');
        this.refreshTable()()
        this.refreshTable()
      } else {
        this.$message.error('上传失败');
      }
@@ -469,7 +456,6 @@
      })
        .then(() => {
          delManageRecordCheck({ id: row.id }).then((res) => {
            if (res.code == 201) return;
            this.$message.success("删除成功");
            this.refresh();
          });