ZhaoJing преди 1 година
родител
ревизия
377565a77e
променени са 7 файла, в които са добавени 158 реда и са изтрити 27 реда
  1. 1 1
      public/config.js
  2. 114 15
      src/stores/user.js
  3. 5 1
      src/views/bjhd/hdlb/index.vue
  4. 19 7
      src/views/bjhd/hdlbgl/index.vue
  5. 9 1
      src/views/wypj/wdsz/index.vue
  6. 9 1
      src/views/wypj/wdsz/wdpfx/index.vue
  7. 1 1
      src/views/wypj/xsewm/index.vue

+ 1 - 1
public/config.js

@@ -24,7 +24,7 @@ const production = {
 
 function isWhich() {
   if (window.location.href.includes('localhost')) {
-    return local
+    return production
   } else if (window.location.href.includes('bozedu')) {
     return development
   } else {

Файловите разлики са ограничени, защото са твърде много
+ 114 - 15
src/stores/user.js


+ 5 - 1
src/views/bjhd/hdlb/index.vue

@@ -602,10 +602,14 @@ export default {
         .catch(() => {});
     },
     exportAc() {
+      let exp_arr = [];
+      for (let i in this.multipleSelection) {
+        exp_arr.push(this.multipleSelection[i].xdb_id);
+      }
       let link =
         window.globalVariables.api +
         "/xddy/dygl_bjhd/index?api=xls&page=1&limit=10000&token=" +
-        token;
+        token + '&xdb_id=' + exp_arr.join(',');
       window.open(link, "_self");
     },
     toDetail(id) {

+ 19 - 7
src/views/bjhd/hdlbgl/index.vue

@@ -11,8 +11,8 @@
       >
         <el-button type="primary">导入</el-button>
       </el-upload>
-      <el-button type="primary" @click="exportType">导入模板下载</el-button>
-      <el-button type="primary" @click="exportType">导出</el-button>
+      <el-button type="primary" @click="exportType('one')">导入模板下载</el-button>
+      <el-button type="primary" @click="exportType('mul')">导出</el-button>
       <el-button type="primary" @click="addType">添加</el-button>
       <el-button
         type="danger"
@@ -340,11 +340,23 @@ export default {
         })
         .catch(() => {});
     },
-    exportType() {
-      let link =
-        window.globalVariables.api +
-        "/xddy/dygl_bjhd_hdlbgl/index?api=xls&page=1&limit=10000&token=" +
-        token;
+    exportType(type) {
+      let link;
+      if (type == 'one') {
+         link =
+          window.globalVariables.api +
+          "/xddy/dygl_bjhd_hdlbgl/index?api=xls&page=1&limit=1&token=" +
+          token;
+      } else {
+        let exp_arr = [];
+        for (let i in this.multipleSelection) {
+          exp_arr.push(this.multipleSelection[i].xdbh_id);
+        }
+         link =
+          window.globalVariables.api +
+          "/xddy/dygl_bjhd_hdlbgl/index?api=xls&page=1&limit=10000&token=" +
+          token + '&xdbh_id=' + exp_arr.join(',');
+      }
       window.open(link, "_self");
     },
     import_success(res) {

+ 9 - 1
src/views/wypj/wdsz/index.vue

@@ -70,7 +70,7 @@
       </el-form>
       <div slot="footer" class="text-center">
         <el-button @click="formCancel">取 消</el-button>
-        <el-button type="primary" @click="formSubmit('dialogForm')"
+        <el-button :disabled="isButton" type="primary" @click="formSubmit('dialogForm')"
           >确 定</el-button
         >
       </div>
@@ -102,6 +102,7 @@ export default {
         wdmc: [{ required: true, message: "请输入维度名称", trigger: "blur" }],
       },
       multipleSelection: [],
+      isButton: false,
     };
   },
   methods: {
@@ -128,6 +129,7 @@ export default {
     },
 
     addData() {
+      this.isButton = false;
       this.title = "添加";
       this.dialogForm = {
         wdmc: "",
@@ -137,6 +139,7 @@ export default {
     },
 
     editData(item) {
+      this.isButton = false;
       this.title = "编辑信息";
       this.isEdit = true;
       this.dialogFormVisible = true;
@@ -147,6 +150,7 @@ export default {
     formSubmit(formName) {
       this.$refs[formName].validate((valid) => {
         if (valid) {
+          this.isButton = true;
           let data = {
             xdww_name: this.dialogForm.wdmc,
             xdbs_jclx: "1",
@@ -158,6 +162,7 @@ export default {
                   message: "信息添加成功!",
                   type: "success",
                 });
+                this.isButton = true;
                 this.dialogFormVisible = false;
                 this.getListData();
               } else {
@@ -187,6 +192,9 @@ export default {
             });
           }
         }
+        else {
+          this.isButton = false
+        }
       });
     },
 

+ 9 - 1
src/views/wypj/wdsz/wdpfx/index.vue

@@ -64,7 +64,7 @@
       </el-form>
       <div slot="footer" class="text-center">
         <el-button @click="formCancel">取 消</el-button>
-        <el-button type="primary" @click="formSubmit('dialogForm')"
+        <el-button :disabled="isButton" type="primary" @click="formSubmit('dialogForm')"
           >确 定</el-button
         >
       </div>
@@ -96,6 +96,7 @@ export default {
         pfx: [{ required: true, message: "请输入评分项", trigger: "blur" }],
       },
       multipleSelection: [],
+      isButton: false,
     };
   },
   methods: {
@@ -120,6 +121,7 @@ export default {
       });
     },
     addData() {
+      this.isButton = false;
       this.title = "添加";
       this.dialogForm = {
         pfx: "",
@@ -130,6 +132,7 @@ export default {
     },
 
     editData(item) {
+      this.isButton = false;
       this.title = "编辑信息";
       this.isEdit = true;
       this.dialogFormVisible = true;
@@ -141,6 +144,7 @@ export default {
     formSubmit(formName) {
       this.$refs[formName].validate((valid) => {
         if (valid) {
+          this.isButton = true;
           let data = {
             xdwwp_name: this.dialogForm.pfx,
             xdww_id: this.xdww_id,
@@ -152,6 +156,7 @@ export default {
                   message: "信息添加成功!",
                   type: "success",
                 });
+                this.isButton = true;
                 this.dialogFormVisible = false;
                 this.getListData();
               } else {
@@ -182,6 +187,9 @@ export default {
             });
           }
         }
+        else {
+          this.isButton = false
+        }
       });
     },
 

+ 1 - 1
src/views/wypj/xsewm/index.vue

@@ -223,7 +223,7 @@ export default {
           this.multipleSelection.join(",");
       }
 
-      window.open(link, "_blank");
+      window.open(link, "_self");
     },
     clearData() {
       this.firstForm.grade = "";