lrf402788946 4 年之前
父节点
当前提交
4489eb43c0
共有 3 个文件被更改,包括 7 次插入1 次删除
  1. 3 1
      src/views/newspaper/index.vue
  2. 2 0
      src/views/task/index.vue
  3. 2 0
      src/views/train-plan/experience.vue

+ 3 - 1
src/views/newspaper/index.vue

@@ -92,9 +92,11 @@ export default {
     },
     // 下载
     async download({ data }) {
+      let msg = this.$message('正在导出,请稍后....');
       const { id } = data;
       const r = await this.export({ id });
-      if (this.$checkRes(r)) {
+      msg.close();
+      if (this.$checkRes(r, '导出成功', r.errmsg || '导出失败')) {
         window.open(r.data);
       }
     },

+ 2 - 0
src/views/task/index.vue

@@ -117,8 +117,10 @@ export default {
     },
     // 导出作业
     async toExport(range) {
+      let msg = this.$message('正在导出,请稍后....');
       let data = { range };
       const res = await this.export(data);
+      msg.close();
       if (this.$checkRes(res, '导出成功', res.errmsg || '导出失败')) {
         window.open(res.data);
       }

+ 2 - 0
src/views/train-plan/experience.vue

@@ -126,7 +126,9 @@ export default {
       this.$set(this, `studentList`, arr);
     },
     async toExport(data) {
+      let msg = this.$message('正在导出,请稍后....');
       const res = await this.export(data);
+      msg.close();
       if (this.$checkRes(res, '导出成功', res.errmsg || '导出失败')) {
         window.open(res.data);
       }