Explorar el Código

修复合同修改中的确定按钮无效

lizhenhao hace 2 años
padre
commit
8d0a2cc2a3
Se han modificado 1 ficheros con 15 adiciones y 13 borrados
  1. 15 13
      src/views/modules/cw/workContract/ContractNameForm.vue

+ 15 - 13
src/views/modules/cw/workContract/ContractNameForm.vue

@@ -886,25 +886,27 @@
           throw new Error()
         } else {
           if (status === 'save') {
-            this.$refs['inputForm'].validate(async (valid) => {
-              if (this.inputForm.filedPaperType !== '0' & this.inputForm.filedPaperType !== '') {
-                if (this.inputForm.filedNo === '' || this.inputForm.filedNo === undefined) {
-                  this.loading = false
-                  this.$message.error('请填写案卷号')
-                  throw new Error('请填写案卷号')
-                }
-                if (this.inputForm.confirmFiledNo === '' || this.inputForm.confirmFiledNo === undefined) {
-                  this.loading = false
-                  this.$message.error('请填写确认案卷号')
-                  throw new Error('请填写确认案卷号')
+            this.loading = true
+            this.$refs['inputForm'].validate((valid) => {
+              if (valid) {
+                if (this.inputForm.filedPaperType !== '0' & this.inputForm.filedPaperType !== '') {
+                  if (this.inputForm.filedNo === '' || this.inputForm.filedNo === undefined) {
+                    this.loading = false
+                    this.$message.error('请填写案卷号')
+                    throw new Error('请填写案卷号')
+                  }
+                  if (this.inputForm.confirmFiledNo === '' || this.inputForm.confirmFiledNo === undefined) {
+                    this.loading = false
+                    this.$message.error('请填写确认案卷号')
+                    throw new Error('请填写确认案卷号')
+                  }
                 }
-                this.loading = true
                 this.inputForm.status = '5'
                 this.inputForm.filedType = '5'
                 this.inputForm.contractProperList = this.$refs.uploadFile.getDataList()
                 this.inputForm.contractInfoList = this.$refs.archiveFile.getDataList()
                 this.inputForm.fees = this.inputForm.contractFees.join(',')
-                this.contractInfoService.save(this.inputForm).then(({data}) => {
+                this.contractInfoService.save(this.inputForm).then(() => {
                   this.loading = false
                   this.close()
                 }).catch(() => {