소스 검색

资源目录添加导出功能

maxiaoxiao 9 달 전
부모
커밋
5e86a3f717
1개의 변경된 파일8개의 추가작업 그리고 1개의 파일을 삭제
  1. 8 1
      src/views/system/zyml/index.vue

+ 8 - 1
src/views/system/zyml/index.vue

@@ -82,7 +82,7 @@
           plain
           plain
           icon="el-icon-download                                                                                                 ws"
           icon="el-icon-download                                                                                                 ws"
           size="mini"
           size="mini"
-          @click="handleAdd"
+          @click="handleExport"
           v-hasPermi="['system:zymlexport']"
           v-hasPermi="['system:zymlexport']"
           >导出</el-button
           >导出</el-button
         >
         >
@@ -622,6 +622,13 @@ export default {
     this.getList();
     this.getList();
   },
   },
   methods: {
   methods: {
+    handleExport() {
+      this.download(
+        "system/zyml/export",
+        {},
+        `zyml_${new Date().getTime()}.xlsx`
+      );
+    },
     handleRowOnEnd(evt) {
     handleRowOnEnd(evt) {
       setTimeout(() => {
       setTimeout(() => {
         // 输出移动后每行的数据及索引
         // 输出移动后每行的数据及索引