value
2024-04-22 94e2f78c6ff8eb51ce9b0a8c7a85062872cacb0c
src/components/view/b1-report-preparation.vue
@@ -217,7 +217,7 @@
            type: 'text',
            method: 'handleSubmit',
            disabFun: (row, index) => {
              return row.isExamine != null
              return row.state != 0
            }
          }, {
            id: 'handleIssued',
@@ -225,7 +225,7 @@
            type: 'text',
            method: 'handleIssued',
            disabFun: (row, index) => {
              return row.isExamine != null
              return row.state == null||row.state == 0 ||row.isExamine == 1
            }
          }, {
            id: 'handleApprove',
@@ -233,7 +233,7 @@
            type: 'text',
            method: 'handleApprove',
            disabFun: (row, index) => {
              return row.isRatify != null
              return row.state == null||row.state == 0||row.isExamine == 0||row.isExamine == null ||row.isRatify==1
            }
          }],
          linkEvent: {
@@ -262,6 +262,17 @@
                value: 1,
                type: 'success',
                label: '通过'
              }]
            },
            state: {
              select: [{
                value: 0,
                type: 'danger',
                label: '待提交'
              }, {
                value: 1,
                type: 'success',
                label: '已提交'
              }]
            }
          },
@@ -351,7 +362,7 @@
        let edit = false
        let up = false
        let res = false
        let sub = true
        let sub = false
        let issued = true
        let approve = true
        for (var i = 0; i < power.length; i++) {
@@ -363,6 +374,9 @@
          }
          if (power[i].menuMethod == 'upReportUrl') {
            res = true
          }
          if (power[i].menuMethod == 'writeReport') {
            sub = true
          }
        }
        if (!approve) {
@@ -413,6 +427,22 @@
      },
      subIssued(){
        this.loadingIssued = true;
        this.$axios.post(this.$api.insReport.examineReport, {
                        id: this.currentInfo.id,
                isExamine: 1
          }).then(res => {
            if (res.code === 201) {
              return
            }
            this.$message.success('提交成功')
            this.refreshTable()
            this.loadingIssued = false;
            this.currentInfo = null;
            this.issuedVisible = false;
          }).catch(e => {
            this.$message.error('提交失败')
            this.loadingIssued = false;
          })
      },
      handleApprove(row){
        this.currentInfo = row;
@@ -427,14 +457,14 @@
                     cancelButtonText: "取消",
                     type: "success"
                  }).then(() => {
                     this.$axios.post(this.delUrl, {
                     this.$axios.post(this.$api.insReport.writeReport, {
                        id: row.id
                     }).then(res => {
                        if (res.code === 201) {
                           return
                        }
                        this.$message.success('提交成功')
                        this.selectList()
                        this.refreshTable()
                     }).catch(e => {
                        this.$message.error('提交失败')
                     })
@@ -445,6 +475,25 @@
          return this.$message.error('请输入原因')
        }
        this.loadingIssuedReason = true;
        this.$axios.post(this.$api.insReport.examineReport, {
                        id: this.currentInfo.id,
                isExamine: 0,
                examineTell:this.reason
          }).then(res => {
            if (res.code === 201) {
              return
            }
            this.$message.success('操作成功')
            this.refreshTable()
            this.loadingIssuedReason = false;
            this.currentInfo = null;
            this.reason = '';
            this.issuedVisible = false;
            this.issuedReasonVisible = false;
          }).catch(e => {
            this.$message.error('操作失败')
            this.loadingIssuedReason = false;
          })
      },
      handleApproveReason(){
        if(!this.reason){