Selaa lähdekoodia

04/21 14:56

111
Xiao_Mo 5 vuotta sitten
vanhempi
commit
a333cfefff

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/index.html


+ 1 - 0
dist/static/css/chunk-6a50fbf4.f6f995da.css

@@ -0,0 +1 @@
+.pagination-container[data-v-31cb099a]{background:#fff;padding:32px 16px;width:100%;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.pagination-container.hidden[data-v-31cb099a]{display:none}.newBand[data-v-6c8b7bf2]{display:inline-block;margin-right:10px}.right-code .title[data-v-6c8b7bf2]{font-size:18px;text-align:center;padding-bottom:8px}[data-v-6c8b7bf2] .studentInfo .el-dialog__body{padding-top:0;padding-bottom:0}[data-v-6c8b7bf2] .studentInfo .multiple.el-select{width:185px!important}

+ 0 - 1
dist/static/css/chunk-c05c1d5a.879d1459.css

@@ -1 +0,0 @@
-.pagination-container[data-v-31cb099a]{background:#fff;padding:32px 16px;width:100%;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.pagination-container.hidden[data-v-31cb099a]{display:none}.newBand[data-v-2bbcfc82]{display:inline-block;margin-right:10px}.right-code .title[data-v-2bbcfc82]{font-size:18px;text-align:center;padding-bottom:8px}[data-v-2bbcfc82] .studentInfo .el-dialog__body{padding-top:0;padding-bottom:0}[data-v-2bbcfc82] .studentInfo .multiple.el-select{width:185px!important}

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/app.fe70141d.js


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-6a50fbf4.dc0cd63f.js


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-c05c1d5a.cb2626b3.js


+ 53 - 33
src/views/studentManager/studentList.vue

@@ -212,6 +212,7 @@
             filterable
             filterable
             clearable
             clearable
             placeholder="请选择分部"
             placeholder="请选择分部"
+            @change="changeStudentOrgan"
           >
           >
             <el-option
             <el-option
               v-for="(item,index) in organList"
               v-for="(item,index) in organList"
@@ -249,10 +250,10 @@
             <el-option value="0" label="否"></el-option>
             <el-option value="0" label="否"></el-option>
           </el-select>
           </el-select>
         </el-form-item>
         </el-form-item>
-          <el-form-item label="指导老师" prop="teacherId">
+        <el-form-item label="指导老师" prop="teacherId">
           <el-select class="multiple" v-model.trim="studentForm.teacherId" clearable filterable>
           <el-select class="multiple" v-model.trim="studentForm.teacherId" clearable filterable>
             <el-option
             <el-option
-              v-for="(item,index) in teacherList"
+              v-for="(item,index) in maskTeacherList"
               :label="item.realName"
               :label="item.realName"
               :value="item.id"
               :value="item.id"
               :key="index"
               :key="index"
@@ -336,7 +337,7 @@ import {
   studentHasCourse
   studentHasCourse
 } from "@/api/studentManager";
 } from "@/api/studentManager";
 import { vaildStudentUrl } from "@/utils/validate";
 import { vaildStudentUrl } from "@/utils/validate";
-import { getEmployeeOrgan, resetPassword2,getTeacher } from "@/api/buildTeam";
+import { getEmployeeOrgan, resetPassword2, getTeacher } from "@/api/buildTeam";
 import QRCode from "qrcodejs2";
 import QRCode from "qrcodejs2";
 import store from "@/store";
 import store from "@/store";
 import axios from "axios";
 import axios from "axios";
@@ -360,12 +361,13 @@ export default {
         hasPracticeCourse: null,
         hasPracticeCourse: null,
         operatingTag: null,
         operatingTag: null,
         serviceTag: null,
         serviceTag: null,
-        teacherId:null
+        teacherId: null
       },
       },
       searchList: [],
       searchList: [],
       tableList: [],
       tableList: [],
       organList: [],
       organList: [],
-      teacherList:[],
+      teacherList: [],
+      maskTeacherList:[],
       pageInfo: {
       pageInfo: {
         // 分页规则
         // 分页规则
         limit: 10, // 限制显示条数
         limit: 10, // 限制显示条数
@@ -383,7 +385,7 @@ export default {
         nation: "",
         nation: "",
         serviceTag: null,
         serviceTag: null,
         operatingTag: null,
         operatingTag: null,
-        teacherId:null
+        teacherId: null
       },
       },
       studentRules: {
       studentRules: {
         name: [{ required: true, message: "请输入学生姓名" }],
         name: [{ required: true, message: "请输入学生姓名" }],
@@ -393,7 +395,7 @@ export default {
         nation: [{ required: true, message: "请输入名族" }],
         nation: [{ required: true, message: "请输入名族" }],
         serviceTag: [{ required: true, message: "请选择是否参与服务" }],
         serviceTag: [{ required: true, message: "请选择是否参与服务" }],
         operatingTag: [{ required: true, message: "请选择是否参与运营" }],
         operatingTag: [{ required: true, message: "请选择是否参与运营" }],
-        teacherId: [{ required: true, message: "请选择指导老师" }],
+        teacherId: [{ required: true, message: "请选择指导老师" }]
       },
       },
       isNew: false,
       isNew: false,
       active: null,
       active: null,
@@ -426,7 +428,7 @@ export default {
         this.organList = res.data;
         this.organList = res.data;
       }
       }
     });
     });
-      getTeacher().then(res => {
+    getTeacher().then(res => {
       if (res.code == 200) {
       if (res.code == 200) {
         this.teacherList = res.data;
         this.teacherList = res.data;
       }
       }
@@ -484,7 +486,7 @@ export default {
         hasPracticeCourse: null,
         hasPracticeCourse: null,
         operatingTag: null,
         operatingTag: null,
         serviceTag: null,
         serviceTag: null,
-        teacherId:null,
+        teacherId: null
       };
       };
     },
     },
     downLoadStudent() {
     downLoadStudent() {
@@ -501,7 +503,7 @@ export default {
           : null,
           : null,
         operatingTag: searchForm.operatingTag ? searchForm.operatingTag : null,
         operatingTag: searchForm.operatingTag ? searchForm.operatingTag : null,
         serviceTag: searchForm.serviceTag ? searchForm.serviceTag : null,
         serviceTag: searchForm.serviceTag ? searchForm.serviceTag : null,
-        teacherId:searchForm.teacherId ? searchForm.teacherId:null
+        teacherId: searchForm.teacherId ? searchForm.teacherId : null
       };
       };
       const options = {
       const options = {
         method: "POST",
         method: "POST",
@@ -592,7 +594,7 @@ export default {
             nation: this.studentForm.nation,
             nation: this.studentForm.nation,
             serviceTag: this.studentForm.serviceTag,
             serviceTag: this.studentForm.serviceTag,
             operatingTag: this.studentForm.operatingTag,
             operatingTag: this.studentForm.operatingTag,
-            teacherId:this.studentForm.teacherId
+            teacherId: this.studentForm.teacherId
           };
           };
           registerStudent(obj).then(res => {
           registerStudent(obj).then(res => {
             if (res.code == 200) {
             if (res.code == 200) {
@@ -619,7 +621,7 @@ export default {
             nation: this.studentForm.nation,
             nation: this.studentForm.nation,
             serviceTag: this.studentForm.serviceTag,
             serviceTag: this.studentForm.serviceTag,
             operatingTag: this.studentForm.operatingTag,
             operatingTag: this.studentForm.operatingTag,
-            teacherId:this.studentForm.teacherId
+            teacherId: this.studentForm.teacherId
           };
           };
           updateStudent(obj).then(res => {
           updateStudent(obj).then(res => {
             if (res.code == 200) {
             if (res.code == 200) {
@@ -632,28 +634,39 @@ export default {
       });
       });
     },
     },
     addStudent() {
     addStudent() {
-      this.isNew = true;
-      this.studentVisible = true;
-      this.maskName = "新增学员";
+      getTeacher().then(res => {
+        if (res.code == 200) {
+          this.maskTeacherList = res.data;
+          this.isNew = true;
+          this.studentVisible = true;
+          this.maskName = "新增学员";
+        }
+      });
     },
     },
     resetStudent(row) {
     resetStudent(row) {
-      this.isNew = false;
-      this.active = row;
-      this.studentVisible = true;
-      this.maskName = "修改学员";
-     
-      this.studentForm = {
-        phone: row.parentsPhone,
-        name: row.username,
-        sex: row.gender,
-        parseName: row.realName,
-        date: row.birthdate,
-        organId: row.organId,
-        nation: row.nation,
-        serviceTag: row.serviceTag+'',
-        operatingTag: row.operatingTag+'',
-        teacherId:row.teacherId
-      };
+      let organId = row.organId;
+      getTeacher({ organId }).then(res => {
+        if (res.code == 200) {
+          this.maskTeacherList = res.data;
+          this.isNew = false;
+          this.active = row;
+          this.studentVisible = true;
+          this.maskName = "修改学员";
+
+          this.studentForm = {
+            phone: row.parentsPhone,
+            name: row.username,
+            sex: row.gender,
+            parseName: row.realName,
+            date: row.birthdate,
+            organId: row.organId,
+            nation: row.nation,
+            serviceTag: row.serviceTag + "",
+            operatingTag: row.operatingTag + "",
+            teacherId: row.teacherId
+          };
+        }
+      });
     },
     },
     resetPassWrod(row) {
     resetPassWrod(row) {
       this.activatedRow = row;
       this.activatedRow = row;
@@ -691,6 +704,13 @@ export default {
           });
           });
         }
         }
       });
       });
+    },
+    changeStudentOrgan(val){
+        getTeacher({organId:val}).then(res => {
+      if (res.code == 200) {
+        this.maskTeacherList = res.data;
+      }
+    });
     }
     }
   },
   },
   watch: {
   watch: {
@@ -706,7 +726,7 @@ export default {
           nation: "",
           nation: "",
           serviceTag: null,
           serviceTag: null,
           operatingTag: null,
           operatingTag: null,
-          teacherId:null
+          teacherId: null
         };
         };
         this.$refs["studentForm"].resetFields();
         this.$refs["studentForm"].resetFields();
       }
       }

Kaikkia tiedostoja ei voida näyttää, sillä liian monta tiedostoa muuttui tässä diffissä