Просмотр исходного кода

导入之后删除前一个文件

LiFei 4 лет назад
Родитель
Сommit
ea11df3276

+ 7 - 0
src/views/hwpayment/modules/HwPaymentExportModal.vue

@@ -212,6 +212,13 @@
           console.log(info.file, info.fileList);
         }
         let fileList = info.fileList
+        //第二导入删除前一个文件
+        if(fileList.length>1){
+          const index = 0;
+          const newFileList = fileList.slice();
+          newFileList.splice(index, 1);
+          fileList=newFileList
+        }
         if (info.file.status === 'done') {
           if(info.file.response.success){
             this.type=2

+ 7 - 0
src/views/requiremanager/modules/HwRequireEnrollmentExportModal.vue

@@ -179,6 +179,13 @@
           console.log(info.file, info.fileList);
         }
         let fileList = info.fileList
+        //第二导入删除前一个文件
+        if(fileList.length>1){
+          const index = 0;
+          const newFileList = fileList.slice();
+          newFileList.splice(index, 1);
+          fileList=newFileList
+        }
         if (info.file.status === 'done') {
           if(info.file.response.success){
             this.type=2