licailing пре 4 година
родитељ
комит
67eed44e61
1 измењених фајлова са 16 додато и 2 уклоњено
  1. 16 2
      src/main/vue/src/views/performance/ProgrammeOrgList.vue

+ 16 - 2
src/main/vue/src/views/performance/ProgrammeOrgList.vue

@@ -139,8 +139,18 @@
                         :on-success="onSuccess"
                         class="uploader"
                         :on-error="onfail"
+                        :loading="loading"
+                        :disabled="loading"
                     >
-                        <el-button slot="trigger" type="primary" icon="el-icon-upload2" v-if="add">批量上传</el-button>
+                        <el-button
+                            slot="trigger"
+                            type="primary"
+                            icon="el-icon-upload2"
+                            v-if="add"
+                            :loading="loading"
+                            :disabled="loading"
+                            >批量上传</el-button
+                        >
                     </el-upload>
                     <el-button
                         @click="download"
@@ -347,7 +357,8 @@ export default {
                 { label: '已提交', value: 'SUBMIT' },
                 { label: '初选未通过', value: 'AUDIT_FAILED' },
                 { label: '审核未通过', value: 'REVIEW_FAILED' }
-            ]
+            ],
+            loading: false
         };
     },
     created() {
@@ -686,6 +697,7 @@ export default {
         },
         onSuccess() {
             this.$message.success('上传成功');
+            this.loading = false;
             this.getData();
         },
         beforeUpload() {
@@ -693,6 +705,8 @@ export default {
                 confirmButtonText: '确定',
                 cancelButtonText: '取消',
                 type: 'warning'
+            }).then(() => {
+                this.loading = true;
             });
         },
         canAdd() {