lsc 2 년 전
부모
커밋
9dc60ec15b

+ 25 - 5
src/components/pages/components/ganChart.vue

@@ -67,7 +67,7 @@ let options = {
         id: 2,
         label: "任务描述",
         value: "label2",
-        width: 150,
+        width: 300,
         expander: true,
         html: true,
         events: {
@@ -247,7 +247,27 @@ export default {
       immediate: true,
       deep: true,
       handler(newValue, oldValue) {
-
+        var unitJson = this.Json
+        for (var i = 0; i < unitJson.length; i++) {
+          let task = unitJson[i].chapterInfo[0].taskJson
+          for (var j = 0; j < task.length; j++) {
+            this.tasks.push({
+              id: i + '-' + j,
+              label2: '第' + (i + 1) + '阶段-'+'任务' + (j + 1) + '-' + task[j].task,
+              label: this.datedifference(task[j].time[0], task[j].time[1]) + '天',
+              start: this.getTody(task[j].time[0]),
+              end: this.getTody(task[j].time[1]),
+              percent: 85,
+              type: "task",
+              style: {
+                base: {
+                  fill: "#4a83d0",
+                  stroke: "#4a83d0",
+                },
+              },
+            })
+          }
+        }
       }
     }
   },
@@ -299,9 +319,9 @@ export default {
         let task = unitJson[i].chapterInfo[0].taskJson
         for (var j = 0; j < task.length; j++) {
           this.tasks.push({
-            id: i+'-'+j,
-            label2: '第'+(i+1)+'阶段-'+task[j].task,
-            label:this.datedifference(task[j].time[0],task[j].time[1])+'天',
+            id: i + '-' + j,
+            label2: '第' + (i + 1) + '阶段-'+'任务' + (j + 1) + '-' + task[j].task,
+            label: this.datedifference(task[j].time[0], task[j].time[1]) + '天',
             start: this.getTody(task[j].time[0]),
             end: this.getTody(task[j].time[1]),
             percent: 85,

+ 1 - 0
src/components/pages/components/proMan.vue

@@ -112,6 +112,7 @@ export default {
   width: 270px;
   margin-top: 10px;
   border-radius: 15px;
+  background: #f6f6f640;
 }
 
 .rwMidBox>div:nth-child(1) {

+ 6 - 2
src/components/pages/scourse.vue

@@ -69,7 +69,7 @@
             <div class="bottom_box">
               <div>{{ item.title }}</div>
               <div class="kc_t">
-                创建学生:{{ item.uname }}
+                创建:{{ item.uname }}
               </div>
               <div class="kc_time">
                 <span style="color: #4b4b4b">创建日期:</span>{{ item.time }}
@@ -81,6 +81,7 @@
             <div class="three_bottom">
               <!-- <div @click="jump(item.courseId)">评课</div> -->
               <div @click="get(item.courseId)">查看内容</div>
+              <div @click="getA(item.courseId)">项目进展</div>
               <div @click="goToCourse(item.courseId)">
                 修改
               </div>
@@ -147,7 +148,7 @@
           </div>
           <div class="bottom_box">
             <div>{{ item.title }}</div>
-            <div class="kc_t">创建老师:{{ item.uname }}</div>
+            <div class="kc_t">创建:{{ item.uname }}</div>
             <div class="kc_time">{{ item.time }}</div>
           </div>
           <div class="three_bottom">
@@ -298,6 +299,9 @@ export default {
     get(cid){
       window.parent.postMessage({ cid: cid, screenType: "3s" }, "*");
     },
+    getA(cid){
+      this.$router.push("/courseProgress?cid=" + cid)
+    },
     handle_remove(file, fileList) {
       var _tmp = this.fileList;
       for (var i = 0, len = _tmp.length; i < len; i++) {

+ 33 - 31
src/components/pages/student/addCourse.vue

@@ -43,19 +43,19 @@
               </div>
               <div>上传项目内容</div>
             </div>
-            <div v-if="steps == 4" class="four">
+            <!-- <div v-if="steps == 4" class="four">
               <div>
                 <img src="../../../assets/icon/five.png" alt style="width:33px" />
               </div>
               <div>项目管理</div>
-            </div>
+            </div> 
             <div v-else class="fourNo" @click="navSteps(4)">
               <div>
                 <img src="../../../assets/icon/fiveNo.png" alt style="width:33px" />
               </div>
               <div>项目管理</div>
-            </div>
-            <div v-if="steps == 5" class="four">
+            </div>-->
+            <div v-if="steps == 4" class="four">
               <div>
                 <img src="../../../assets/icon/four.png" alt />
               </div>
@@ -90,8 +90,8 @@
               <h3 class="info_title" v-if="steps == 1">项目内容填写</h3>
               <h3 class="info_title" v-if="steps == 2">请选择项目框架</h3>
               <h3 class="info_title" v-if="steps == 3">项目内容填写</h3>
-              <h3 class="info_title" v-if="steps == 4">项目管理</h3>
-              <h3 class="info_title" v-if="steps == 5">上传项目</h3>
+              <!-- <h3 class="info_title" v-if="steps == 4">项目管理</h3> -->
+              <h3 class="info_title" v-if="steps == 4">上传项目</h3>
               <el-breadcrumb separator-class="el-icon-arrow-right" style="margin-top: 15px">
                 <!-- /studentCourse -->
                 <el-breadcrumb-item :to="{
@@ -245,9 +245,9 @@
                   style="padding-bottom: 30px"
                 ></el-switch>
               </div>-->
-              <!-- <div style="width: 95%; margin: 15px auto">
+              <div style="width: 95%; margin: 15px auto">
                 <el-switch v-model="isTeacherSee" active-text="是否公开此项目" style="padding-bottom: 30px"></el-switch>
-              </div> -->
+              </div>
             </div>
             <div class="whiteBg" style="border-radius: 0; margin-top: 15px; padding-bottom: 20px" v-if="false">
               <div class="right_title">目标管理</div>
@@ -682,7 +682,7 @@
               </div>
             </div>
           </div>
-          <div class="rightBox" v-if="this.steps == 4">
+          <!-- <div class="rightBox" v-if="this.steps == 4">
             <div class="proMan">
               <div class="title"><img src="../../../assets/icon/task.png" alt />任务进展甘特图</div>
               <ganChart :Json="unitJson"></ganChart>
@@ -691,12 +691,12 @@
               <div class="title"><img src="../../../assets/icon/proMan.png" alt />负责人看板</div>
               <proMan :Json="unitJson"></proMan>
             </div>
-          </div>
+          </div> -->
           <div style="
               width: calc(100% - 20px);
               background: rgb(255, 255, 255);
               border-radius: 10px;
-            " v-if="this.steps == 5">
+            " v-if="this.steps == 4">
             <div class="basic_box_success">
               <div class="right_img">
                 <img src="../../../assets/icon/right.png" alt />
@@ -718,11 +718,11 @@
             ">
               返回项目
             </button>
-            <button class="info_btn" v-if="steps > 1 && steps != 6" @click="lastSteps">
-              {{ steps == 5 ? "返回首页" : "上一步" }}
+            <button class="info_btn" v-if="steps > 1 && steps != 5" @click="lastSteps">
+              {{ steps == 4 ? "返回首页" : "上一步" }}
             </button>
-            <button class="info_btn" v-if="steps < 5" @click="nextSteps">
-              {{ steps == 4 ? "确认上传" : "下一步" }}
+            <button class="info_btn" v-if="steps < 4" @click="nextSteps">
+              {{ steps == 3 ? "确认上传" : "下一步" }}
             </button>
           </div>
         </div>
@@ -1852,7 +1852,7 @@ export default {
       return _guid;
     },
     lastSteps() {
-      if (this.steps == 5) {
+      if (this.steps == 4) {
         this.goTo(
           this.fpath + "?userid=" +
           this.userid +
@@ -2089,14 +2089,15 @@ export default {
               }
             }
           }
-        } else if (this.steps == 4) {
-          if (this.userid != this.courseUserid) {
-            this.updateWork2();
-          } else {
-            this.updateWork();
-          }
-          this.steps++
         }
+        //  else if (this.steps == 4) {
+        //   if (this.userid != this.courseUserid) {
+        //     this.updateWork2();
+        //   } else {
+        //     this.updateWork();
+        //   }
+        //   this.steps++
+        // }
       } else {
         if (this.steps == 1) {
           if (this.courseName != "") {
@@ -2145,14 +2146,15 @@ export default {
               }
             }
           }
-        } else if (this.steps == 4) {
-          if (this.userid != this.courseUserid) {
-            this.updateWork2();
-          } else {
-            this.updateWork();
-          }
-          this.steps++
-        }
+        } 
+        // else if (this.steps == 4) {
+        //   if (this.userid != this.courseUserid) {
+        //     this.updateWork2();
+        //   } else {
+        //     this.updateWork();
+        //   }
+        //   this.steps++
+        // }
       }
       this.$refs.stepBox.scrollTop = 0;
     },

+ 8 - 4
src/components/pages/student/course.vue

@@ -69,7 +69,7 @@
             <div class="bottom_box">
               <div>{{ item.title }}</div>
               <div class="kc_t" v-if="item.isCourseType == 2 || groupA == 1">
-                负责老师:{{ item.uname }}
+                负责:{{ item.uname }}
               </div>
               <div class="kc_time">
                 <span style="color: #4b4b4b">创建日期:</span>{{ item.time }}
@@ -81,6 +81,7 @@
             <div class="three_bottom">
               <!-- <div @click="jump(item.courseId)">评课</div> -->
               <div @click="get(item.courseId)">查看内容</div>
+              <div @click="getA(item.courseId)">项目进展</div>
               <div v-if="groupA == '0'" @click="goToCourse(item.courseId)">
                 修改
               </div>
@@ -147,7 +148,7 @@
           </div>
           <div class="bottom_box">
             <div>{{ item.title }}</div>
-            <div class="kc_t">创建老师:{{ item.uname }}</div>
+            <div class="kc_t">创建:{{ item.uname }}</div>
             <div class="kc_time">{{ item.time }}</div>
           </div>
           <div class="three_bottom">
@@ -295,9 +296,12 @@ export default {
       // );
       window.parent.postMessage({ cid: cid, screenType: "2" }, "*");
     },
-    get(cid){
+    get(cid) {
       window.parent.postMessage({ cid: cid, screenType: "3s" }, "*");
     },
+    getA(cid) {
+      this.$router.push("/courseProgress?cid=" + cid)
+    },
     handle_remove(file, fileList) {
       var _tmp = this.fileList;
       for (var i = 0, len = _tmp.length; i < len; i++) {
@@ -1053,7 +1057,7 @@ export default {
 .more div {
   position: absolute;
   bottom: 0px;
-  transform: translate(-50%,100%);
+  transform: translate(-50%, 100%);
   background: #f5f4f4;
   padding: 10px 20px;
   z-index: 99;

+ 85 - 0
src/components/pages/student/courseProgress.vue

@@ -0,0 +1,85 @@
+<template>
+    <div v-loading="loading" class="box">
+        <el-button type="primary" size="small" class="returnBtn" @click="retrunA()">返回</el-button>
+        <div class="proMan">
+            <div class="title"><img src="../../../assets/icon/task.png" alt />任务进展甘特图</div>
+            <ganChart :Json="unitJson"></ganChart>
+        </div>
+        <div class="proMan">
+            <div class="title"><img src="../../../assets/icon/proMan.png" alt />负责人看板</div>
+            <proMan :Json="unitJson"></proMan>
+        </div>
+    </div>
+</template>
+
+<script>
+import proMan from "../components/proMan.vue"
+import ganChart from "../components/ganChart.vue"
+export default {
+    components: { proMan, ganChart },
+    data() {
+        return {
+            cid: this.$route.query.cid,
+            loading: false,
+            unitJson: {},
+        }
+    },
+    methods: {
+        retrunA() {
+            this.$router.go(-1)
+        },
+        getCourse() {
+            let params = {
+                cid: this.cid,
+            };
+            this.ajax
+                .get(this.$store.state.api + "select_student_course_detail", params)
+                .then((res) => {
+                    this.loading = false;
+                    this.unitJson = JSON.parse(res.data[0][0].chapters);
+                })
+                .catch((err) => {
+                    console.error(err);
+                });
+        }
+    },
+    mounted() {
+        this.loading = true;
+        this.getCourse();
+    },
+}
+</script>
+
+<style scoped>
+.returnBtn {
+    position: fixed;
+    right: 20px;
+    top: 15px;
+}
+
+.box {
+    background: #fff;
+    height: 100%;
+    width: 100%;
+    overflow: auto;
+}
+
+.proMan {
+    width: 95%;
+    margin: 0 auto;
+    padding: 20px 0 20px;
+    /* margin-top: 20px; */
+}
+
+.proMan .title {
+    margin-bottom: 10px;
+    display: flex;
+    align-items: center;
+}
+
+.proMan .title img {
+    margin-right: 5px;
+    height: 17px;
+    width: 17px;
+}
+</style>

+ 485 - 0
src/components/pages/tencent/data.vue

@@ -0,0 +1,485 @@
+<template>
+  <div
+    class="pb_content"
+    style="
+      width: 100%;
+      height: 100%;
+      display: flex;
+      align-items: center;
+      justify-content: center;
+      min-height: 640px;
+      min-width: unset;
+      margin: 0;
+    "
+  >
+    <div class="pb_content_body" style="position: relative; width: 100%">
+      <div style="width: 100%; margin: 0px auto">
+        <div class="formTop">
+          <div class="tx">
+            <img
+              :src="ruleForm.headportrait ? ruleForm.headportrait : tx"
+              alt
+            />
+          </div>
+          <!-- <div class="right">
+            <div class="name">{{ ruleForm.name }}</div>
+            <div class="rightBottom">
+              <div class="emailImg">
+                <img src="../../../assets/email.png" alt />
+              </div>
+              <div class="email">{{ ruleForm.mail }}</div>
+            </div>
+          </div> -->
+        </div>
+        <div class="data_nav">
+          <span @click="type = 1" :class="{ active: type == 1 }">我的资料</span>
+          <span @click="type = 2" :class="{ active: type == 2 }">修改密码</span>
+        </div>
+        <el-form
+          v-if="type == 1"
+          :model="ruleForm"
+          :rules="rules"
+          ref="ruleForm"
+          label-width="100px"
+          class="demo-ruleForm"
+        >
+          <!-- <el-form-item label="姓名" prop="teacherName">
+            <el-input
+              v-model="ruleForm.name"
+              style="width: 250px"
+              placeholder="请输入名字"
+            ></el-input>
+          </el-form-item>-->
+          <el-form-item label="性别">
+            <el-radio-group v-model="ruleForm.sex">
+              <el-radio label="男"></el-radio>
+              <el-radio label="女"></el-radio>
+            </el-radio-group>
+          </el-form-item>
+          <el-form-item label="昵称" prop="name">
+            <el-input
+              v-model="ruleForm.name"
+              style="width: 300px"
+              placeholder="请输入昵称"
+            ></el-input>
+          </el-form-item>
+          <!-- <el-form-item label="邮箱" prop="mail">
+            <el-input
+              v-if="ruleForm.mail == ''"
+              v-model="ruleForm.mail"
+              style="width: 300px"
+              placeholder="请输入邮箱"
+            ></el-input>
+            <el-input
+              v-else
+              disabled
+              v-model="ruleForm.mail"
+              style="width: 300px"
+              placeholder="请输入邮箱"
+            ></el-input>
+          </el-form-item> -->
+          <!-- <el-form-item label="手机号码" prop="phone">
+            <el-input
+              v-model="ruleForm.phone"
+              style="width: 300px"
+              placeholder="请输入手机号码"
+            ></el-input>
+          </el-form-item> -->
+          <el-form-item label="组织" prop="org">
+            <el-select
+              v-model="ruleForm.org"
+              clearable
+              placeholder="暂无组织"
+              disabled
+            >
+              <el-option
+                v-for="item in orgJuri"
+                :key="item.id"
+                :label="item.name"
+                :value="item.id"
+              >
+              </el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="学校" prop="sBySchool">
+            <el-select
+              v-model="ruleForm.sBySchool"
+              clearable
+              placeholder="请选择学校"
+              disabled
+            >
+              <!-- <el-option
+                v-for="item in schoolJuri"
+                :key="item.id"
+                :label="item.name"
+                :value="item.id"
+              >
+              </el-option> -->
+              <el-option :value="ruleForm.sBySchool"> </el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="身份" prop="type">
+            <el-select
+              v-model="ruleForm.type"
+              clearable
+              placeholder="请选择身份"
+              disabled
+            >
+              <el-option :value="ruleForm.type"> </el-option>
+              <!-- <el-option >学生 </el-option> -->
+            </el-select>
+          </el-form-item>
+          <el-form-item label="个人简介" prop="intro">
+            <el-input
+              v-model="ruleForm.intro"
+              type="textarea"
+              :rows="5"
+              resize="none"
+              placeholder="想说点什么..."
+              style="width: 300px"
+            ></el-input>
+          </el-form-item>
+          <el-form-item>
+            <el-button type="primary" @click="submitForm('ruleForm')"
+              >修改</el-button
+            >
+          </el-form-item>
+        </el-form>
+        <div class="password" v-if="type == 2">
+          <div class="input_box">
+            <span>原密码</span>
+            <el-input
+              class="input"
+              v-model="opassword"
+              placeholder="请输入原密码"
+            ></el-input>
+          </div>
+          <div class="input_box">
+            <span>修改密码</span>
+            <el-input
+              class="input"
+              v-model="password"
+              placeholder="请输入修改密码"
+            ></el-input>
+          </div>
+          <div class="input_box">
+            <span></span>
+            <div class="input">
+              <el-button type="primary" @click="updatePassword">修改</el-button>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    var validatePass = (rule, value, callback) => {
+      if (value == "") {
+        return;
+      }
+      var reg =
+        /^[A-Za-z\d]+([-_.][A-Za-z\d]+)*@([A-Za-z\d]+[-.])+[A-Za-z\d]{2,4}$/;
+      if (!reg.test(value)) {
+        callback(new Error("请输入正确的邮箱"));
+      } else {
+        callback();
+      }
+    };
+    var validatePass1 = (rule, value, callback) => {
+      var reg = /^1\d{10}$/;
+      if (!reg.test(value)) {
+        callback(new Error("请输入正确的手机号码"));
+      } else {
+        callback();
+      }
+    };
+    return {
+      type: 1,
+      ruleForm: {
+        name: "",
+        type: "",
+        sex: "男",
+        intro: "",
+        // mail: "",
+        phone: "",
+        sBySchool: "",
+        org: "",
+        headportrait: "",
+      },
+      opassword: "",
+      password: "",
+      tx: require("../../../assets/avatar.png"),
+      userinfo: "",
+      schoolJuri: [],
+      orgJuri: [],
+      userid: this.$route.query.userid,
+      rules: {
+        pass: [{ validator: validatePass, trigger: "blur" }],
+        name: [{ required: true, message: "请输入你的名字", trigger: "blur" }],
+        mail: [
+          {
+            required: true,
+            message: "请输入你的邮箱",
+            trigger: "blur",
+          },
+        ],
+        phone: [
+          // { required: true, message: "请输入你的手机号码", trigger: "blur" },
+
+          {
+            validator: validatePass1,
+            trigger: "blur",
+          },
+        ],
+      },
+    };
+  },
+  methods: {
+    getSchool() {
+      this.isLoading = true;
+      let params = {
+        page: this.page,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectOrg", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.schoolJuri = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    getOrg() {
+      this.isLoading = true;
+      this.ajax
+        .get(this.$store.state.api + "selectorg2", "")
+        .then((res) => {
+          this.isLoading = false;
+          this.orgJuri = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    submitForm(formName) {
+      this.$refs[formName];
+      let params = [
+        {
+          userid: this.userid,
+          username: this.ruleForm.name,
+          type: this.ruleForm.type == "老师" ? 1 : 2,
+          oid: this.ruleForm.sBySchool,
+          phone: this.ruleForm.phone,
+          intro: this.ruleForm.intro,
+          sex: this.ruleForm.sex == "男" ? "0" : "1",
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "updatePblMessage2", params)
+        .then((res) => {
+          this.$message({
+            message: "修改成功",
+            type: "success",
+          });
+          window.parent.postMessage({ close: "1" }, "*");
+          this.getUser();
+        })
+        .catch((err) => {
+          this.$message.error("修改失败");
+          console.error(err);
+        });
+    },
+    getUser() {
+      let params = { uid: this.userid };
+      this.ajax
+        .get(this.$store.state.api + "getUser", params)
+        .then((res) => {
+          this.userinfo = res.data[0][0];
+          // this.$cookies.set("userInfo", this.userinfo, -1);
+          this.$cookies.set("teacherInfo", res.data[0][0], -1);
+          this.$store.commit("update", ["userInfo", this.userinfo]);
+          console.log(res.data[0][0]);
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    getDetail() {
+      let params = { uid: this.userid };
+      this.ajax
+        .get(this.$store.state.api + "getUser", params)
+        .then((res) => {
+          if (res.data[0][0]) {
+            res.data[0][0].sex = res.data[0][0].sex ? "女" : "男";
+            this.ruleForm = res.data[0][0];
+            this.ruleForm.org = res.data[0][0].org
+              ? res.data[0][0].org.split(",")[0]
+              : "";
+            this.ruleForm.type = res.data[0][0].type == 1 ? "老师" : "学生";
+            console.log(res.data[0][0]);
+          }
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    updatePassword() {
+      if (this.password.length < 6) {
+        this.$message.error("密码长度不少于6位");
+        return;
+      }
+      let params = [
+        {
+          userid: this.userid,
+          opassword: this.opassword,
+          password: this.password,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "updatePassword", params)
+        .then((res) => {
+          if (res.data[0] && res.data[0].success == 1) {
+            this.$message.success("修改成功");
+            this.opassword = "";
+            this.password = "";
+          } else {
+            this.$message.error("修改失败,原密码不正确");
+          }
+        })
+        .catch((err) => {
+          this.$message.error("修改失败");
+          console.error(err);
+        });
+    },
+  },
+  created() {
+    this.getSchool();
+    this.getOrg();
+    this.getDetail();
+  },
+};
+</script>
+
+<style scoped>
+.formTop {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin: 20px 0;
+}
+.formTop >>> .el-form {
+  margin: 0 auto;
+}
+.tx {
+  width: 100px;
+  /* margin-right: 15px; */
+  min-width: 50px;
+  min-height: 50px;
+}
+.emailImg {
+  width: 30px;
+  margin-right: 5px;
+}
+.tx > img,
+.emailImg > img {
+  width: 100%;
+  height: 100%;
+}
+.right {
+  display: flex;
+  flex-direction: column;
+  align-items: flex-start;
+}
+.name {
+  color: #3c88dd;
+  font-size: 20px;
+  margin-bottom: 10px;
+}
+
+.email {
+  color: #acacac;
+  font-size: 18px;
+}
+.rightBottom {
+  display: flex;
+  align-items: center;
+}
+.demo-ruleForm {
+  width: 100%;
+  display: flex;
+  flex-direction: column;
+  justify-content: center;
+  align-items: center;
+  background: #fff;
+}
+/* .demo-ruleForm >>> .el-form-item__label:before {
+  content: "*";
+  color: #f56c6c;
+  margin-right: 4px;
+}
+.demo-ruleForm >>> .el-form-item__label:nth-child(3) {
+  content: "";
+} */
+.demo-ruleForm >>> .el-form-item__content {
+  width: 300px;
+}
+
+.data_nav {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  width: 100%;
+  margin: 10px 0;
+}
+
+.data_nav span {
+  box-sizing: border-box;
+  padding: 8px 5px;
+  cursor: pointer;
+  color: #444444;
+  height: 35px;
+}
+
+.data_nav span + span {
+  margin-left: 10px;
+}
+
+.data_nav .active {
+  color: #4aa3ff;
+  border-bottom: 2px solid #409eff;
+}
+
+.password {
+  height: 511px;
+  padding: 50px 0 0 0;
+  box-sizing: border-box;
+  /* display: flex;
+  justify-content: center;
+  align-items: center;
+  flex-direction: column; */
+}
+.input_box {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+.input_box span {
+  width: 100px;
+  font-size: 14px;
+  text-align: right;
+  padding: 0 12px 0 0;
+}
+.input_box .input {
+  width: 300px;
+}
+.input_box + .input_box {
+  margin-top: 20px;
+}
+</style>

+ 849 - 0
src/components/pages/tencent/school.vue

@@ -0,0 +1,849 @@
+<template>
+  <div class="pb_content" style="
+      overflow: auto;
+      margin: 0px;
+      box-sizing: border-box;
+      width: 100%;
+      height: 100%;
+    ">
+    <div>
+      <div class="pb_content_body" style="
+          background: #fff;
+          padding: 0px 25px;
+          box-sizing: border-box;
+          margin: 10px auto 0;
+        ">
+        <div class="pb_head">
+          <span>学校管理</span>
+          <!-- <span>备注:教师可以根据课程、班级条件筛选学生并查看该学生信息</span> -->
+        </div>
+        <div class="student_head">
+          <div class="student_search">
+            <el-button class="btnClassGM" size="small" type="primary" @click="dialogVisible = true" v-if="step == 0">
+              添加学校</el-button>
+          </div>
+        </div>
+      </div>
+      <div class="pb_content_body" style="margin: 0 auto 10px;">
+        <div class="student_table">
+          <el-table ref="table" :data="tableData" stripe border :header-cell-style="{
+            background: '#f1f1f1',
+            'text-align': 'center',
+          }" :cell-style="{ 'text-align': 'center' }" style="width: 100%" :height="tableHeight"
+            v-loading="isLoading">
+            <el-table-column prop="name" label="学校名称" min-width="70">
+            </el-table-column>
+            <el-table-column prop="date" label="操作" min-width="30">
+              <template slot-scope="scope">
+                <div class="pb_buttonBox">
+                  <el-button class="btnClassGM" size="mini" type="primary"
+                    @click="updateS(scope.row.id, scope.row.name)">修改</el-button>
+                  <el-button class="btnClassGM" size="mini" type="primary" @click="deleteSchool(scope.row.id)">删除
+                  </el-button>
+                </div>
+              </template>
+            </el-table-column>
+          </el-table>
+        </div>
+      </div>
+      <div class="student_page">
+        <el-pagination background layout="prev, pager, next" :page-size="10" :total="total" v-if="page"
+          @current-change="handleCurrentChange"></el-pagination>
+      </div>
+    </div>
+    <el-dialog title="添加学校" :visible.sync="dialogVisible" width="500px" :before-close="handleClose" class="dialog_diy"
+      center>
+      <div class="addBox">
+        <span class="tian1">学校名称</span>
+        <el-input v-model="schoolName" style="width: 250px; margin: 15px 0px" placeholder="请输入学校名称"></el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible = false">取 消</el-button>
+        <el-button class="btnClassGM" type="primary" @click="addSchool">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="修改学校" :visible.sync="dialogVisible1" width="500px" :before-close="handleClose" class="dialog_diy"
+      center>
+      <div class="addBox">
+        <span class="tian1">学校名称</span>
+        <el-input v-model="schoolName" style="width: 250px; margin: 15px 0px" placeholder="请输入学校名称"></el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible1 = false">取 消</el-button>
+        <el-button class="btnClassGM" type="primary" @click="updateSchool">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+  
+<script>
+export default {
+  data() {
+    return {
+      tableHeight: "500px",
+      isLoading: false,
+      formLabelWidth: "100px",
+      tableData: [],
+      tableData1: [],
+      tableData2: [],
+      fileList: [],
+      schoolName: "",
+      typeName: "",
+      bannerCourse: "",
+      sTypeName: "",
+      searchClassName: "",
+      checkBannerCourse: "",
+      noneBtnImg: false,
+      isBanner: false,
+      page: 1,
+      total: 0,
+      page1: 1,
+      total1: 0,
+      page2: 1,
+      total2: 0,
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      dialogVisible: false,
+      dialogVisible1: false,
+      dialogVisible2: false,
+      dialogVisible3: false,
+      dialogVisible4: false,
+      updateOid: "",
+      dialogVisible5: false,
+      dialogVisible6: false,
+      dialogVisible7: false,
+      step: 0,
+      pid: "",
+      imgVisible: false,
+      dialogImageUrl: "",
+      uploadLoading: false,
+      checkList: [],
+      courseList: [],
+    };
+  },
+  mounted() {
+    this.$nextTick(function () {
+      //   this.tableHeight =
+      //     window.innerHeight - this.$refs.table.$el.offsetTop;
+      //   if (this.tableHeight <= 530) {
+      //     this.tableHeight = 530;
+      //   }
+      //   // 监听窗口大小变化
+      //   let self = this;
+      //   window.onresize = function () {
+      //     self.tableHeight =
+      //       window.innerHeight - self.$refs.table.$el.offsetTop;
+      //     if (self.tableHeight <= 530) {
+      //       self.tableHeight = 530;
+      //     }
+      //   };
+    });
+  },
+  methods: {
+    goTo(path) {
+      this.$router.push(path);
+    },
+    time() {
+      if (!this.now) {
+        this.now = new Date().getTime();
+        return true;
+      } else {
+        let time = new Date().getTime();
+        if (time - this.now > 3000) {
+          this.now = time;
+          return true;
+        } else {
+          return false;
+        }
+      }
+    },
+    tableRowClassName({ row, rowIndex }) {
+      if ((rowIndex + 1) % 2 === 0) {
+        return "even_row";
+      } else {
+        return "";
+      }
+    },
+    handleClose(done) {
+      done();
+    },
+    imgChange(file, fileList) {
+      var _tmp = this.fileList;
+      this.noneBtnImg = _tmp.length >= 1;
+    },
+    handleRemove(file) {
+      var _tmp = this.fileList;
+      for (var i = 0, len = _tmp.length; i < len; i++) {
+        if (_tmp[i].uid == file.uid) {
+          _tmp.splice(i, 1);
+          break;
+        }
+        this.fileList = _tmp;
+      }
+      this.noneBtnImg = _tmp.length >= 1;
+    },
+    handlePictureCardPreview(file) {
+      this.dialogImageUrl = this.fileList[0].url;
+      this.imgVisible = true;
+    },
+    handleCurrentChange(val) {
+      this.page = val;
+      this.selectSchool();
+    },
+    handleCurrentChange1(val) {
+      this.page1 = val;
+      this.selectType();
+    },
+    handleCurrentChange2(val) {
+      this.page2 = val;
+      this.selectSType();
+    },
+    beforeUpload(data) {
+      this.$refs.upload.uploadFiles;
+      this.uploadLoading = true;
+      var file = data.file;
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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",
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read",
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true,
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function (evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function (err, data) {
+            _this.uploadLoading = false;
+            if (err) {
+              var a = _this.$refs.upload.uploadFiles;
+              a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败");
+            } else {
+              //上传成功处理
+              _this.fileList.push({
+                name: file.name,
+                url: data.Location,
+                uid: file.uid,
+              });
+              console.log(data.Location);
+              _this.imgChange();
+            }
+          });
+      }
+    },
+    addBanner() {
+      if (this.isBanner == true) {
+        this.$confirm(
+          "您已经添加过Banner了,如果您再提交将覆盖上次提交的Banner!",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning",
+          }
+        )
+          .then(() => {
+            var list = this.fileList;
+            if (list.length == 0) {
+              this.$message.error("请上传需要添加的banner");
+              return;
+            }
+            if (this.time()) {
+              let params = [
+                {
+                  p: list[0].url,
+                  url: "",
+                  uid: this.userid,
+                  oid: this.updateOid,
+                },
+              ];
+              this.ajax
+                .post(this.$store.state.api + "addBanner", params)
+                .then((res) => {
+                  this.$message({
+                    message: "添加成功",
+                    type: "success",
+                  });
+                  this.dialogVisible6 = false;
+                  this.init();
+                })
+                .catch((err) => {
+                  this.$message.error("添加失败");
+                  console.error(err);
+                });
+            }
+          })
+          .catch(() => { });
+      } else {
+        var list = this.fileList;
+        if (list.length == 0) {
+          this.$message.error("请上传需要添加的banner");
+          return;
+        }
+        if (this.time()) {
+          let params = [
+            {
+              p: list[0].url,
+              url: "",
+              uid: this.userid,
+              oid: this.updateOid,
+            },
+          ];
+          this.ajax
+            .post(this.$store.state.api + "addBanner", params)
+            .then((res) => {
+              this.$message({
+                message: "添加成功",
+                type: "success",
+              });
+              this.dialogVisible6 = false;
+              this.init();
+            })
+            .catch((err) => {
+              this.$message.error("添加失败");
+              console.error(err);
+            });
+        }
+      }
+    },
+    setBannerUrl() {
+      if (this.checkBannerCourse == "") {
+        this.$message.error("请选择作为banner链接的课程");
+        return;
+      }
+      this.bannerCourse = this.checkBannerCourse;
+      this.dialogVisible7 = false;
+    },
+    selectSchool() {
+      this.isLoading = true;
+      let params = {
+        org: this.org,
+        page: this.page,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectSchoolNameOrg", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    addSchool() {
+      let params = [
+        {
+          n: this.schoolName,
+          cuid: this.userid,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "addSchoolOrg", params)
+        .then((res) => {
+          this.$message({
+            message: "添加成功",
+            type: "success",
+          });
+          this.dialogVisible = false;
+          this.schoolName = "";
+          this.selectSchool();
+        })
+        .catch((err) => {
+          this.$message.error("添加失败");
+          console.error(err);
+        });
+    },
+    updateS(id, name) {
+      this.dialogVisible1 = true;
+      this.schoolName = name;
+      this.updateId = id;
+    },
+    updateP(id, name) {
+      this.dialogVisible3 = true;
+      this.typeName = name;
+      this.updateId = id;
+    },
+    updateSPType(id, name) {
+      this.dialogVisible5 = true;
+      this.sTypeName = name;
+      this.updateId = id;
+    },
+    updateSchool() {
+      let params = {
+        oid: this.updateId,
+        n: this.schoolName,
+      };
+      this.ajax
+        .get(this.$store.state.api + "updateSN", params)
+        .then((res) => {
+          this.$message({
+            message: "修改成功",
+            type: "success",
+          });
+          this.dialogVisible1 = false;
+          this.updateId = "";
+          this.schoolName = "";
+          this.selectSchool();
+        })
+        .catch((err) => {
+          this.$message.error("修改失败");
+          console.error(err);
+        });
+    },
+    deleteSchool(id) {
+      let params = [
+        {
+          id: id,
+        },
+      ];
+      let _this = this
+      _this
+        .$confirm("确定删除此学校吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+        .then(() => {
+          _this.ajax
+            .post(this.$store.state.api + "deleteSchoolAdmin", params)
+            .then((res) => {
+              _this.$message({
+                message: "删除成功",
+                type: "success",
+              });
+              _this.updateId = "";
+              _this.schoolName = "";
+              _this.selectSchool();
+            })
+            .catch((err) => {
+              _this.$message.error("删除成功");
+              console.error(err);
+            });
+        })
+        .catch(() => {
+          return;
+        });
+
+    },
+    selectType(id) {
+      this.tableData1 = [];
+      this.tableData2 = [];
+      this.step = 1;
+      this.updateOid = id;
+      let params = {
+        page: this.page1,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectPtype", params)
+        .then((res) => {
+          this.total1 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData1 = res.data[0];
+          this.selectBanner();
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    selectBanner() {
+      let params = {
+        oid: this.updateOid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectBannerByOid", params)
+        .then((res) => {
+          if (res.data[0].length > 0) {
+            this.isBanner = true;
+          } else {
+            this.isBanner = false;
+          }
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    selectSType(pid) {
+      this.step = 2;
+      if (pid != undefined) {
+        this.pid = pid;
+      }
+      let params = {
+        pid: pid != undefined ? pid : this.pid,
+        oid: this.updateOid,
+        page: this.page2,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectStype", params)
+        .then((res) => {
+          this.total2 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData2 = res.data[0];
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    addType() {
+      let params = {
+        n: this.typeName,
+        uid: this.userid,
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "addPtype", params)
+        .then((res) => {
+          this.$message({
+            message: "添加成功",
+            type: "success",
+          });
+          this.dialogVisible2 = false;
+          this.typeName = "";
+          this.selectType();
+        })
+        .catch((err) => {
+          this.$message.error("添加失败");
+          console.error(err);
+        });
+    },
+    updatePtype() {
+      let params = {
+        n: this.typeName,
+        tid: this.updateId,
+      };
+      this.ajax
+        .get(this.$store.state.api + "updatePtype", params)
+        .then((res) => {
+          this.$message({
+            message: "修改成功",
+            type: "success",
+          });
+          this.dialogVisible3 = false;
+          this.updateId = "";
+          this.typeName = "";
+          this.selectType();
+        })
+        .catch((err) => {
+          this.$message.error("修改失败");
+          console.error(err);
+        });
+    },
+    deletePtype(id) {
+      let params = {
+        tid: id,
+      };
+      this.ajax
+        .get(this.$store.state.api + "deletePtype", params)
+        .then((res) => {
+          this.$message({
+            message: "删除成功",
+            type: "success",
+          });
+          this.updateId = "";
+          this.typeName = "";
+          this.selectType();
+        })
+        .catch((err) => {
+          this.$message.error("删除失败");
+          console.error(err);
+        });
+    },
+    addStype() {
+      let params = {
+        n: this.sTypeName,
+        pid: this.pid,
+        uid: this.userid,
+        oid: this.updateOid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "addStype", params)
+        .then((res) => {
+          this.$message({
+            message: "添加成功",
+            type: "success",
+          });
+          this.dialogVisible4 = false;
+          this.sTypeName = "";
+          this.selectSType();
+        })
+        .catch((err) => {
+          this.$message.error("添加成功");
+          console.error(err);
+        });
+    },
+    updateStype() {
+      let params = {
+        n: this.sTypeName,
+        tid: this.updateId,
+      };
+      this.ajax
+        .get(this.$store.state.api + "updatePtype", params)
+        .then((res) => {
+          this.$message({
+            message: "修改成功",
+            type: "success",
+          });
+          this.dialogVisible5 = false;
+          this.updateId = "";
+          this.sTypeName = "";
+          this.selectSType();
+        })
+        .catch((err) => {
+          this.$message.error("修改失败");
+          console.error(err);
+        });
+    },
+    //打开添加弹窗
+    addBannerUrlPop() {
+      this.dialogVisible7 = true;
+      this.searchClassName = "";
+      this.Search();
+    },
+    init() {
+      this.searchClassName = "";
+      this.checkList = [];
+      this.courseList = [];
+      this.fileList = [];
+      this.$refs.upload ? (this.$refs.upload.uploadFiles.length = 0) : "";
+      this.noneBtnImg = false;
+      this.dialogImageUrl = "";
+      this.bannerCourse = "";
+      this.checkBannerCourse = "";
+    },
+    Search() {
+      this.checkList = [];
+      let params = { t: this.searchClassName, oid: this.updateOid };
+      this.ajax
+        .get(this.$store.state.api + "getSearchCourseByoid", params)
+        .then((res) => {
+          this.courseList = res.data[0];
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    deleteStype(id) {
+      let params = {
+        tid: id,
+      };
+      this.ajax
+        .get(this.$store.state.api + "deletePtype", params)
+        .then((res) => {
+          this.$message({
+            message: "删除成功",
+            type: "success",
+          });
+          this.updateId = "";
+          this.sTypeName = "";
+          this.selectSType();
+        })
+        .catch((err) => {
+          this.$message.error("删除失败");
+          console.error(err);
+        });
+    },
+  },
+  created() {
+    this.page = 1;
+    this.selectSchool();
+  },
+};
+</script>
+  
+<style scoped>
+.pb_head>span:nth-child(2) {
+  font-size: 16px;
+  margin-left: 80px;
+  color: #ab582f;
+}
+
+.addBox {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.tian1 {
+  /* font-size: 16px; */
+  margin-right: 10px;
+}
+
+.pb_head {
+  margin: 0 !important;
+  width: 100% !important;
+}
+
+.student_page {
+  margin: 10px 0 0 45px;
+}
+
+.disUoloadSty>>>.el-upload--picture-card {
+  display: none;
+  /* 上传按钮隐藏 */
+}
+
+.dialogBox {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.dialogBox span {
+  margin: 0 20px;
+}
+
+.student_head {
+  margin-top: 10px;
+  padding-bottom: 15px;
+  display: flex;
+  justify-content: space-between;
+}
+
+.student_search,
+.student_search1 {
+  display: flex;
+  width: 100%;
+  position: relative;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  justify-content: flex-end;
+}
+
+.student_search1 {
+  justify-content: space-between;
+}
+
+.student_table>>>.el-table--border td {
+  border-right: 0px !important;
+}
+
+.student_table>>>.el-table,
+.student_table>>>.el-table__body-wrapper {
+  height: auto !important;
+}
+
+.el-table>>>.even_row {
+  background-color: #f1f1f1 !important;
+}
+
+.dialog_diy>>>.el-dialog__header {
+  padding: 9px 20px 10px;
+  background: #32455b !important;
+}
+
+.dialog_diy>>>.el-dialog__title {
+  color: #fff;
+  font-size: 15px;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn {
+  top: 14px;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn .el-dialog__close {
+  color: #fff;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn .el-dialog__close:hover {
+  color: #fff;
+}
+
+.dialog_diy>>>.el-dialog__body,
+.dialog_diy>>>.el-dialog__footer {
+  background: #fafafa;
+}
+
+.r_diy>>>.el-dialog__footer {
+  padding: 0;
+}
+
+.a_addBox {
+  height: 570px;
+  overflow: auto;
+}
+
+.workdates {
+  height: 100%;
+  position: absolute;
+  top: 0;
+  background: #fff;
+  overflow: auto;
+  z-index: 1;
+  width: 95%;
+  left: 50%;
+  transform: translateX(-50%);
+  padding: 20px;
+  box-sizing: border-box;
+}
+
+.cancelbox {
+  position: absolute;
+  z-index: 2;
+  left: 50%;
+  width: 95%;
+  transform: translateX(-50%);
+  display: flex;
+  justify-content: flex-end;
+  padding: 0 90px 0px 0px;
+  box-sizing: border-box;
+}
+
+.cardList {
+  font-size: 14px;
+  height: 360px;
+  overflow: auto;
+}
+
+.cardList div {
+  margin-bottom: 18px;
+}
+
+.cardList div:last-child {
+  margin-bottom: 0;
+}
+
+.cardHead {
+  display: flex;
+}
+
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled).active {
+  background-color: #5c549f;
+  color: #fff !important;
+}
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled):hover {
+  color: #5c549f;
+}
+
+</style>
+  

+ 954 - 0
src/components/pages/tencent/student.vue

@@ -0,0 +1,954 @@
+<template>
+  <div class="pb_content" style="background: unset;height: 100%;overflow: auto;">
+    <div
+      class="pb_content_body"
+      style="
+        background: #fff;
+        padding: 0px 25px;
+        box-sizing: border-box;
+        margin: 10px auto 0;
+        /* border-radius: 5px; */
+      "
+    >
+      <div class="pb_head">
+        <span>我的学生列表</span>
+      </div>
+      <div class="student_head">
+        <div class="head_left">
+          <el-input v-model="sPhoneUser" class="student_input" placeholder="请输入用户名"></el-input>
+          <el-select v-model="cid" placeholder="请选择班级" class="student_input inputClass" @change="searchStudent">
+            <el-option label="所有人" value=""></el-option>
+            <el-option
+              v-for="(item, index) in classJuri"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
+          </el-select>
+          <el-button class="student_button" @click="searchStudent">查询</el-button>
+        </div>
+        <div class="head_right">
+          <el-button @click="addStudent">添加学生</el-button>
+          <el-upload
+            class="upload-demo newCss"
+            :http-request="handleChange"
+            :on-remove="handleRemove"
+            action="#"
+            :file-list="fileListUpload"
+            accept=".xlsx"
+          >
+            <el-button class="btnClassGM" size="primary" type="primary">批量添加</el-button>
+            <div slot="tip" class="el-upload__tip" style="margin-left:10px;">只能上传xlsx文件,且不超过500kb</div>
+          </el-upload>
+          <!-- <el-button @click="exportExcel">导出学生</el-button> -->
+          <div @click="getExcel">xls 上传样例</div>
+        </div>
+      </div>
+    </div>
+    <div class="pb_content_body" style="margin:0 auto">
+      <div class="student_table">
+        <el-table
+          ref="table"
+          :data="tableData"
+          border
+          :height="tableHeight"
+          :fit="true"
+          v-loading="isLoading"
+          style="width: 100%"
+          :header-cell-style="{ background: '#f1f1f1', fontSize: '17px' }"
+          :row-class-name="tableRowClassName"
+        >
+          <el-table-column label="姓名" min-width="10" align="center">
+            <template slot-scope="scope">
+              <div class="userImg">
+                <div class="tx">
+                  <img
+                    :src="
+                      scope.row.headportrait != null
+                        ? scope.row.headportrait
+                        : tx
+                    "
+                    alt
+                  />
+                </div>
+                <div
+                  style="
+                    width: 150px;
+                    text-align: left;
+                    white-space: nowrap;
+                    overflow: hidden;
+                    text-overflow: ellipsis;
+                  "
+                >{{ scope.row.name }}</div>
+              </div>
+            </template>
+          </el-table-column>
+            <el-table-column label="账号" min-width="15" align="center">
+            <template slot-scope="scope">
+              <div>{{scope.row.un ? scope.row.un : "" }}</div>
+            </template>
+          </el-table-column>
+          <!-- <el-table-column label="电话" min-width="15" align="center">
+            <template slot-scope="scope">
+              <div>{{scope.row.phonenumber ? scope.row.phonenumber : "" }}</div>
+            </template>
+          </el-table-column>
+          <el-table-column prop="studentid" label="学号" min-width="10" align="center"></el-table-column> -->
+          <!-- <el-table-column
+            prop="school"
+            label="学校"
+            min-width="30"
+            align="center"
+          >
+          </el-table-column>-->
+          <el-table-column
+            prop="classname2"
+            label="班级"
+            min-width="15"
+            align="center"
+          >
+          </el-table-column>
+          <el-table-column label="操作" width="220px">
+            <template slot-scope="scope">
+              <!-- <el-button
+                class="de_button"
+                type="primary"
+                size="small"
+                @click="deleteStudent(scope.row.userid, scope.row.state)"
+                >删除</el-button
+              >-->
+              <div class="delete" @click="deleteStudent(scope.row.userid, scope.row.state)">
+                <img src="../../../assets/remove.png" alt />
+              </div>
+            </template>
+          </el-table-column>
+        </el-table>
+      </div>
+      <div class="student_page">
+        <el-pagination
+          background
+          layout="prev, pager, next"
+          :page-size="10"
+          :total="total"
+          v-if="page"
+          @current-change="handleCurrentChange"
+        ></el-pagination>
+      </div>
+    </div>
+    <el-dialog
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="700px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <div slot="title" class="header-title">
+        <div class="logoImg">
+          <img src="../../../assets/logo.png" alt />
+        </div>
+        <div class="title_add_student">添加学生</div>
+      </div>
+      <el-form class="inputClass">
+        <el-form-item label="学生名称" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入学生昵称" clearable v-model="sName" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="学生学号" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入学生学号" clearable v-model="sId" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="学生手机号" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入学生手机号" clearable v-model="sPhone" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="学生邮箱" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入学生邮箱" clearable v-model="sMail" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="所属学校" :label-width="formLabelWidth">
+          <el-input disabled style="width: 300px" v-model="schoolName"></el-input>
+        </el-form-item>
+        <el-form-item label="班级" :label-width="formLabelWidth">
+          <el-select v-model="sByClass" placeholder="请选择班级">
+            <el-option
+              v-for="(item, index) in classJuri"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <div style="text-align: center; color: #adb3b7">注:添加学生的账号密码为123456</div>
+      </el-form>
+      <span slot="footer" class="dialog-footer flex">
+        <el-button class="right" @click="insertStudent">确认</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import $ from "jquery";
+import pinyin from "../../../../node_modules/js-pinyin/index";
+export default {
+  data() {
+    return {
+      tableHeight: "500px",
+      isLoading: false,
+      formLabelWidth: "100px",
+      tableData: [],
+      dialogVisible: false,
+      sName: "",
+      sPhone: "",
+      sId: "",
+      schoolName: "",
+      // sBySchool: [],
+      // sBySchoolName:"",
+      sByClass: "",
+      sMail: "",
+      schoolJuri: [],
+      classJuri: [],
+      fileListUpload: [],
+      page: 1,
+      total: 0,
+      sPhoneUser: "",
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      cid: '',
+      tx: require("../../../assets/avatar.png"),
+    };
+  },
+  mounted() {
+    this.$nextTick(function () {
+      this.tableHeight =
+        window.innerHeight - this.$refs.table.$el.offsetTop - 200;
+      if (this.tableHeight <= 530) {
+        this.tableHeight = 530;
+      }
+      // 监听窗口大小变化
+      let self = this;
+      window.onresize = function () {
+        self.tableHeight =
+          window.innerHeight - self.$refs.table.$el.offsetTop - 200;
+        if (self.tableHeight <= 530) {
+          self.tableHeight = 530;
+        }
+      };
+    });
+  },
+  methods: {
+    tableRowClassName({ row, rowIndex }) {
+      if ((rowIndex + 1) % 2 === 0) {
+        return "even_row";
+      } else {
+        return "";
+      }
+    },
+    searchStudent() {
+      this.page = 1;
+      this.getStudent();
+    },
+    addStudent() {
+      this.dialogVisible = true;
+      (this.sName = ""), (this.sPhone = ""), (this.sByClass = "");
+      this.getClass();
+      // this.getSchool();
+    },
+    handleClose(done) {
+      done();
+    },
+    getExcel(res) {
+      require.ensure([], () => {
+        const { export_json_to_excel } = require("../../../common/Export2Excel");
+        const tHeader = ["学号", "学生姓名", "学生邮箱", "学生手机号", "班级"];
+        const data = [];
+        export_json_to_excel(tHeader, data, "上传学生样例");
+      });
+    },
+    handleCurrentChange(val) {
+      this.page = val;
+      this.getStudent();
+    },
+    time() {
+      if (!this.now) {
+        this.now = new Date().getTime();
+        return true;
+      } else {
+        let time = new Date().getTime();
+        if (time - this.now > 3000) {
+          this.now = time;
+          return true;
+        } else {
+          return false;
+        }
+      }
+    },
+    //新增学生
+    insertStudent() {
+      this.dialogVisible = true;
+      if (this.sName === "") {
+        this.$message.error("学生昵称不能为空");
+        return;
+      }  else if (this.sByClass === "") {
+        this.$message.error("请为学生选择班级");
+        return;
+      } else if (this.sPhone != "" && !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.sPhone)) {
+        this.$message.error("手机号格式不正确");
+        return;
+      } else if (
+        !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
+      ) {
+        this.$message.error("邮箱格式不正确");
+        return;
+      }
+
+      // else if (this.sId === "") {
+      //   this.$message.error("学生学号不能为空");
+      //   return;
+      // } else if (this.sPhone === "") {
+      //   this.$message.error("学生手机号不能为空");
+      //   return;
+      // }
+      if (this.time()) {
+        // let params = { un: this.sPhone };
+        // this.ajax
+        //   .get(this.$store.state.api + "findPhone", params)
+        //   .then((res) => {
+        //     if (res.data[0].length > 0) {
+        //       this.$message.error("此学生手机号码已被注册");
+        //     } else {
+              let params = { un: this.sMail };
+              this.ajax
+                .get(this.$store.state.api + "findMail", params)
+                .then((res) => {
+                  if (res.data[0].length > 0) {
+                    this.$message.error("此学生邮箱已被注册");
+                  } else {
+                    // let params = { un: this.sId };
+                    // this.ajax
+                    //   .get(this.$store.state.api + "findSid", params)
+                    //   .then((res) => {
+                        // if (res.data[0].length > 0) {
+                        //   this.$message.error("此学生学号已被注册");
+                        // } else {
+                          this.add_Student();
+                        // }
+                      // })
+                      // .catch((err) => {
+                      //   console.error(err);
+                      // });
+                  }
+                })
+                .catch((err) => {
+                  console.error(err);
+                });
+            // }
+          // })
+          // .catch((err) => {
+          //   console.error(err);
+          // });
+      }
+    },
+    add_Student() {
+      let params = [
+        {
+          username: this.sMail,
+          userpassword: 123456,
+          alias: this.sName,
+          oid: this.oid,
+          ph: this.sPhone,
+          sid: this.sId,
+          cid: this.sByClass,
+          org: this.org,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "batchRegistrationOrg", params)
+        .then((res) => {
+          // console.log(res.data.uid, res.data.ph, res.data.oid, res.data.cid);
+          // this.isLoading = false;
+
+          let params = [
+            {
+              userid: res.data.uid,
+              username: this.sName,
+              sid: this.sId,
+              type: 2,
+              oid: res.data.oid,
+              phone: res.data.ph,
+              cid: res.data.cid,
+              intro: "",
+              sex: "0",
+            },
+          ];
+          this.ajax
+            // .post(this.$store.state.api + "updateUser", params)
+            .post(this.$store.state.api + "updateUserByEdu", params)
+            .then((res) => {
+              console.log(res);
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+          this.$message({
+            message: "新增成功",
+            type: "success",
+          });
+          this.dialogVisible = false;
+          this.sPhone = "";
+          this.sName = "";
+          // this.sBySchool = [];
+          this.sByClass = [];
+          this.sMail = "";
+          this.getStudent();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          this.$message({
+            message: "新增失败",
+            type: "error",
+          });
+          console.error(err);
+        });
+    },
+    //获取班级列表
+    getClass() {
+      this.isLoading = true;
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectClassBySchool", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.classJuri = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    // getSchool() {
+    // 	this.isLoading = true;
+    // 	let params = {
+    // 		page: this.page,
+    // 	};
+    // 	this.ajax
+    // 		.get(this.$store.state.api + "selectOrg", params)
+    // 		.then((res) => {
+    // 			this.isLoading = false;
+    // 			this.schoolJuri = res.data[0];
+    // 		})
+    // 		.catch((err) => {
+    // 			this.isLoading = false;
+    // 			console.error(err);
+    // 		});
+    // },
+    getStudent() {
+      this.isLoading = true;
+      let params = {
+        oid: this.oid,
+        cid: this.cid,
+        cu: "",
+        cn: this.sPhoneUser,
+        page: this.page,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectStudent2", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    handleChange(file) {
+      this.fileTemp = file.file;
+      if (this.fileTemp) {
+        if (
+          this.fileTemp.type ==
+            "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" ||
+          this.fileTemp.type == "application/vnd.ms-excel"
+        ) {
+          this.importCount = 1;
+          this.importfxx(this.fileTemp);
+        } else {
+          this.$message({
+            type: "warning",
+            message: "附件格式错误,请删除后重新上传!",
+          });
+        }
+      } else {
+        this.$message({
+          type: "warning",
+          message: "请上传附件!",
+        });
+      }
+    },
+    handleRemove(file, fileList) {
+      this.fileTemp = null;
+    },
+    exportExcel() {
+      try {
+        let params = {
+          oid: this.oid,
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectUserBySchool", params)
+          .then((res) => {
+            var res = res.data[0];
+            //如果value的json字段的key值和想要的headers值不一致时,可做如下更改
+            //将和下面的Object.fromEntries结合,将json字段的key值改变为要求的excel的header值
+            var array = [];
+            for (var i = 0; i < res.length; i++) {
+              var _json = {};
+              _json["用户名"] = res[i].username;
+              _json["姓名"] = res[i].alias ? res[i].alias : "";
+              _json["班级"] = res[i].classid ? res[i].classid : "";
+              array.push(_json);
+            }
+
+            var XLSX = require("xlsx");
+            const workbook = XLSX.utils.book_new(); //创建一个新的工作簿对象
+            let ws = XLSX.utils.json_to_sheet(array); //将json对象数组转化成工作表
+            ws["!cols"] = [
+              //设置每一列的宽度
+              { wch: 50 },
+              { wch: 50 },
+              { wch: 50 },
+            ];
+            XLSX.utils.book_append_sheet(workbook, ws, "sheet1"); //把sheet添加到workbook里,第三个参数是sheet名
+            XLSX.writeFile(workbook, "学生信息.xlsx");
+            // const wopts = { bookType: "xlsx", bookSST: false, type: "array" };//写入的样式bookType:输出的文件类型,type:输出的数据类型,bookSST: 是否生成Shared String Table,官方解释是,如果开启生成速度会下降,但在低版本IOS设备上有更好的兼容性
+            // const wbout = XLSX.write(workbook, wopts);// 浏览器端和node共有的API,实际上node可以直接使用xlsx.writeFile来写入文件,但是浏览器没有该API
+            // FileSaver.saveAs(new Blob([wbout], { type: "application/octet-stream" }), `${title} demo.xlsx`);//保存文件
+            this.$message({
+              message: "导出成功",
+              type: "success",
+            });
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      } catch (e) {
+        console.log(e, e.stack);
+      }
+    },
+    importfxx(obj) {
+      const loading = this.$loading.service({
+        background: "rgba(255, 255, 255, 0.7)",
+        target: document.body,
+      });
+      var _$ = $;
+      this.importCount++;
+      let _this = this;
+      // 通过DOM取文件数据
+      this.file = obj;
+      var rABS = false; //是否将文件读取为二进制字符串
+      var f = this.file;
+      var reader = new FileReader();
+      //if (!FileReader.prototype.readAsBinaryString) {
+      FileReader.prototype.readAsBinaryString = function (f) {
+        var binary = "";
+        var rABS = false; //是否将文件读取为二进制字符串
+        var pt = this;
+        var wb; //读取完成的数据
+        var outdata;
+        var reader = new FileReader();
+        reader.onload = function (e) {
+          var bytes = new Uint8Array(reader.result);
+          var length = bytes.byteLength;
+          for (var i = 0; i < length; i++) {
+            binary += String.fromCharCode(bytes[i]);
+          }
+          var XLSX = require("xlsx");
+          if (rABS) {
+            wb = XLSX.read(btoa(fixdata(binary)), {
+              //手动转化
+              type: "base64",
+            });
+          } else {
+            wb = XLSX.read(binary, {
+              type: "binary",
+            });
+          }
+          outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]]); //outdata就是你想要的东西
+          this.da = [...outdata];
+          let arr = [];
+          this.da.map((v) => {
+            let obj = {};
+            let a = "";
+            var num = "";
+            // for (var cj = 0; cj < 3; cj++) {
+            //   num += Math.floor(Math.random() * 10);
+            // }
+            // a =
+            //   pinyin.getFullChars(v["学生姓名"]).toLowerCase() +
+            //   num +
+            //   "@cocorobo.cc";
+            obj.sId = v["学号"];
+            obj.name = v["学生姓名"];
+            obj.mail = v["学生邮箱"];
+            obj.phone = v["学生手机号"];
+            obj.class = v["班级"];
+            arr.push(obj);
+          });
+          console.log(arr);
+          let _b = 1;
+          for (var i = 0; i < arr.length; i++) {
+            let item = arr[i];
+            if (item.class === "") {
+              _b = 1;
+              _this.$message.error("学生班级不能为空,请重新上传");
+              break;
+            } else if (item.name === "") {
+              _b = 1;
+              _this.$message.error("学生姓名不能为空,请重新上传");
+              break;
+            } else if (item.sId === "") {
+              _b = 1;
+              _this.$message.error("学生学号不能为空,请重新上传");
+            }else if (item.mail === "") {
+              _b = 1;
+              _this.$message.error("学生邮箱不能为空,请重新上传");
+              break;
+            } else if (
+              !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
+                item.mail
+              )
+            ) {
+              _b = 1;
+              _this.$message.error("有学生邮箱格式不正确,请重新上传");
+              break;
+            }
+          }
+          let z = 2;
+          let newArr = JSON.stringify(arr);
+          let params = [
+            {
+              arr: newArr,
+              userpassword: 123456,
+              oid: _this.oid,
+              org: _this.org,
+            },
+          ];
+          _this.ajax
+            .post(_this.$store.state.api + "batchRegistrationMoreOrg", params)
+            .then((res) => {
+              if (res.data.type == 1) {
+                _this.$message.error("有学生手机号码已被注册");
+                z = 1;
+              }
+              if (res.data.type == 2) {
+                _this.$message.error("有学生邮箱已被注册");
+                z = 1;
+              }
+              if (res.data.type == 3) {
+                _this.$message.error("有学生学号重复");
+                z = 1;
+              }
+              if (z == 2) {
+                _this.$message({
+                  message: "新增成功",
+                  type: "success",
+                });
+                _this.getStudent();
+              }
+              loading.close();
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+          _this.fileListUpload = [];
+        };
+
+        reader.readAsArrayBuffer(f);
+      };
+
+      if (rABS) {
+        reader.readAsArrayBuffer(f);
+      } else {
+        reader.readAsBinaryString(f);
+      }
+    },
+    getSchoolName() {
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectSchoolName2", params)
+        .then((res) => {
+          this.schoolName = res.data[0][0].name;
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    deleteStudent(id, state) {
+      state = 0;
+      let params = [{ uid: id, state: state }];
+      this.$confirm("确定" + "删除" + "此学生吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.ajax
+            .post(this.$store.state.api + "deleteStudent", params)
+            .then((res) => {
+              this.$message({
+                message: "操作成功",
+                type: "success",
+              });
+              this.getStudent();
+            })
+            .catch((err) => {
+              this.$message.error("操作失败");
+              console.error(err);
+            });
+        })
+        .catch(() => {});
+    },
+  },
+  created() {
+    this.page = 1;
+    this.getStudent();
+    this.getSchoolName();
+    this.getClass();
+  },
+};
+</script>
+
+<style scoped>
+.pb_head > span:nth-child(2) {
+  font-size: 20px;
+  margin-left: 5px;
+  color: #828282;
+}
+.pb_head {
+  margin: 0 !important;
+  width: 100% !important;
+}
+.student_page {
+  margin-top: 10px;
+}
+.student_head {
+  margin-top: 10px;
+  padding-bottom: 10px;
+  display: flex;
+  justify-content: space-between;
+}
+.head_left {
+  display: flex;
+  align-items: center;
+}
+.head_right {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: baseline;
+}
+.student_input >>> .el-input__inner {
+  height: 30px;
+  width: 190px;
+  font-size: 13px;
+  padding: 0 10px;
+}
+.student_button {
+  color: #fff;
+  background: #8681b7;
+  border-color: #8681b7;
+  width: 60px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > button:nth-child(1) {
+  color: #fff;
+  background: #8681b7;
+  border-color: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > button:nth-child(2) {
+  color: #fff;
+  background: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > div {
+  font-size: 12px;
+  line-height: 40px;
+  margin-left: 10px;
+  color: #2a6dbe;
+  text-decoration: underline;
+  cursor: pointer;
+}
+.student_table >>> .el-table--border td {
+  border-right: 0px !important;
+}
+.student_table >>> .el-table,.student_table >>> .el-table__body-wrapper{
+  height: auto !important;
+}
+.el-table >>> .even_row {
+  background-color: #f1f1f1 !important;
+}
+.de_button {
+  color: #fff;
+  background: #5190fd;
+  width: 50px;
+  height: 25px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 25px;
+}
+.add_student >>> .el-dialog__header {
+  padding: 20px 20px 10px;
+  text-align: center;
+  background: #454545;
+}
+.add_student >>> .el-dialog__title {
+  font-size: 14px !important;
+  color: #fff !important;
+}
+.add_student >>> .el-dialog__headerbtn {
+  font-size: 20px !important;
+}
+.add_student >>> .el-form-item__label {
+  margin-left: 65px;
+}
+.add_student >>> .el-form-item {
+  display: flex;
+}
+.add_student >>> .el-form-item__content {
+  margin: 0 !important;
+}
+.add_input {
+  width: 365px;
+}
+.add_student >>> .el-dialog__footer {
+  text-align: center !important;
+}
+.right {
+  width: 250px;
+  color: #fff;
+  background: #8681b7;
+  margin-bottom: 20px;
+}
+.header-title {
+  display: flex;
+}
+.logoImg {
+  width: 30px;
+}
+.logoImg > img {
+  width: 100%;
+  height: 100%;
+}
+.title_add_student {
+  margin: 0 auto;
+  color: #fff;
+}
+.upload-demo {
+  line-height: 0px !important;
+}
+.upload-demo >>> .el-button {
+  color: #fff;
+  background: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 0 !important;
+}
+
+.userImg {
+  display: flex;
+  flex-direction: row;
+  justify-content: center;
+  align-items: center;
+}
+
+.tx {
+  width: 40px;
+  margin-right: 10px;
+}
+
+.delete {
+  width: 25px;
+  cursor: pointer;
+}
+
+.tx > img,
+.delete > img {
+  width: 100%;
+  height: 100%;
+}
+
+.newCss {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: baseline;
+}
+
+
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled).active {
+  background-color: #5c549f;
+  color: #fff !important;
+}
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled):hover {
+  color: #5c549f;
+}
+
+
+
+.el-select-dropdown__item.selected {
+  color: #5c549f;
+}
+
+.inputClass.is-active >>> .el-input__inner,
+.inputClass  >>> .el-input__inner:focus {
+  border-color: #5c549f;
+}
+
+.inputClass >>> .el-select .el-input.is-focus .el-input__inner {
+  border-color: #5c549f;
+}
+.inputClass >>> .el-select .el-input__inner:focus {
+  border-color: #5c549f;
+}
+
+.student_input.el-input{
+  width: auto; 
+}
+
+.student_input{
+  margin-right: 10px;
+}
+
+.student_input >>> .el-input__icon{
+  line-height: unset;
+}
+</style>

+ 891 - 0
src/components/pages/tencent/teacher.vue

@@ -0,0 +1,891 @@
+<template>
+  <div
+    class="pb_content"
+    style="background: unset; height: 100%; overflow: auto"
+  >
+    <div
+      class="pb_content_body"
+      style="
+        background: #fff;
+        padding: 0px 25px;
+        box-sizing: border-box;
+        margin: 10px auto 0;
+        /* border-radius: 5px; */
+      "
+    >
+      <div class="pb_head">
+        <span>教师管理</span>
+      </div>
+      <div class="student_head">
+        <div class="head_left">
+          <el-input
+            v-model="sPhoneUser"
+            class="student_input"
+            placeholder="请输入用户名"
+          ></el-input>
+          <el-select
+            v-model="cid"
+            placeholder="请选择学校"
+            class="student_input inputClass"
+            @change="searchStudent"
+          >
+            <el-option label="所有学校" value=""></el-option>
+            <el-option
+              v-for="(item, index) in classJuri"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
+          </el-select>
+          <el-button class="student_button" @click="searchStudent"
+            >查询</el-button
+          >
+        </div>
+        <div class="head_right">
+          <el-button @click="addStudent">添加教师</el-button>
+          <el-upload
+            class="upload-demo newCss"
+            :http-request="handleChange"
+            :on-remove="handleRemove"
+            action="#"
+            :file-list="fileListUpload"
+            accept=".xlsx"
+          >
+            <el-button class="btnClassGM" size="primary" type="primary"
+              >批量添加</el-button
+            >
+            <div slot="tip" class="el-upload__tip" style="margin-left: 10px">
+              只能上传xlsx文件,且不超过500kb
+            </div>
+          </el-upload>
+          <!-- <el-button @click="exportExcel">导出学生</el-button> -->
+          <div @click="getExcel">xls 上传样例</div>
+        </div>
+      </div>
+    </div>
+    <div class="pb_content_body" style="margin: 0 auto">
+      <div class="student_table">
+        <el-table
+          ref="table"
+          :data="tableData"
+          border
+          :height="tableHeight"
+          :fit="true"
+          v-loading="isLoading"
+          style="width: 100%"
+          :header-cell-style="{ background: '#f1f1f1', fontSize: '17px' }"
+          :row-class-name="tableRowClassName"
+        >
+          <el-table-column label="姓名" min-width="10" align="center">
+            <template slot-scope="scope">
+              <div class="userImg">
+                <div class="tx">
+                  <img
+                    :src="
+                      scope.row.headportrait != null
+                        ? scope.row.headportrait
+                        : tx
+                    "
+                    alt
+                  />
+                </div>
+                <div
+                  style="
+                    width: 150px;
+                    text-align: left;
+                    white-space: nowrap;
+                    overflow: hidden;
+                    text-overflow: ellipsis;
+                  "
+                >
+                  {{ scope.row.name }}
+                </div>
+              </div>
+            </template>
+          </el-table-column>
+          <el-table-column label="邮箱" min-width="15" align="center">
+            <template slot-scope="scope">
+              <div>{{ scope.row.un ? scope.row.un : "" }}</div>
+            </template>
+          </el-table-column>
+          <el-table-column
+            prop="schoolName"
+            label="学校"
+            min-width="15"
+            align="center"
+          >
+          </el-table-column>
+          <el-table-column label="操作" width="220px">
+            <template slot-scope="scope">
+              <div
+                class="delete"
+                @click="deleteStudent(scope.row.userid, scope.row.state)"
+              >
+                <img src="../../../assets/remove.png" alt />
+              </div>
+            </template>
+          </el-table-column>
+        </el-table>
+      </div>
+      <div class="student_page">
+        <el-pagination
+          background
+          layout="prev, pager, next"
+          :page-size="10"
+          :total="total"
+          v-if="page"
+          @current-change="handleCurrentChange"
+        ></el-pagination>
+      </div>
+    </div>
+    <el-dialog
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="700px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <div slot="title" class="header-title">
+        <div class="logoImg">
+          <img src="../../../assets/logo.png" alt />
+        </div>
+        <div class="title_add_student">添加教师</div>
+      </div>
+      <el-form class="inputClass">
+        <el-form-item label="教师名称" :label-width="formLabelWidth">
+          <span>
+            <el-input
+              placeholder="请输入教师昵称"
+              clearable
+              v-model="sName"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="教师邮箱" :label-width="formLabelWidth">
+          <span>
+            <el-input
+              placeholder="请输入教师邮箱"
+              clearable
+              v-model="sMail"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="所属学校" :label-width="formLabelWidth">
+          <el-select
+            v-model="schoolName"
+            placeholder="请选择学校"
+            @change="checkEva"
+          >
+            <el-option
+              v-for="(item, index) in classJuri"
+              :key="index"
+              :label="item.name"
+              :value="item.id"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <div style="text-align: center; color: #adb3b7">
+          注:添加教师的账号密码为123456
+        </div>
+      </el-form>
+      <span slot="footer" class="dialog-footer flex">
+        <el-button class="right" @click="insertStudent">确认</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import $ from "jquery";
+import pinyin from "../../../../node_modules/js-pinyin/index";
+export default {
+  data() {
+    return {
+      tableHeight: "500px",
+      isLoading: false,
+      formLabelWidth: "100px",
+      tableData: [],
+      dialogVisible: false,
+      sName: "",
+      sMail: "",
+      sId: "",
+      schoolName: "",
+      schoolJuri: [],
+      classJuri: [],
+      fileListUpload: [],
+      page: 1,
+      total: 0,
+      sPhoneUser: "",
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      cid: '',
+      org: this.$route.query.org,
+      tx: require("../../../assets/avatar.png"),
+    };
+  },
+  mounted() {
+    this.$nextTick(function () {
+      this.tableHeight =
+        window.innerHeight - this.$refs.table.$el.offsetTop - 200;
+      if (this.tableHeight <= 530) {
+        this.tableHeight = 530;
+      }
+      // 监听窗口大小变化
+      let self = this;
+      window.onresize = function () {
+        self.tableHeight =
+          window.innerHeight - self.$refs.table.$el.offsetTop - 200;
+        if (self.tableHeight <= 530) {
+          self.tableHeight = 530;
+        }
+      };
+    });
+  },
+  methods: {
+    tableRowClassName({ row, rowIndex }) {
+      if ((rowIndex + 1) % 2 === 0) {
+        return "even_row";
+      } else {
+        return "";
+      }
+    },
+    searchStudent() {
+      this.page = 1;
+      this.getStudent();
+    },
+    addStudent() {
+      this.dialogVisible = true;
+      (this.sName = ""), (this.sMail = ""), (this.schoolName = "");
+      this.getClass();
+      // this.getSchool();
+    },
+    handleClose(done) {
+      done();
+    },
+    getExcel(res) {
+      require.ensure([], () => {
+        const {
+          export_json_to_excel,
+        } = require("../../../common/Export2Excel");
+        const tHeader = ["教师姓名", "教师邮箱", "学校"];
+        const data = [];
+        export_json_to_excel(tHeader, data, "上传教师样例");
+      });
+    },
+    handleCurrentChange(val) {
+      this.page = val;
+      this.getStudent();
+    },
+    time() {
+      if (!this.now) {
+        this.now = new Date().getTime();
+        return true;
+      } else {
+        let time = new Date().getTime();
+        if (time - this.now > 3000) {
+          this.now = time;
+          return true;
+        } else {
+          return false;
+        }
+      }
+    },
+    //新增学生
+    insertStudent() {
+      this.dialogVisible = true;
+      if (this.sName === "") {
+        this.$message.error("教师昵称不能为空");
+        return;
+      } else if (this.sMail === "") {
+        this.$message.error("教师邮箱不能为空");
+        return;
+      } else if (
+        !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
+      ) {
+        this.$message.error("邮箱格式不正确");
+        return;
+      }else if(this.schoolName === ""){
+        this.$message.error("请选择学校");
+        return;
+      }
+      if (this.time()) {
+        let params = { un: this.sMail };
+        this.ajax
+          .get(this.$store.state.api + "findMail", params)
+          .then((res) => {
+            if (res.data[0].length > 0) {
+              this.$message.error("此邮箱已被注册");
+            } else {
+              this.add_Student();
+            }
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      }
+    },
+    add_Student() {
+      let params = [
+        {
+          username: this.sMail,
+          userpassword: 123456,
+          alias: this.sName,
+          org:this.org,
+          oid: this.schoolName,
+          ph: this.sPhone,
+          sid: this.sId,
+          cid: '',
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "batchRegistration1", params)
+        .then((res) => {
+          // debugger;
+          let params = [
+            {
+              userid: res.data.uid,
+              username: this.sName,
+              sid: this.sId,
+              type: 1,
+              org:this.org,
+              oid: res.data.oid,
+              phone: res.data.ph,
+              cid: '',
+              intro: "",
+              sex: "0",
+            },
+          ];
+          this.ajax
+            .post(this.$store.state.api + "updateUserByEdu1", params)
+            .then((res) => {
+              console.log(res);
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+          this.$message({
+            message: "新增成功",
+            type: "success",
+          });
+          this.dialogVisible = false;
+          this.sName = "";
+          this.sMail = "";
+          this.schoolName = "";
+          this.getStudent();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          this.$message({
+            message: "新增失败",
+            type: "error",
+          });
+          console.error(err);
+        });
+    },
+    //获取班级列表
+    getClass() {
+      this.isLoading = true;
+      let params = {
+        org: this.org,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectSchoolByOrg", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.classJuri = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    // getSchool() {
+    // 	this.isLoading = true;
+    // 	let params = {
+    // 		page: this.page,
+    // 	};
+    // 	this.ajax
+    // 		.get(this.$store.state.api + "selectOrg", params)
+    // 		.then((res) => {
+    // 			this.isLoading = false;
+    // 			this.schoolJuri = res.data[0];
+    // 		})
+    // 		.catch((err) => {
+    // 			this.isLoading = false;
+    // 			console.error(err);
+    // 		});
+    // },
+    getStudent() {
+      this.isLoading = true;
+      let params = {
+        org: this.org,
+        cu: this.cid,
+        cn: this.sPhoneUser,
+        page: this.page,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacher", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    handleChange(file) {
+      this.fileTemp = file.file;
+      if (this.fileTemp) {
+        if (
+          this.fileTemp.type ==
+            "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" ||
+          this.fileTemp.type == "application/vnd.ms-excel"
+        ) {
+          this.importCount = 1;
+          this.importfxx(this.fileTemp);
+        } else {
+          this.$message({
+            type: "warning",
+            message: "附件格式错误,请删除后重新上传!",
+          });
+        }
+      } else {
+        this.$message({
+          type: "warning",
+          message: "请上传附件!",
+        });
+      }
+    },
+    handleRemove(file, fileList) {
+      this.fileTemp = null;
+    },
+    exportExcel() {
+      try {
+        let params = {
+          oid: this.oid,
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectUserBySchool", params)
+          .then((res) => {
+            var res = res.data[0];
+            //如果value的json字段的key值和想要的headers值不一致时,可做如下更改
+            //将和下面的Object.fromEntries结合,将json字段的key值改变为要求的excel的header值
+            var array = [];
+            for (var i = 0; i < res.length; i++) {
+              var _json = {};
+              _json["用户名"] = res[i].username;
+              _json["姓名"] = res[i].alias ? res[i].alias : "";
+              _json["班级"] = res[i].classid ? res[i].classid : "";
+              array.push(_json);
+            }
+
+            var XLSX = require("xlsx");
+            const workbook = XLSX.utils.book_new(); //创建一个新的工作簿对象
+            let ws = XLSX.utils.json_to_sheet(array); //将json对象数组转化成工作表
+            ws["!cols"] = [
+              //设置每一列的宽度
+              { wch: 50 },
+              { wch: 50 },
+              { wch: 50 },
+            ];
+            XLSX.utils.book_append_sheet(workbook, ws, "sheet1"); //把sheet添加到workbook里,第三个参数是sheet名
+            XLSX.writeFile(workbook, "学生信息.xlsx");
+            // const wopts = { bookType: "xlsx", bookSST: false, type: "array" };//写入的样式bookType:输出的文件类型,type:输出的数据类型,bookSST: 是否生成Shared String Table,官方解释是,如果开启生成速度会下降,但在低版本IOS设备上有更好的兼容性
+            // const wbout = XLSX.write(workbook, wopts);// 浏览器端和node共有的API,实际上node可以直接使用xlsx.writeFile来写入文件,但是浏览器没有该API
+            // FileSaver.saveAs(new Blob([wbout], { type: "application/octet-stream" }), `${title} demo.xlsx`);//保存文件
+            this.$message({
+              message: "导出成功",
+              type: "success",
+            });
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      } catch (e) {
+        console.log(e, e.stack);
+      }
+    },
+    importfxx(obj) {
+      const loading = this.$loading.service({
+        background: "rgba(255, 255, 255, 0.7)",
+        target: document.body,
+      });
+      var _$ = $;
+      this.importCount++;
+      let _this = this;
+      // 通过DOM取文件数据
+      this.file = obj;
+      var rABS = false; //是否将文件读取为二进制字符串
+      var f = this.file;
+      var reader = new FileReader();
+      //if (!FileReader.prototype.readAsBinaryString) {
+      FileReader.prototype.readAsBinaryString = function (f) {
+        var binary = "";
+        var rABS = false; //是否将文件读取为二进制字符串
+        var pt = this;
+        var wb; //读取完成的数据
+        var outdata;
+        var reader = new FileReader();
+        reader.onload = function (e) {
+          var bytes = new Uint8Array(reader.result);
+          var length = bytes.byteLength;
+          for (var i = 0; i < length; i++) {
+            binary += String.fromCharCode(bytes[i]);
+          }
+          var XLSX = require("xlsx");
+          if (rABS) {
+            wb = XLSX.read(btoa(fixdata(binary)), {
+              //手动转化
+              type: "base64",
+            });
+          } else {
+            wb = XLSX.read(binary, {
+              type: "binary",
+            });
+          }
+          outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]]); //outdata就是你想要的东西
+          this.da = [...outdata];
+          let arr = [];
+          this.da.map((v) => {
+            let obj = {};
+            obj.name = v["教师姓名"];
+            obj.mail = v["教师邮箱"];
+            obj.school = v["学校"];
+            arr.push(obj);
+          });
+          console.log(arr);
+          let _b = 1;
+          for (var i = 0; i < arr.length; i++) {
+            let item = arr[i];
+            if (item.school === "") {
+              _b = 1;
+              _this.$message.error("教师学校不能为空,请重新上传");
+              break;
+            } else if (item.name === "") {
+              _b = 1;
+              _this.$message.error("教师姓名不能为空,请重新上传");
+              break;
+            } else if (item.mail === "") {
+              _b = 1;
+              _this.$message.error("教师邮箱不能为空,请重新上传");
+            }else if (
+              !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
+                item.mail
+              )
+            ) {
+              _b = 1;
+              _this.$message.error("有教师邮箱格式不正确,请重新上传");
+              break;
+            }
+          }
+          let z = 2;
+          let newArr = JSON.stringify(arr);
+          let params = [
+            {
+              arr: newArr,
+              userpassword: 123456,
+              org: _this.org,
+            },
+          ];
+          _this.ajax
+            .post(_this.$store.state.api + "batchRegistrationMore1", params)
+            .then((res) => {
+              if (z == 2) {
+                _this.$message({
+                  message: "新增成功",
+                  type: "success",
+                });
+                _this.getStudent();
+              }
+              loading.close();
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+          _this.fileListUpload = [];
+        };
+
+        reader.readAsArrayBuffer(f);
+      };
+
+      if (rABS) {
+        reader.readAsArrayBuffer(f);
+      } else {
+        reader.readAsBinaryString(f);
+      }
+    },
+    getSchoolName() {
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectSchoolName2", params)
+        .then((res) => {
+          this.schoolName = res.data[0][0].name;
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    deleteStudent(id, state) {
+      state = 0;
+      let params = [{ uid: id, state: state }];
+      this.$confirm("确定" + "删除" + "此教师吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.ajax
+            .post(this.$store.state.api + "deleteStudent", params)
+            .then((res) => {
+              this.$message({
+                message: "操作成功",
+                type: "success",
+              });
+              this.getStudent();
+            })
+            .catch((err) => {
+              this.$message.error("操作失败");
+              console.error(err);
+            });
+        })
+        .catch(() => {});
+    },
+  },
+  created() {
+    this.page = 1;
+    this.getStudent();
+    this.getSchoolName();
+    this.getClass();
+  },
+};
+</script>
+
+<style scoped>
+.pb_head > span:nth-child(2) {
+  font-size: 20px;
+  margin-left: 5px;
+  color: #828282;
+}
+.pb_head {
+  margin: 0 !important;
+  width: 100% !important;
+}
+.student_page {
+  margin-top: 10px;
+}
+.student_head {
+  margin-top: 10px;
+  padding-bottom: 10px;
+  display: flex;
+  justify-content: space-between;
+}
+.head_left {
+  display: flex;
+  align-items: center;
+}
+.head_right {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: baseline;
+}
+.student_input >>> .el-input__inner {
+  height: 30px;
+  width: 190px;
+  font-size: 13px;
+  padding: 0 10px;
+}
+.student_button {
+  color: #fff;
+  background: #8681b7;
+  border-color: #8681b7;
+  width: 60px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > button:nth-child(1) {
+  color: #fff;
+  background: #8681b7;
+  border-color: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > button:nth-child(2) {
+  color: #fff;
+  background: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 30px;
+}
+.head_right > div {
+  font-size: 12px;
+  line-height: 40px;
+  margin-left: 10px;
+  color: #2a6dbe;
+  text-decoration: underline;
+  cursor: pointer;
+}
+.student_table >>> .el-table--border td {
+  border-right: 0px !important;
+}
+.student_table >>> .el-table,
+.student_table >>> .el-table__body-wrapper {
+  height: auto !important;
+}
+.el-table >>> .even_row {
+  background-color: #f1f1f1 !important;
+}
+.de_button {
+  color: #fff;
+  background: #5190fd;
+  width: 50px;
+  height: 25px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 25px;
+}
+.add_student >>> .el-dialog__header {
+  padding: 20px 20px 10px;
+  text-align: center;
+  background: #454545;
+}
+.add_student >>> .el-dialog__title {
+  font-size: 14px !important;
+  color: #fff !important;
+}
+.add_student >>> .el-dialog__headerbtn {
+  font-size: 20px !important;
+}
+.add_student >>> .el-form-item__label {
+  margin-left: 65px;
+}
+.add_student >>> .el-form-item {
+  display: flex;
+}
+.add_student >>> .el-form-item__content {
+  margin: 0 !important;
+}
+.add_input {
+  width: 365px;
+}
+.add_student >>> .el-dialog__footer {
+  text-align: center !important;
+}
+.right {
+  width: 250px;
+  color: #fff;
+  background: #8681b7;
+  margin-bottom: 20px;
+}
+.header-title {
+  display: flex;
+}
+.logoImg {
+  width: 30px;
+}
+.logoImg > img {
+  width: 100%;
+  height: 100%;
+}
+.title_add_student {
+  margin: 0 auto;
+  color: #fff;
+}
+.upload-demo {
+  line-height: 0px !important;
+}
+.upload-demo >>> .el-button {
+  color: #fff;
+  background: #8681b7;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 0 !important;
+}
+
+.userImg {
+  display: flex;
+  flex-direction: row;
+  justify-content: center;
+  align-items: center;
+}
+
+.tx {
+  width: 40px;
+  margin-right: 10px;
+}
+
+.delete {
+  width: 25px;
+  cursor: pointer;
+}
+
+.tx > img,
+.delete > img {
+  width: 100%;
+  height: 100%;
+}
+
+.newCss {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: baseline;
+}
+
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled).active {
+  background-color: #5c549f;
+  color: #fff !important;
+}
+.student_page
+  >>> .el-pagination.is-background
+  .el-pager
+  li:not(.disabled):hover {
+  color: #5c549f;
+}
+
+.el-select-dropdown__item.selected {
+  color: #5c549f;
+}
+
+.inputClass.is-active >>> .el-input__inner,
+.inputClass >>> .el-input__inner:focus {
+  border-color: #5c549f;
+}
+
+.inputClass >>> .el-select .el-input.is-focus .el-input__inner {
+  border-color: #5c549f;
+}
+.inputClass >>> .el-select .el-input__inner:focus {
+  border-color: #5c549f;
+}
+
+.student_input.el-input {
+  width: auto;
+}
+
+.student_input {
+  margin-right: 10px;
+}
+
+.student_input >>> .el-input__icon {
+  line-height: unset;
+}
+</style>

+ 47 - 0
src/router/index.js

@@ -52,6 +52,11 @@ import examineGM from '@/components/pages/GM/examine'
 import noticeGM from '@/components/pages/GM/notice'
 import studentCourse from '@/components/pages/student/course'
 import studentAddCourse from '@/components/pages/student/addCourse'
+import courseProgress from '@/components/pages/student/courseProgress'
+import tcData from '@/components/pages/tencent/data'
+import tcSchool from '@/components/pages/tencent/school'
+import tcStudent from '@/components/pages/tencent/student'
+import tcTeacher from '@/components/pages/tencent/teacher'
 
 Vue.use(Router).use(ElementUI)
 
@@ -103,6 +108,13 @@ export default new Router({
                 requireAuth: '' // 是否需要判断是否登录,这里是需要判断
             }
         },
+        {
+            path: '/courseProgress',
+            component: courseProgress,
+            meta: {
+                requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+            }
+        },
         {
             path: '/courseGM',
             component: courseGM,
@@ -443,6 +455,41 @@ export default new Router({
                 requireAuth: '' // 不需要鉴权
             }
         },
+        {
+            path: '/tcData',
+            name: 'tcData',
+            component: tcData,
+            meta: {
+                requireAuth: '' // 不需要鉴权
+            }
+        },
+        {
+            path: '/tcSchool',
+            name: 'tcSchool',
+            component: tcSchool,
+            meta: {
+                requireAuth: '' // 不需要鉴权
+            }
+        },
+        {
+            path: '/tcStudent',
+            name: 'tcStudent',
+            component: tcStudent,
+            meta: {
+                requireAuth: '' // 不需要鉴权
+            }
+        },
+        {
+            path: '/tcTeacher',
+            name: 'tcTeacher',
+            component: tcTeacher,
+            meta: {
+                requireAuth: '' // 不需要鉴权
+            }
+        },
         
+
+
+
     ]
 })