WINDOWS-7IFQK7E\EDY 2 anni fa
parent
commit
ae3153cdf9

+ 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 {

File diff suppressed because it is too large
+ 94 - 1
src/stores/user.js


+ 26 - 28
src/views/bjzzpb/bjpb/index.vue

@@ -3,12 +3,12 @@
     <el-form :inline="true">
       <el-form-item label="年级:">
         <el-select v-model="firstForm.grade" placeholder="请选择年级" clearable @change="getListData">
-          <el-option v-for="item in gradeList" :label="item.grade_name" :value="item.grade_id"></el-option>
+          <el-option v-for="item in gradeList" :label="item.grade_name" :value="item.grade_name"></el-option>
         </el-select>
       </el-form-item>
       <el-form-item label="班级:">
         <el-select v-model="firstForm.class" placeholder="请选择班级" clearable @change="getListData">
-          <el-option v-for="item in classList" :label="item.class_name" :value="item.class_id"></el-option>
+          <el-option v-for="item in classList" :label="item.class_name" :value="item.class_name"></el-option>
         </el-select>
       </el-form-item>
       <el-form-item label="优胜班级:">
@@ -20,10 +20,10 @@
         <el-date-picker v-model="firstForm.time" clearable @change="getTime" type="daterange" value-format="yyyy-MM-dd" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
         </el-date-picker>
       </el-form-item>
-      <el-form-item class="mr10" label="时间:">
+      <!-- <el-form-item class="mr10" label="时间:">
         <el-date-picker v-model="firstForm.time" clearable @change="getTime" type="daterange" value-format="yyyy-MM-dd" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
         </el-date-picker>
-      </el-form-item>
+      </el-form-item> -->
       <!-- <el-form-item prop="keyword">
         <el-input
           placeholder="请输入分值"
@@ -51,7 +51,7 @@
       <div class="small"><span class="ml-20px">优胜班级个数:</span>10{{num}}个</div>
     </div> -->
     <el-button class="" type="primary" @click="exportAll">导出</el-button>
-    <el-table :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
+    <el-table @selection-change="handleSelectionChange" :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
       <el-table-column type="selection" align="center" width="55">
       </el-table-column>
 
@@ -135,6 +135,7 @@ export default {
       },
       xdbb_id: "",
       commentDialogVisible: false,
+      multipleSelection1: [],
       rules: {
         xdbs_zp: [{ required: true, message: "请输入总评", trigger: "blur" }],
       },
@@ -161,8 +162,8 @@ export default {
       let data = {
         page: this.cur_page,
         limit: this.limit,
-        grade_id: this.firstForm.grade,
-        class_id: this.firstForm.class,
+        grade_name: this.firstForm.grade,
+        class_name: this.firstForm.class,
         xdbs_sj: this.xdbs_sj,
         xdbs_ysbj: this.xdbs_ysbj
       };
@@ -187,37 +188,27 @@ export default {
       });
     },
     gradeListData() {
+      this.loading = true;
       let data = {
-        page: 1,
-        limit: 9999,
       };
       grade_search(data).then((res) => {
-        if (res.code == 1) {
-          this.gradeList = res.data.page_data;
-          let obj = {
-            grade_id: "",
-            grade_name: "全部",
-          };
-          this.gradeList.unshift(obj);
-        }
+        this.loading = false;
+        this.gradeList = res.data.page_data;
+
       });
     },
+
     classListData() {
+      this.loading = true;
       let data = {
-        page: 1,
-        limit: 9999,
       };
       class_search(data).then((res) => {
-        if (res.code == 1) {
-          this.classList = res.data.page_data;
-          let obj = {
-            class_id: "",
-            class_name: "全部",
-          };
-          this.classList.unshift(obj);
-        }
+        this.loading = false;
+        this.classList = res.data.page_data;
+
       });
     },
+
     getTime() {
       if (!this.firstForm.time) {
         this.firstForm.time = [];
@@ -301,7 +292,14 @@ export default {
         }
       });
     },
+    handleSelectionChange(val) {
 
+      this.multipleSelection1 = [];
+      for (let i in val) {
+        this.multipleSelection1.push(val[i].xdbb_id);
+        console.log(this.multipleSelection1, 123);
+      }
+    },
     exportAll() {
       let time = "";
       if (this.firstForm.time.length > 0) {
@@ -312,7 +310,7 @@ export default {
       let link =
         window.globalVariables.api +
         "/xddy/dygl_bjzzpb_bjpfgl/index?api=xls&page=1&limit=10000&token=" +
-        token;
+        token + '&xdbb_id=' + this.multipleSelection1.join(',');
       window.open(link, "_blank");
     },
     clearData() {

+ 12 - 3
src/views/bjzzpb/cggl/index.vue

@@ -29,7 +29,7 @@
     <el-button class="mt30" type="primary" @click="addData">添加</el-button>
     <el-button class="mt30" type="primary" @click="exportAll">导出</el-button>
 
-    <el-table :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
+    <el-table @selection-change="handleSelectionChange" :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
       <el-table-column type="selection" align="center" width="55">
       </el-table-column>
 
@@ -299,7 +299,8 @@ export default {
         xdbs_cgsjdf: [{ required: true, message: "请输入实际分值", trigger: "blur" }],
       },
       tablejlData: [],
-      totalTableData: []
+      totalTableData: [],
+      multipleSelection1: [],
     };
 
   },
@@ -480,6 +481,14 @@ export default {
       this.dialogFormVisible = false;
       this.rateDialogFormVisible = false;
     },
+    handleSelectionChange(val) {
+
+      this.multipleSelection1 = [];
+      for (let i in val) {
+        this.multipleSelection1.push(val[i].xdbb_id);
+        console.log(this.multipleSelection1, 123);
+      }
+    },
     exportAll() {
       let time = "";
       if (this.firstForm.time.length > 0) {
@@ -490,7 +499,7 @@ export default {
       let link =
         window.globalVariables.api +
         "/xddy/dygl_bjzzpb_bjpfgl/index?api=xls&page=1&limit=10000&xdbs_jclx=2&token=" +
-        token;
+        token + '&xdbb_id=' + this.multipleSelection1.join(',');
       window.open(link, "_blank");
     },
     studentData() {

+ 12 - 3
src/views/bjzzpb/wsgl/index.vue

@@ -28,7 +28,7 @@
     <el-button class="mt30" type="primary" @click="addData">添加</el-button>
     <el-button class="mt30" type="primary" @click="exportAll">导出</el-button>
 
-    <el-table :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
+    <el-table @selection-change="handleSelectionChange" :data="tableData" tooltip-effect="dark" v-loading="loading" class="mt20" style="width: 100%">
       <el-table-column type="selection" align="center" width="55">
       </el-table-column>
       <el-table-column label="年级" prop="grade_name" width="150">
@@ -285,7 +285,8 @@ export default {
         xdbs_wssjdf: [{ required: true, message: "请输入实际分值", trigger: "blur" }],
       },
       tablejlData: [],
-      totalTableData: []
+      totalTableData: [],
+      multipleSelection1: [],
     };
   },
   methods: {
@@ -501,6 +502,14 @@ export default {
       this.cur_page = 1;
       this.getListData();
     },
+    handleSelectionChange(val) {
+
+      this.multipleSelection1 = [];
+      for (let i in val) {
+        this.multipleSelection1.push(val[i].xdbb_id);
+        console.log(this.multipleSelection1, 123);
+      }
+    },
     exportAll() {
       let time = "";
       if (this.firstForm.time.length > 0) {
@@ -511,7 +520,7 @@ export default {
       let link =
         window.globalVariables.api +
         "/xddy/dygl_bjzzpb_bjpfgl/index?api=xls&page=1&limit=10000&xdbs_jclx=1&token=" +
-        token;
+        token + '&xdbb_id=' + this.multipleSelection1.join(',');
       window.open(link, "_blank");
     },
     studentData() {