dedsudiyu 6 днів тому
батько
коміт
26630cf4d9

+ 11 - 0
src/views/integratedManagement/laboratoryManagement/subject/index.vue

@@ -63,6 +63,7 @@
                 <!--<el-dropdown-item :command="{command:2}">关联配置</el-dropdown-item>-->
                 <!--<el-dropdown-item :command="{command:3}">准入配置</el-dropdown-item>-->
                 <el-dropdown-item :command="{command:4}">下载二维码</el-dropdown-item>
+                <el-dropdown-item :command="{command:5}" v-hasPermiRouter="['system:subject:export']">导出</el-dropdown-item>
               </el-dropdown-menu>
             </el-dropdown>
             <el-form-item v-hasPermiRouter="['system:subject:import']" style="float: right;">
@@ -379,6 +380,7 @@
     methods: {
       //操作按钮
       commandButton(item){
+        let self = this;
         if(item.command == 1){
           this.clickPage(2);
         }else if(item.command == 2){
@@ -407,6 +409,15 @@
           }else{
             this.msgError('请勾选实验室')
           }
+        }else if(item.command == 5){
+          self.$confirm(`确认导出所有实验室数据?`, "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }).then(async () => {
+            let obj = JSON.parse(JSON.stringify(self.queryParams))
+            self.download(`/laboratory/subRelInfo/exportOut/`,{...obj}, '实验室列表-'+'.xlsx')
+          }).catch(() => {})
         }
       },
       // 页面切换