luojun 2 лет назад
Родитель
Сommit
cefb07be31
1 измененных файлов с 18 добавлено и 4 удалено
  1. 18 4
      src/views/system/dept/extend.vue

+ 18 - 4
src/views/system/dept/extend.vue

@@ -1536,7 +1536,10 @@ export default {
     },
     /** 提交按钮 */
     submitBusinessForm() {
-      this.Businessform.certificate= this.Businessimgs[this.Businessimgs.length - 1].toString(",");
+      if(this.Businessimgs.length>1){
+        this.Businessform.certificate= this.Businessimgs[this.Businessimgs.length - 1].toString(",");
+      }
+     
       this.$refs.Businessform.validate((valid) => {
         if (valid) {
           // 表单验证通过,提交数据或执行其他操作
@@ -1636,7 +1639,11 @@ export default {
     },
     /** 提交按钮 */
     submitBankForm() {
-      this.Bankform.certificate= this.Bankimgs[this.Bankimgs.length - 1].toString(",");
+      if(this.Bankimgs.length>1){
+        this.Bankform.certificate= this.Bankimgs[this.Bankimgs.length - 1].toString(",");
+      }
+
+      
       this.$refs.Bankform.validate((valid) => {
         if (valid) {
           // 表单验证通过,提交数据或执行其他操作
@@ -1733,7 +1740,11 @@ export default {
     },
     /** 提交按钮 */
     submitdetachedForm() {
-      this.detachedform.certificate= this.detachedimgs[this.detachedimgs.length - 1].toString(",");
+      if(this.detachedimgs.length>1){
+        this.detachedform.certificate= this.detachedimgs[this.detachedimgs.length - 1].toString(",");
+      }
+
+     
       this.$refs.detachedform.validate((valid) => {
         if (valid) {
           // 表单验证通过,提交数据或执行其他操作
@@ -1831,7 +1842,10 @@ export default {
     },
     /** 提交按钮 */
     submitOrgForm() {
-      this.orgform.certificate= this.orgimgs[this.orgimgs.length - 1].toString(",");
+      if(this.orgimgs.length>1){
+        this.orgform.certificate= this.orgimgs[this.orgimgs.length - 1].toString(",");
+      }
+      
       this.$refs.orgform.validate((valid) => {
         if (valid) {
           // 表单验证通过,提交数据或执行其他操作