Преглед на файлове

Merge branch 'beta' of https://git.cocorobo.cn/CocoRoboLabs/pbl-teacher-table into beta

SanHQin преди 8 месеца
родител
ревизия
8766a80824
променени са 27 файла, в които са добавени 1694 реда и са изтрити 276 реда
  1. 1 1
      dist/index.html
  2. 0 0
      dist/static/css/app.baedc63e611da37a4eb4fb361a578224.css
  3. 0 0
      dist/static/css/app.baedc63e611da37a4eb4fb361a578224.css.map
  4. 0 0
      dist/static/js/app.e12c9327b7b954504f6e.js
  5. 0 0
      dist/static/js/app.e12c9327b7b954504f6e.js.map
  6. 0 0
      dist/static/js/manifest.571c38d63f24b1ae9e16.js.map
  7. 1 1
      src/components/pages/addCourseGM.vue
  8. 556 133
      src/components/pages/aiAddCourse/addCourse.vue
  9. 1 1
      src/components/pages/aiAddCourse/aiCreateDialog.vue
  10. 10 9
      src/components/pages/aiAddCourse/templateDialog.vue
  11. 38 13
      src/components/pages/aiAddCourse/tipsDialog.vue
  12. 2 2
      src/components/pages/race/addRace/projectProcess.vue
  13. 1 1
      src/components/pages/student/addCourseJiu.vue
  14. 1 1
      src/components/pages/studio/addCourse.vue
  15. 1 1
      src/components/pages/task/addCourse.vue
  16. 1 1
      src/components/pages/test/add/setInfo/index.vue
  17. 137 0
      src/components/pages/test/aggregate/index.vue
  18. 299 64
      src/components/pages/test/examine/conpoments/personPage.vue
  19. 427 0
      src/components/pages/test/examine/conpoments/shareBox/index.vue
  20. 103 24
      src/components/pages/test/examine/conpoments/targetPage.vue
  21. 56 11
      src/components/pages/test/examine/index.vue
  22. 1 1
      src/components/pages/test/file/wPdf.vue
  23. 1 1
      src/components/pages/test/file/wPdf2.vue
  24. 10 3
      src/components/pages/test/index.vue
  25. 19 2
      src/components/pages/testPerson/examine/index.vue
  26. 3 2
      src/components/pages/testPerson/info/index.vue
  27. 25 4
      src/components/pages/testPerson/info/infoDialog/index.vue

+ 1 - 1
dist/index.html

@@ -32,7 +32,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.0a244d8ed7b630a0e7defc6f9ad5b003.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.571c38d63f24b1ae9e16.js></script><script type=text/javascript src=./static/js/vendor.d5f0d79dbb0d92c052d4.js></script><script type=text/javascript src=./static/js/app.feafa4415508799db9a3.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.baedc63e611da37a4eb4fb361a578224.css rel=stylesheet></head><body><div id=app></div><script type=text/javascript src=./static/js/manifest.571c38d63f24b1ae9e16.js></script><script type=text/javascript src=./static/js/vendor.d5f0d79dbb0d92c052d4.js></script><script type=text/javascript src=./static/js/app.e12c9327b7b954504f6e.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
dist/static/css/app.baedc63e611da37a4eb4fb361a578224.css


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
dist/static/css/app.baedc63e611da37a4eb4fb361a578224.css.map


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
dist/static/js/app.e12c9327b7b954504f6e.js


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
dist/static/js/app.e12c9327b7b954504f6e.js.map


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
dist/static/js/manifest.571c38d63f24b1ae9e16.js.map


+ 1 - 1
src/components/pages/addCourseGM.vue

@@ -1398,7 +1398,7 @@
                 </div>
                 <div class="addTaskBorder" @click="addTaskBorder">
                   <div>
-                    <img src="../../assets/icon/addHw.png" alt />
+                    <img src="../../assets/icon/addHW.png" alt />
                     <span>添加任务</span>
                   </div>
                 </div>

Файловите разлики са ограничени, защото са твърде много
+ 556 - 133
src/components/pages/aiAddCourse/addCourse.vue


+ 1 - 1
src/components/pages/aiAddCourse/aiCreateDialog.vue

@@ -361,7 +361,7 @@ ${mclass.length ? "面向年级:" + mclass.join(",") : ""}
                     type == 1
                         ? "6063369f-289a-11ef-8bf4-12e77c4cb76b"
                         : "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
-                message: [{ type: "text", text: message }],
+                message: [{ type: "text", text: message.replaceAll('\n', " ") }],
                 session_name: uuidv4(),
                 userId: this.userid,
                 file_ids: fileid.length ? [...fileid] : "",

+ 10 - 9
src/components/pages/aiAddCourse/templateDialog.vue

@@ -10,7 +10,7 @@
                 </el-input>
             </div>
             <div class="a-d-t-right">
-                <!-- <el-button @click="open2()" type="primary" size="small" style="margin-right: 10px;">设置模板</el-button> -->
+                <el-button @click="open2()" type="primary" size="small" style="margin-right: 10px;">设置模板</el-button>
                 <span @click.stop="close">×</span>
             </div>
         </div>
@@ -37,7 +37,7 @@
 						">
                     {{ tagname }}
                 </div>
-                <div style="display: flex; flex-wrap: wrap" v-loading="loading">
+                <div style="display: flex; flex-wrap: wrap;height:100%" v-loading="loading">
                     <div class="a-d-b-item" v-for="(item, index) in searchDataList" :key="index">
                         <div class="a-d-b-i-top">
                             <img style="height: 22px; width: 22px" :src="require('../../../assets/icon/classroomObservation/digImg.svg')
@@ -48,9 +48,9 @@
                             </el-tooltip>
                         </div>
                         <div class="a-d-b-i-top" v-if="item.uname">创建人:{{ item.uname }}</div>
-                        <el-tooltip :content="item.detail" placement="top" effect="dark">
+                        <!-- <el-tooltip :content="item.detail" placement="top" effect="dark"> -->
                             <div class="a-d-b-i-bottom">{{ item.detail }}</div>
-                        </el-tooltip>
+                        <!-- </el-tooltip> -->
                         <div class="a-d-b-i-bottomBtn">
                             <div style="
 										display: flex;
@@ -190,11 +190,12 @@ export default {
                     this.loading = false
                     this.searchDataList = res.data[0]
                     if (!this.input2) {
-                        this.searchDataList.unshift({
-                            name: "项目式学习 (Project-Based Learning, PBL)",
-                            detail: "项目式学习是一种以学生为中心的教学方法,通过实际项目和问题解决,培养学生的深度学习和应用能力。",
-                            id:''
-                        });
+                        // this.searchDataList.unshift(
+                        //     {
+                        //     name: "项目式学习 (Project-Based Learning, PBL)",
+                        //     detail: "项目式学习是一种以学生为中心的教学方法,通过实际项目和问题解决,培养学生的深度学习和应用能力。",
+                        //     id:''
+                        // });
                     }
                 })
                 .catch((err) => {

+ 38 - 13
src/components/pages/aiAddCourse/tipsDialog.vue

@@ -19,8 +19,16 @@
                     <el-radio :label="2">所有人</el-radio>
                 </el-radio-group>
             </div>
+            <div class="t_box">
+                <span>是否公开提示词:</span>
+                <el-radio-group v-model="isT">
+                    <el-radio :label="1">不公开</el-radio>
+                    <el-radio :label="2">公开</el-radio>
+                </el-radio-group>
+            </div>
         </div>
         <span slot="footer" class="dialog-footer">
+            <el-button @click="selectT(2)" type="primary">确定并保存课程</el-button>
             <el-button @click="selectT" type="primary">确 定</el-button>
             <el-button @click="close">关 闭</el-button>
         </span>
@@ -56,7 +64,8 @@ export default {
         return {
             title: "",
             detail: "",
-            radio: 0
+            radio: 0,
+            isT: 1
         }
     },
     watch: {
@@ -65,11 +74,13 @@ export default {
                 this.title = this.tipsJson.name ? this.tipsJson.name : ''
                 this.detail = this.tipsJson.detail ? this.tipsJson.detail : ''
                 this.radio = this.tipsJson.open ? parseInt(this.tipsJson.open) : 0
+                this.isT = this.tipsJson.istips ? parseInt(this.tipsJson.istips) : 0
             } else {
                 this.$emit('update:tipsJson', {
                     name: this.title,
                     detail: this.detail,
                     open: this.radio,
+                    istips: this.istips
                 })
             }
         },
@@ -82,7 +93,7 @@ export default {
         close() {
             this.$emit('update:dialogVisibleTips', false)
         },
-        selectT() {
+        selectT(type) {
             if (!this.title) {
                 this.$message.error('请输入模板名称');
                 return
@@ -98,13 +109,13 @@ export default {
                     }
                 )
                     .then(() => {
-                        this.updateTipsTemplate();
+                        this.updateTipsTemplate(type);
                     })
                     .catch(() => {
                         return;
                     });
             }else{
-                this.addTipsTemplate();
+                this.addTipsTemplate(type);
             }
             // let params = {
             //     userid: this.userid,
@@ -138,19 +149,27 @@ export default {
             //         console.error(err);
             //     });
         },
-        addTipsTemplate() {
+        addTipsTemplate(type) {
             let params = [{
                 n: this.title,
                 d: this.detail,
                 json: JSON.stringify(this.aiJson),
                 o: this.radio,
-                uid: this.userid
+                uid: this.userid,
+                isT: this.isT
             }]
             this.ajax
-                .post(this.$store.state.api + "addTipsTemplate", params)
+                .post(this.$store.state.api + "addTipsTemplate2", params)
                 .then((res) => {
                     this.$message.success("保存成功");
-                    this.$emit('retrunCourse')
+                    console.log(res.data);
+                    this.$emit('update:templateid', res.data[0][0].id)
+                    console.log(this.templateid)
+                    if(type == 2){
+                        this.$emit('addWork', type)
+                    }else{
+                        this.$emit('retrunCourse')
+                    }
                     this.close();
                 })
                 .catch((err) => {
@@ -158,19 +177,24 @@ export default {
                     console.error(err);
                 });
         },
-        updateTipsTemplate() {
+        updateTipsTemplate(type) {
             let params = [{
                 n: this.title,
                 d: this.detail,
                 json: JSON.stringify(this.aiJson),
                 o: this.radio,
-                uid: this.templateid
+                uid: this.templateid,
+                isT: this.isT
             }]
             this.ajax
-                .post(this.$store.state.api + "addTipsTemplate", params)
+                .post(this.$store.state.api + "addTipsTemplate2", params)
                 .then((res) => {
                     this.$message.success("修改成功");
-                    this.$emit('retrunCourse')
+                    if(type == 2){
+                        this.$emit('addWork', type)
+                    }else{
+                        this.$emit('retrunCourse')
+                    }
                     this.close();
                 })
                 .catch((err) => {
@@ -263,8 +287,9 @@ export default {
 }
 
 .t_box>span:nth-child(1) {
-    min-width: 80px;
+    min-width: 135px;
     font-size: 16px;
     color: #000;
+    text-align: right;
 }
 </style>

+ 2 - 2
src/components/pages/race/addRace/projectProcess.vue

@@ -564,7 +564,7 @@
                 v-if="raIndex == racePro.stageBox[saIndex].actBox.length - 1"
               >
                 <div>
-                  <img src="../../../../assets/icon/addHw.png" alt />
+                  <img src="../../../../assets/icon/addHW.png" alt />
                   <span>添加任务</span>
                 </div>
               </div>
@@ -575,7 +575,7 @@
               v-if="saIndex == racePro.stageBox.length - 1"
             >
               <div>
-                <img src="../../../../assets/icon/addHw.png" alt />
+                <img src="../../../../assets/icon/addHW.png" alt />
                 <span>添加阶段</span>
               </div>
             </div>

+ 1 - 1
src/components/pages/student/addCourseJiu.vue

@@ -1315,7 +1315,7 @@
                 </div>
                 <div class="addTaskBorder" @click="addTaskBorder">
                   <div>
-                    <img src="../../../assets/icon/addHw.png" alt />
+                    <img src="../../../assets/icon/addHW.png" alt />
                     <span>添加任务</span>
                   </div>
                 </div>

+ 1 - 1
src/components/pages/studio/addCourse.vue

@@ -1920,7 +1920,7 @@
                 </div>
                 <div class="addTaskBorder" @click="addTaskBorder">
                   <div>
-                    <img src="../../../assets/icon/addHw.png" alt />
+                    <img src="../../../assets/icon/addHW.png" alt />
                     <span>添加任务</span>
                   </div>
                 </div>

+ 1 - 1
src/components/pages/task/addCourse.vue

@@ -6156,7 +6156,7 @@
                   v-if="!unitJson[unitIndex].easy"
                 >
                   <div>
-                    <img src="../../../assets/icon/addHw.png" alt />
+                    <img src="../../../assets/icon/addHW.png" alt />
                     <span>添加任务</span>
                   </div>
                 </div>

+ 1 - 1
src/components/pages/test/add/setInfo/index.vue

@@ -84,7 +84,7 @@
                         <!-- <span :class="{ active: type == 3 }" @click="type = 3">题库导入</span> -->
                         <div class="skip_btn">
                             <!-- <el-button type="primary" size="mini" @click="openAiCreate">智能创建</el-button> -->
-                            <el-button type="primary" size="mini" @click="nextSteps">跳过</el-button>
+                            <!-- <el-button type="primary" size="mini" @click="nextSteps">跳过</el-button> -->
                         </div>
 
                     </div>

+ 137 - 0
src/components/pages/test/aggregate/index.vue

@@ -0,0 +1,137 @@
+<template>
+  <div class="aggregate">
+    <el-table :data="tableData" border style="width: 100%" v-loading="tabLoading" @header-click="handleHeaderClick">
+      <el-table-column fixed align="center" type="index" width="50">
+      </el-table-column>
+
+      <el-table-column fixed align="center" prop="username" label="教师姓名" width="150">
+      </el-table-column>
+      <el-table-column fixed align="center" label="教研室" width="130">
+        <template slot-scope="scope">
+          <div class="TabBtn" v-if="!scope.row.tea">/</div>
+          <div class="TabBtn" v-else>{{ scope.row.tea }}</div>
+        </template>
+      </el-table-column>
+
+      <div v-for="item in titList" :key="item.id">
+        <el-table-column align="center" :label="item.name">
+          <div v-for="e in allFrom" :key="e.courseId">
+            <el-table-column v-if="e.typeid == item.id" align="center" :prop="e.courseId" :label="e.title"
+              :cell-style="{ color: '#000' }" width="130">
+              <template slot-scope="scope">
+                <div v-if="e.juri2 && arrayToArray(scope.row.teaId ? scope.row.teaId.split(',') : [],e.juri2 ? e.juri2.split(',') : []).length && scope.row.works.indexOf(e.courseId) !== -1"
+                  class="yuan blacky"></div>
+                <div v-else-if="scope.row.works.indexOf(e.courseId) !== -1" class="yuan blacky"></div>
+                <div v-else-if="e.juri2 && arrayToArray(scope.row.teaId ? scope.row.teaId.split(',') : [],e.juri2 ? e.juri2.split(',') : []).length == 0" class="yuan greyy"></div>
+                <div v-else class="yuan"></div>
+              </template>
+            </el-table-column>
+          </div>
+        </el-table-column>
+      </div>
+    </el-table>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      tableData: [],
+      titList: [],
+      allFrom: [],
+      tabLoading: false
+    };
+  },
+
+  mounted() {
+    this.getData();
+  },
+
+  methods: {
+    arrayToArray(arrayo, arrayt) {
+      let array1 = arrayo;
+      let array2 = arrayt;
+
+      let commonElements = [];
+
+      for (let i = 0; i < array1.length; i++) {
+        for (let j = 0; j < array2.length; j++) {
+          if (array1[i] === array2[j]) {
+            commonElements.push(array1[i]);
+          }
+        }
+      }
+      return commonElements;
+    },
+    getData() {
+      this.tabLoading = true;
+
+      let params = {
+        oid: this.oid,
+        org: this.org
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTestWorksAggregate", params)
+        .then(res => {
+          let data = res.data[0]; //所有老师
+          this.titList = res.data[1]; // 所有分类
+          this.allFrom = res.data[2]; //所有表单
+          let data3 = res.data[3]; //所有老师填写表单
+          data.forEach(e => {
+            e.works = [];
+            data3.forEach(k => {
+              if (e.userid == k.userid) {
+                e.works.push(k.courseid);
+              }
+            });
+          });
+          this.tableData = data;
+          this.tabLoading = false;
+        })
+        .catch(error => {
+          console.log(error);
+        });
+    },
+    handleHeaderClick(column, event) {
+      // console.log("表头被点击", column, event);
+      this.$router.push(
+        "/checkToTest?cid=" +
+        column.property +
+        "&oid=" +
+        this.oid +
+        "&org=" +
+        this.org +
+        "&type=" +
+        2 +
+        "&role=" +
+        this.role
+      );
+      // 在这里处理点击事件
+    }
+  }
+};
+</script>
+
+<style scoped>
+.yuan {
+  width: 13px;
+  height: 13px;
+  border: 1px solid #000;
+  border-radius: 100%;
+  box-sizing: border-box;
+  margin: 0 auto;
+}
+
+.blacky {
+  background-color: #000;
+}
+
+.greyy {
+  background-color: #eee;
+  border: 1px solid #eee;
+}
+</style>

+ 299 - 64
src/components/pages/test/examine/conpoments/personPage.vue

@@ -1,19 +1,30 @@
 <template>
   <div>
     <div class="personPage">
-      <!-- <div style="width: 100%;display: flex;justify-content: flex-end;">
-        <el-select v-model="teas" multiple placeholder="请选择">
+      <div
+        style="width: 100%;display: flex;justify-content: flex-end;align-items: center;"
+      >
+        <!-- <el-select v-model="teas" multiple placeholder="请选择">
           <el-option
-            v-for="item in TeaOptions"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value"
+            v-for="item in TeaList"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id"
           >
           </el-option>
-        </el-select>
-        <div><el-button type="primary" size="mini">提醒</el-button></div>
-      </div> -->
-      <el-table :data="tableData" class="scoTab" style="width: 100%">
+        </el-select> -->
+        <!-- <div style="margin-left: 10px;">
+          <el-button type="primary" @click="remindExamine" size="mini"
+            >提醒</el-button
+          >
+        </div> -->
+      </div>
+      <el-table
+        :data="tableData"
+        class="scoTab"
+        v-loading="tabLoading"
+        style="width: 100%"
+      >
         <el-table-column type="index" align="center" label="序号" width="180">
         </el-table-column>
         <el-table-column prop="username" align="center" label="教师姓名">
@@ -21,24 +32,51 @@
         <el-table-column
           prop="tea"
           show-overflow-tooltip
+          :filters="TeachingOptions"
+          :filter-method="filterTea"
           align="center"
           label="教研室"
           width="180"
         >
         </el-table-column>
-        <el-table-column align="center" label="考核进度">
+        <el-table-column
+          :filters="[
+            { text: '已完成', value: '已完成' },
+            { text: '未完成', value: '未完成' }
+          ]"
+          :filter-method="filterExa"
+          :filter-multiple="false"
+          prop="state"
+          align="center"
+          label="考核进度"
+        >
           <template slot-scope="scope">
             <div v-if="scope.row.step == scope.row.allStep">√</div>
             <div v-else>{{ scope.row.step }}/{{ scope.row.allStep }}</div>
           </template>
         </el-table-column>
-        <el-table-column prop="evaSca" align="center" label="自评分数">
+        <el-table-column
+          prop="evaSca"
+          :sortable="true"
+          :sort-method="sortEvaMethod"
+          align="center"
+          label="自评分数"
+        >
         </el-table-column>
-        <el-table-column prop="cogSco" align="center" label="考核分数">
+        <el-table-column
+          prop="cogSco"
+          :sortable="true"
+          :sort-method="sortCogMethod"
+          align="center"
+          label="考核分数"
+        >
         </el-table-column>
-        <el-table-column align="center" label="评分">
+        <el-table-column align="center" label="操作">
           <template slot-scope="scope">
-            <div class="TabBtn" @click="lookScore(scope.row)">评分</div>
+            <div style="display: flex;justify-content: center;">
+              <div class="TabBtn" @click="lookScore(scope.row)">评分</div>
+              <div class="TabBtn" @click="withdraw(scope.row.id)">退回</div>
+            </div>
           </template>
         </el-table-column>
       </el-table>
@@ -171,6 +209,10 @@
                       <div style="display: flex;justify-content: center;">
                         <div v-if="tableData.length > 0" class="ScoreStep">
                           <input
+                            :style="{
+                              color: k.sco1 == k.sco2 ? '#000' : 'red'
+                            }"
+                            :readonly="txtLoading"
                             @blur="
                               saveTab(
                                 k.sco2 > k.score ? (k.sco2 = k.score) : ''
@@ -179,11 +221,11 @@
                             type="number"
                             v-model="k.sco2"
                           />
-                          <!-- @blur="Submit(scope.row)" -->
                         </div>
                       </div>
                       <div style="display: flex;justify-content: center;">
                         <textarea
+                          :readonly="txtLoading"
                           v-if="tableData.length > 0"
                           @blur="saveTab()"
                           v-model.trim="k.cogSum"
@@ -205,7 +247,7 @@
       :visible.sync="diaIframe"
       :append-to-body="true"
       width="95%"
-      :before-close="handleClose"
+      :before-close="handleClose2"
       class="dialog_diy"
     >
       <div style="height: 100%;">
@@ -216,19 +258,79 @@
         ></iframe>
       </div>
     </el-dialog>
+
+    <!-- 提醒弹框 -->
+
+    <shareBox
+      :remDig.sync="remDig"
+      :pType="pType"
+      :TeaList="TeaList"
+    ></shareBox>
+
+    <!-- <el-dialog
+      title="提醒"
+      :visible.sync="remDig"
+      :append-to-body="true"
+      width="600"
+      :before-close="handleClose3"
+      class="dialog_remDig"
+    >
+      <div v-loading="digLoading" style="height: 100%;padding: 15px;">
+        <div class="remFlex" style="align-items: center;">
+          <div class="remFlexTit">填写范围:</div>
+          <el-select v-model="teas" multiple placeholder="请选择">
+            <el-option
+              v-for="item in TeaList"
+              :key="item.id"
+              :label="item.name"
+              :value="item.id"
+              @change="remindExamine"
+            >
+            </el-option>
+          </el-select>
+        </div>
+        <div class="remFlex">
+          <div class="remFlexTit">需提交人数:</div>
+          <div>{{ remindNum }}</div>
+        </div>
+        <div class="remFlex">
+          <div class="remFlexTit">未完成人数:</div>
+          <div>{{ remindList.length }}</div>
+        </div>
+        <div class="remFlex">
+          <div class="remFlexTit">需提交人数:</div>
+          <div class="remFlex" style="flex-wrap: wrap;">
+            <div
+              v-for="(item, index) in remindList"
+              :key="index"
+              style="margin-right: 2px;"
+            >
+              {{ item }},
+            </div>
+          </div>
+        </div>
+      </div>
+    </el-dialog> -->
   </div>
 </template>
 
 <script>
+import shareBox from "./shareBox/index";
 export default {
   props: {
     pType: {
       //2专任教师 1班主任
       type: Number,
       default: 0
+    },
+    teacherName: {
+      type: String,
+      default: ""
     }
   },
-
+  components: {
+    shareBox
+  },
   data() {
     return {
       digType: 2,
@@ -247,34 +349,16 @@ export default {
       computedScoData: 0,
       computedStepData: 0,
       computedCogSCoData: 0,
-
+      TeaList: [],
+      tabLoading: false,
       userid: this.$route.query.userid, //用户id
       oid: this.$route.query.oid, //学校id
       org: this.$route.query.org, //组织id
       tableData: [],
-      TeaOptions: [
-        {
-          value: "选项1",
-          label: "黄金糕"
-        },
-        {
-          value: "选项2",
-          label: "双皮奶"
-        },
-        {
-          value: "选项3",
-          label: "蚵仔煎"
-        },
-        {
-          value: "选项4",
-          label: "龙须面"
-        },
-        {
-          value: "选项5",
-          label: "北京烤鸭"
-        }
-      ],
-      teas: []
+      TeachingOptions: [],
+      txtLoading: false,
+
+      remDig: false
     };
   },
   watch: {
@@ -333,18 +417,21 @@ export default {
   },
   mounted() {
     this.getData();
+    this.getTeaList();
   },
   methods: {
     // 获取页面数据
     getData() {
+      this.tabLoading = true;
       let params = {
         oid: this.oid,
         org: this.org,
-        type: this.pType
+        type: this.pType,
+        tname: this.teacherName
       };
       // console.log(params);
       this.ajax
-        .get(this.$store.state.api + "selectTestExamineSecondData", params)
+        .get(this.$store.state.api + "selectTestExaminePersonData", params)
         .then(res => {
           let data = res.data[0];
 
@@ -371,16 +458,25 @@ export default {
           });
 
           data.forEach(e => {
+            if (e.step == e.allStep) {
+              e.state = "已完成";
+            } else {
+              e.state = "未完成";
+            }
+            if (!e.tea) {
+              e.tea = "";
+            }
             e.evaSca = e.evaSca.toFixed(2);
             e.cogSco = e.cogSco.toFixed(2);
           });
           this.tableData = data;
+          this.tabLoading = false;
         })
         .catch(error => {
+          this.tabLoading = false;
           console.log(error);
         });
     },
-
     // 点击评分
     lookScore(val) {
       this.digLoading = true;
@@ -398,24 +494,132 @@ export default {
       this.cutPerson();
       this.getPageBase();
     },
-    // getTeaList() {
-    // let params = {
-    //     oid: this.oid,
-    // };
-    // this.ajax
-    //     .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
-    //     .then((res) => {
-    //         this.TeachingOptions = res.data[0];
-    //         console.log('this.TeachingOptions',this.TeachingOptions);
-    //     })
-    //     .catch((err) => {
-    //         this.isLoading = false;
-    //         console.error(err);
-    //     });
-    // },
+    // 获取教研室
+    getTeaList() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+        .then(res => {
+          // return console.log("this.TeachingOptions", res.data[0]);
+          let data = res.data[0];
+          let dataCopy = [];
+
+          data.forEach(e => {
+            let a = {};
+            a.value = e.name;
+            a.text = e.name;
+            dataCopy.push(a);
+          });
+          data.forEach(e => {
+            let a = {};
+            a.id = e.id;
+            a.name = e.name;
+            this.TeaList.push(a);
+          });
+
+          this.TeachingOptions = dataCopy;
+          // console.log("this.TeachingOptions", this.TeachingOptions);
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    // 撤回
+    withdraw(id) {
+      let params = [
+        {
+          tid: id
+        }
+      ];
+
+      this.$confirm("是否确认退回?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: " info"
+      })
+        .then(() => {
+          this.ajax
+            .post(this.$store.state.api + "updateExamineState", params)
+            .then(res => {
+              this.getData();
+            })
+            .catch(error => {
+              console.log(error);
+            });
+        })
+        .catch(() => {
+          // this.$message({
+          //   type: "info",
+          //   message: "已取消退回"
+          // });
+        });
+    },
+    // 提醒
+    remindExamine() {
+      this.remDig = true;
+    },
+    getExcel() {
+      
+      var res = this.tableData;
+      // console.log('导出数据',res);
+      //如果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].eName;
+        _json["所属教研室"] = res[i].tea;
+        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: 30 },
+        { wch: 30 },
+        { wch: 30 },
+      ];
+
+      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"
+      });
+    },
+    // 按照数字大小排序 方法-
+    sortCogMethod(before, after) {
+      return Number(before.cogSco) - Number(after.cogSco);
+    },
+    sortEvaMethod(before, after) {
+      return Number(before.evaSca) - Number(after.evaSca);
+    },
+    // 教研室筛选
+    filterTea(value, row, column) {
+      // console.log(value, row, column);
+      const property = column["property"];
+      return row[property].includes(value);
+    },
+    // 是否完成筛选
+    filterExa(value, row, column) {
+      // console.log(value, row, column);
+      const property = column["property"];
+      return row[property] == value;
+    },
     // ----------------
+
     // 保存修改
     saveTab() {
+      this.txtLoading = true;
+
       let PageBaseDataCopy = JSON.parse(JSON.stringify(this.PageBaseData));
 
       for (const e of PageBaseDataCopy) {
@@ -452,7 +656,7 @@ export default {
         return this.$message.error("暂无人员提交");
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}`;
 
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${cid}&oid=${this.oid}&org=${this.oid}&type=2&role=0&peopleId=${this.digUserid}`;
+      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${cid}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.digUserid}`;
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -615,6 +819,7 @@ export default {
             this.DigSelfSco = 0;
             this.twoTarget = 0;
           }
+          this.txtLoading = false;
           this.digLoading = false;
         })
         .catch(error => {
@@ -645,12 +850,20 @@ export default {
         }
       });
     },
-    // 关闭弹框
+    // 评分关闭弹框
     handleClose(done) {
       this.getData();
       done();
     },
-
+    // 数据来源关闭弹框
+    handleClose2(done) {
+      this.digLoading = true;
+      this.getPageBase();
+      done();
+    },
+    // handleClose3(done) {
+    //   done();
+    // },
     // 处理数据来源
     async handleData() {
       for (const e of this.PageBaseData) {
@@ -665,7 +878,7 @@ export default {
     computedTest(val) {
       let params = [
         {
-          uid: this.uid,
+          uid: this.digUserid,
           testId: val.join(",")
         }
       ];
@@ -693,6 +906,15 @@ export default {
   white-space: nowrap;
   text-overflow: ellipsis;
 }
+.remFlex {
+  display: flex;
+  justify-content: flex-start;
+  margin-bottom: 20px;
+}
+.remFlexTit {
+  width: 80px;
+  flex-shrink: 0;
+}
 .digTop {
   display: flex;
   justify-content: space-between;
@@ -702,6 +924,19 @@ export default {
 .TabBtn {
   cursor: pointer;
   color: #528df6;
+  margin: 0 10px;
+}
+.dialog_remDig >>> .el-dialog {
+  height: 700px;
+  margin: 0 auto !important;
+  margin-top: 20px !important;
+  overflow: hidden;
+  min-width: 800px !important;
+}
+
+.dialog_remDig >>> .el-dialog__header {
+  background: #454545 !important;
+  padding: 15px 20px;
 }
 .dialog_diy >>> .el-dialog {
   height: 95%;

+ 427 - 0
src/components/pages/test/examine/conpoments/shareBox/index.vue

@@ -0,0 +1,427 @@
+<template>
+  <el-dialog
+    title="提醒"
+    :visible.sync="remDig"
+    :append-to-body="true"
+    width="560px"
+    :before-close="handleClose"
+    class="dialog_diy"
+  >
+    <div class="share_box">
+      <div class="info_box" ref="info">
+        <!-- <div class="info">
+          <span>表单范围:</span>
+          <span>{{ reversedMessage }}</span>
+        </div> -->
+        <div class="info">
+          <span>填写范围:</span>
+          <el-select
+            v-model="teas"
+            @change="getData"
+            multiple
+            placeholder="请选择"
+          >
+            <el-option
+              v-for="item in TeaList"
+              :key="item.id"
+              :label="item.name"
+              :value="item.id"
+            >
+            </el-option>
+          </el-select>
+        </div>
+        <!-- <div class="info" v-if="testJson && testJson.overtime">
+          <span>截止时间:</span>
+          <span>{{ testJson.overtime }}</span>
+        </div> -->
+        <div class="info">
+          <span>需提交人数:</span>
+          <span>{{ remindNum }}</span>
+        </div>
+        <div class="info">
+          <span>未完成人数:</span>
+          <span v-html="remindList.length"></span>
+        </div>
+        <div class="info">
+          <span>未完成名单:</span>
+          <span>{{
+            remindList.length > 20
+              ? isSuo
+                ? remindList.slice(0, 20).join(",") + "..."
+                : remindList.join(",")
+              : remindList.join(",")
+          }}</span>
+          <span
+            class="more"
+            v-if="remindList.length > 20"
+            @click="isSuo = !isSuo"
+            >{{ isSuo ? "查看更多" : "收起" }}</span
+          >
+        </div>
+      </div>
+
+      <div class="btn_box">
+        <button class="c_pub_button_confirm tag-read2" @click="getExcelTab">
+          导出
+        </button>
+        <button
+          class="c_pub_button_confirm tag-read2"
+          @click="copy2"
+          :data-clipboard-text="copyText2"
+        >
+          复制信息
+        </button>
+      </div>
+    </div>
+  </el-dialog>
+</template>
+
+<script>
+import Clipboard from "clipboard";
+export default {
+  props: {
+    remDig: {
+      type: Boolean,
+      default: false
+    },
+    pType: {
+      type: Number
+    },
+    TeaList: {
+      type: Array
+    },
+    testJson: {
+      type: Object
+    },
+    TeachingValue: {
+      type: String
+    },
+    TeachName: {
+      type: Array
+    }
+  },
+  data() {
+    return {
+      origin: "",
+      copyText: "",
+      copyText2: "",
+      noCount: 0,
+      pname: [],
+      isSuo: true,
+      excelData: [],
+      remindNum: 0,
+      remindList: [],
+      remindName: [],
+      oid: this.$route.query.oid, //学校id
+      org: this.$route.query.org, //组织id
+      teas: []
+    };
+  },
+  computed: {
+    reversedMessage() {
+      if (this.TeachingValue == "") {
+        return this.testJson.juriP ? this.testJson.juriP : "所有人";
+      } else {
+        return this.TeachName ? this.TeachName[0].name : "所有人";
+      }
+    }
+  },
+  methods: {
+    handleClose(done) {
+      this.close();
+      done();
+    },
+    close() {
+      this.teas = [];
+      this.$emit("update:remDig", false);
+    },
+
+    copy2() {
+      this.copyText2 = `填写范围:${
+        this.teas ? this.remindName.join(",") : "所有人"
+      }\n${"需提交人数:" +
+        this.remindNum +
+        "\n"}${"未完成人数:" + this.remindList.length + "\n"}${
+        this.remindList.length
+          ? "未完成名单:" + this.remindList.join(",") + "\n"
+          : ""
+      }`;
+      var clipboard = new Clipboard(".tag-read2");
+      clipboard.on("success", e => {
+        this.$message.success("复制成功");
+        console.log("复制成功");
+        clipboard.destroy(); // 释放内存
+      });
+      clipboard.on("error", e => {
+        console.log("不支持复制,该浏览器不支持自动复制");
+        clipboard.destroy(); // 释放内存
+      });
+    },
+    getData() {
+      this.remindList = [];
+      this.remindName = [];
+
+      this.remindNum = 0;
+      let params = {
+        oid: this.oid,
+        org: this.org,
+        tea: this.teas.join(","),
+        ptype: this.pType
+      };
+
+      this.ajax
+        .get(this.$store.state.api + "selectExamineTeaRemind", params)
+        .then(res => {
+          let data = res.data[0];
+          this.excelData = JSON.parse(JSON.stringify(data));
+          this.remindNum = data.length > 0 ? data[0].num : 0;
+          data.forEach(e => {
+            this.remindList.push(e.username);
+          });
+          //   this.digLoading = false;
+
+          if (this.teas.length > 0) {
+            this.teas.forEach(e => {
+              this.TeaList.forEach(k => {
+                if (e == k.id) {
+                  this.remindName.push(k.name);
+                }
+              });
+            });
+          }
+
+          console.log("selectExamineTeaRemind", this.remindName);
+        })
+        .catch(err => {
+          console.error(err);
+        });
+
+      //     let params = {
+      //         id: this.testJson.courseId,
+      //         tea: this.TeachingValue
+      //     };
+      //     this.ajax
+      //         .get(this.$store.state.api + "getTestWorkShareCopy", params)
+      //         .then((res) => {
+      //             console.log('res.datares.datares.datares.datares.datares.data',res.data);
+      //             let parray = res.data[0]
+      //             let is = res.data[1]
+      //             this.noCount = parray.length - is.length
+      //             let isA = []
+      //             for(var i=0;i<is.length;i++){
+      //                 isA.push(is[i].userid)
+      //             }
+      //             let pname = []
+      //             for(var i=0;i<parray.length;i++){
+      //                 if(isA.indexOf(parray[i].userid) == -1){
+      //                     pname.push(parray[i].username)
+      //                 }
+      //             }
+      //             this.pname = pname
+      //         })
+      //         .catch((err) => {
+      //             console.error(err);
+      //         });
+    },
+    getExcelTab() {
+      var res = this.excelData;
+      // console.log('导出数据',res);
+      //如果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].eName;
+        _json["所属教研室"] = res[i].tea;
+        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: 30 },
+        { wch: 30 },
+        { wch: 30 }
+      ];
+
+      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"
+      });
+    }
+  },
+  watch: {
+    remDig(newValue, oldValue) {
+      if (newValue) {
+        this.isSuo = true;
+        this.getData();
+      }
+    }
+  }
+  // mounted(){
+  //     console.log(top.origin);
+  // },
+};
+</script>
+
+<style scoped>
+.dialog_diy >>> .el-dialog {
+  height: 70% !important;
+  min-width: 650px !important;
+  margin-top: 10% !important;
+  /* height: 100%; */
+  /* margin: 0 auto !important; */
+}
+
+/* .dialog_diy >>> .el-dialog__header {
+  background: #454545 !important;
+  padding: 25px 20px;
+} */
+.dialog_diy >>> .el-dialog__header {
+  background: #fff !important;
+  padding: 15px 20px;
+}
+
+.dialog_diy >>> .el-dialog__body {
+  height: calc(100% - 124px);
+  box-sizing: border-box;
+  padding: 0px;
+}
+
+.dialog_diy >>> .el-dialog__title {
+  color: #000;
+}
+
+.dialog_diy >>> .el-dialog__headerbtn {
+  top: 19px;
+}
+
+.dialog_diy >>> .el-dialog__headerbtn .el-dialog__close {
+  color: #000;
+}
+
+.dialog_diy >>> .el-dialog__headerbtn .el-dialog__close:hover {
+  color: #000;
+}
+
+.dialog_diy >>> .el-dialog__body,
+.dialog_diy >>> .el-dialog__footer {
+  background: #fff;
+}
+
+.share_box {
+  width: 100%;
+  height: 100%;
+  padding: 20px 15px;
+  box-sizing: border-box;
+}
+
+.info_box {
+  margin: 0 0 20px;
+}
+
+.info_box > .info {
+  line-height: 18px;
+}
+
+.info_box > .info > span:nth-child(1) {
+  color: #00000099;
+}
+
+.info_box > .info > span:nth-child(2) {
+  color: #000000;
+}
+
+.info_box > .info + .info {
+  margin-top: 10px;
+}
+
+.url_box {
+  margin-bottom: 20px;
+}
+
+.qrcode_box {
+  margin-bottom: 20px;
+}
+
+.url_box > .url {
+  width: 100%;
+  display: flex;
+  align-items: center;
+  border: 1px solid #e7e7e7;
+  border-radius: 4px;
+  height: 35px;
+  padding: 0 7px;
+  box-sizing: border-box;
+}
+
+.url_box > .url > span {
+  font-size: 16px;
+  color: #000000;
+}
+
+.url_box > .url > span:nth-child(1) {
+  width: 100%;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.url_box > .url > span:nth-child(2) {
+  margin-left: auto;
+  border-left: 1px solid #e7e7e7;
+  padding-left: 7px;
+  cursor: pointer;
+  min-width: fit-content;
+}
+
+.url_box > .title,
+.qrcode_box > .title {
+  font-size: 16px;
+  font-weight: 700;
+  margin-bottom: 10px;
+}
+
+.qrcode_box > .qrcode {
+  padding: 7px;
+  border: 1px solid #e7e7e7;
+  width: fit-content;
+  border-radius: 4px;
+  display: flex;
+  align-items: flex-end;
+}
+
+.qrcode_box > .qrcode > span:nth-child(1) {
+  width: 100px;
+  display: block;
+  height: 100px;
+}
+
+.qrcode_box > .qrcode > span:nth-child(2) {
+  background: #f0f2f5;
+  padding: 7px 15px;
+  font-size: 16px;
+  border-radius: 4px;
+  cursor: pointer;
+  color: #000;
+  margin-left: 7px;
+}
+
+.btn_box {
+  display: flex;
+  justify-content: flex-end;
+}
+
+.more {
+  cursor: pointer;
+  color: #0061ff;
+}
+</style>

+ 103 - 24
src/components/pages/test/examine/conpoments/targetPage.vue

@@ -124,7 +124,7 @@
       :visible.sync="diaIframe"
       :append-to-body="true"
       width="95%"
-      :before-close="handleClose"
+      :before-close="handleClose2"
       class="dialog_diy"
     >
       <div style="height: 100%;">
@@ -177,13 +177,21 @@
           <el-table-column
             :show-overflow-tooltip="true"
             prop="tea"
+            :filters="TeachingOptions"
+            :filter-method="filterTea"
             align="center"
             label="教研室"
           >
           </el-table-column>
           <el-table-column prop="score" align="center" label="分值">
           </el-table-column>
-          <el-table-column prop="evaSca" align="center" label="自评分数">
+          <el-table-column
+            :sortable="true"
+            :sort-method="sortEvaMethod"
+            prop="evaSca"
+            align="center"
+            label="自评分数"
+          >
           </el-table-column>
           <el-table-column
             prop="evaMed"
@@ -218,11 +226,19 @@
               </div>
             </template>
           </el-table-column>
-          <el-table-column width="200px" align="center" label="认定分数">
+          <el-table-column
+            :sortable="true"
+            :sort-method="sortCogMethod"
+            prop="cogSco"
+            width="200px"
+            align="center"
+            label="认定分数"
+          >
             <template slot-scope="scope">
               <div class="ScoreStep">
                 <input
                   type="number"
+                  :readonly="TxtDig"
                   v-if="scope.row.judge == 1"
                   style=" color :#A7AAB2;"
                   @blur="Submit(scope.row)"
@@ -250,6 +266,7 @@
               <textarea
                 @blur="Submit2(scope.row)"
                 class="tArea"
+                :readonly="TxtDig"
                 v-model.trim="scope.row.cogSummary"
               />
             </template>
@@ -275,6 +292,7 @@ export default {
       evaScoDigSvg: 0,
       evaScoDigCog: 0,
       evaScoDigPerC: 0,
+      TxtDig: false,
 
       diaIframe: false, //数据来源弹框
       diaScore: false, //查看分数弹框
@@ -1309,7 +1327,8 @@ export default {
       //     ]
       //   }
       // ],
-      tableData: [] //弹框数据
+      tableData: [], //弹框数据
+      TeachingOptions: []
     };
   },
   computed: {},
@@ -1321,11 +1340,39 @@ export default {
   },
   mounted() {
     this.getPageBase();
+    this.getTeaList();
     // console.log(JSON.stringify(this.TeaTabJson));
     // console.log(JSON.stringify(this.tableJsonCon));
   },
 
   methods: {
+    // 获取教研室
+    getTeaList() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+        .then(res => {
+          // return console.log("this.TeachingOptions", res.data[0]);
+          let data = res.data[0];
+          let dataCopy = [];
+
+          data.forEach(e => {
+            let a = {};
+            a.value = e.name;
+            a.text = e.name;
+            dataCopy.push(a);
+          });
+
+          this.TeachingOptions = dataCopy;
+          // console.log("this.TeachingOptions", this.TeachingOptions);
+        })
+        .catch(err => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
     // 获取基础页面数据
     getPageBase() {
       this.tabLoad = true;
@@ -1442,6 +1489,20 @@ export default {
       this.diaIframe = true;
     },
     // ----------------------------首页操作与弹框操作分界线
+
+    // 按照数字大小排序 方法-
+    sortCogMethod(before, after) {
+      return Number(before.cogSco) - Number(after.cogSco);
+    },
+    sortEvaMethod(before, after) {
+      return Number(before.evaSca) - Number(after.evaSca);
+    },
+    // 教研室筛选
+    filterTea(value, row, column) {
+      console.log(value, row, column);
+      const property = column["property"];
+      return row[property].includes(value);
+    },
     // 查看评分
     lookScore(val, oneName, twoName) {
       this.evaScoDig = true;
@@ -1479,6 +1540,9 @@ export default {
             e.cogSummary = ""; //认定概述
             e.score = 0; //分值
             e.judge = 0; //是否填充为默认分数 1:默认等于自评分
+            if (!e.tea) {
+              e.tea = "";
+            }
             e.json.forEach(i => {
               i.children.forEach(k => {
                 if (k.id == this.secondId) {
@@ -1506,6 +1570,7 @@ export default {
           // 获取数据来源
           this.handleScoData();
           this.evaScoDig = false;
+          this.TxtDig = false;
         })
         .catch(error => {
           console.log(error);
@@ -1583,6 +1648,8 @@ export default {
       //   }
       // });
       //#endregion
+      this.TxtDig = true;
+
       if (val.cogSco > val.score) {
         val.cogSco = val.score;
       }
@@ -1616,6 +1683,8 @@ export default {
 
     // 概述提交
     Submit2(val) {
+      this.TxtDig = true;
+
       val.json.forEach(e => {
         e.children.forEach(i => {
           if (i.id == this.secondId) {
@@ -1651,18 +1720,7 @@ export default {
       })
         .then(() => {
           this.evaScoDig = true;
-          let promiseChain = Promise.resolve(); // 初始空Promise
-
-          for (const e of this.tableData) {
-            if (e.judge == 1) {
-              promiseChain = promiseChain.then(() => this.Submit3(e)); // 链式调用Promise
-            }
-          }
-
-          promiseChain.then(() => {
-            this.getSecondData(); // 循环结束后执行getSecondData函数
-            this.$message.success("已保存");
-          });
+          this.handleAllSubmit();
         })
         .catch(() => {
           this.handleData();
@@ -1673,7 +1731,17 @@ export default {
           });
         });
     },
-    Submit3(val) {
+    // 处理一键保存
+    async handleAllSubmit() {
+      for (const e of this.tableData) {
+        if (e.judge == 1) {
+          await this.computedAllSubmit(e);
+        }
+      }
+      this.getSecondData(); // 循环结束后执行getSecondData函数
+      this.$message.success("已保存");
+    },
+    computedAllSubmit(val) {
       if (val.cogSco > val.score) {
         val.cogSco = val.score;
       }
@@ -1695,18 +1763,29 @@ export default {
         }
       ];
       // return console.log(params);
-      this.ajax
-        .post(this.$store.state.api + "updateExamineCogData", params)
-        .then(res => {})
-        .catch(error => {
-          console.log(error);
-        });
+
+      return new Promise(resolve => {
+        this.ajax
+          .post(this.$store.state.api + "updateExamineCogData", params)
+          .then(res => {
+            resolve(res);
+          })
+          .catch(error => {
+            console.log(error);
+          });
+      });
     },
 
-    // 关闭弹框
+    // 关闭评分弹框
     handleClose(done) {
       this.getPageBase();
       done();
+    },
+    // 关闭数据来源弹框
+    handleClose2(done) {
+      this.evaScoDig = true;
+      this.getSecondData();
+      done();
     }
   }
 };

+ 56 - 11
src/components/pages/test/examine/index.vue

@@ -17,21 +17,40 @@
           班主任
         </div>
       </div>
-      <div>
-        <el-select v-model="cutTable" placeholder="请选择">
-          <el-option
-            v-for="item in cutTabOpts"
-            :key="item.value"
-            :label="item.label"
-            :value="item.value"
-          >
-          </el-option>
-        </el-select>
+      <div class="operate">
+        <el-input
+          v-if="cutTable == 1"
+          v-model="teacherName"
+          @change="selectTeaName"
+          placeholder="请输入教师姓名"
+        ></el-input>
+        <div style="margin: 0 20px;">
+          <el-select v-model="cutTable" placeholder="请选择">
+            <el-option
+              v-for="item in cutTabOpts"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value"
+            >
+            </el-option>
+          </el-select>
+        </div>
+        <div v-if="cutTable == 1" class="remindBtn" style="margin-right: 20px;" @click="excelBtn">
+          导出
+        </div>
+        <div v-if="cutTable == 1" class="remindBtn" @click="personBtn">
+          提醒
+        </div>
       </div>
     </div>
     <div class="testCon">
       <targetPage :pType="pType" v-if="cutTable == 0"></targetPage>
-      <personPage :pType="pType" v-if="cutTable == 1"></personPage>
+      <personPage
+        ref="child"
+        :pType="pType"
+        :teacherName="teacherName"
+        v-if="cutTable == 1"
+      ></personPage>
     </div>
   </div>
 </template>
@@ -49,6 +68,7 @@ export default {
     return {
       pType: 2,
       cutTable: 0,
+      teacherName: "",
       cutTabOpts: [
         {
           value: 0,
@@ -64,6 +84,15 @@ export default {
   methods: {
     cutPage(e) {
       this.pType = e;
+    },
+    selectTeaName() {
+      this.$refs.child.getData();
+    },
+    excelBtn(){
+      this.$refs.child.getExcel();
+    },
+    personBtn() {
+      this.$refs.child.remindExamine();
     }
   }
 };
@@ -102,4 +131,20 @@ export default {
   box-sizing: border-box;
   padding: 20px;
 }
+.operate {
+  display: flex;
+}
+.operate >>> .el-input {
+  width: 200px !important;
+}
+.operate > .remindBtn {
+  background: #409eff;
+  padding: 10px 15px;
+  box-sizing: border-box;
+  width: 90px;
+  text-align: center;
+  border-radius: 4px;
+  cursor: pointer;
+  color: #fff;
+}
 </style>

+ 1 - 1
src/components/pages/test/file/wPdf.vue

@@ -6,7 +6,7 @@
                 :src="'https://cloud.cocorobo.cn/pdf.js/web/viewer.html?file=' + encodeURIComponent(url)"></iframe>
         </div>
         <span slot="footer" class="dialog-footer">
-            <el-button @click="dialogVisiblePdf = false;">关 闭</el-button>
+            <el-button @click="close">关 闭</el-button>
         </span>
     </el-dialog>
 </template>

+ 1 - 1
src/components/pages/test/file/wPdf2.vue

@@ -6,7 +6,7 @@
                 :src="'https://cloud.cocorobo.cn/pdf.js/web/viewer.html?file=' + encodeURIComponent(url)"></iframe>
         </div>
         <span slot="footer" class="dialog-footer">
-            <el-button @click="dialogVisiblePdf = false;">关 闭</el-button>
+            <el-button @click="close">关 闭</el-button>
         </span>
     </el-dialog>
 </template>

+ 10 - 3
src/components/pages/test/index.vue

@@ -25,7 +25,7 @@
             <span :class="{ active: cutNumber == 1}" v-if="examineData.length" @click="cutNumber = 1">年度考核</span>
         </div>
         <div class="bbox" v-if="cutNumber==0">
-            <div class="test_data_box" v-loading="isLoadingData">
+            <div v-if="!oidArray.includes(oid)" class="test_data_box" v-loading="isLoadingData">
                 <div class="data_box">
                     <div class="left">
                         <div class="title">表单状态总览</div>
@@ -80,6 +80,7 @@
             </div>
             <div class="search_nav">
                 <div class="right">
+                    <span :class="{ active: stype == 3 }" v-show="orgArray2.includes(org) || oidArray.includes(oid)" @click="checkDataType(3)">数据汇总</span>
                     <span :class="{ active: stype == 1 }" @click="checkDataType(1)">按问卷查看</span>
                     <span :class="{ active: stype == 2 }" @click="checkDataType(2)">按人员查看</span>
                 </div>
@@ -123,6 +124,7 @@
                 </div>
             </div>
             <div class="pb_content_body" style="height: 100%;width: 100%;">
+                <aggregate v-if="stype == 3"></aggregate>
                 <div class="student_table" v-loading="isLoading" v-if="stype == 1 && stype2 == 1">
                     <div class="course_box">
                         <div class="test_box" v-for="(item, index) in course" :key="index">
@@ -394,9 +396,10 @@ import randar1 from "./data/randar1.vue";
 import randar2 from "./data/randar2.vue";
 import shareBox from './shareBox/index.vue'
 import examine from './examine/index.vue'
+import aggregate from './aggregate/index'
 export default {
     name: 'test',
-    components: { EditorBar, CourseProblem, pie1, pie2, randar1, randar2, shareBox, examine },
+    components: { EditorBar, CourseProblem, pie1, pie2, randar1, randar2, shareBox, examine, aggregate },
     data() {
         return {
             examineData: [],
@@ -421,7 +424,8 @@ export default {
             org: this.$route.query.org,
             role: this.$route.query.role,
             orgArray: ["150e3120-9195-11ed-b13d-005056b86db5"],
-            oidArray: [],
+            orgArray2: ["0fec3a8a-ad04-11ed-b13d-005056b86db5"],
+            oidArray: ["d67940a5-510c-40ea-9c9a-2631ab03013a"],
             Juri: "",
             groupList: [],
             JuriList: [],
@@ -1303,6 +1307,9 @@ export default {
     mounted() {
         this.getPageBase()
         console.log(2);
+        if (this.orgArray2.includes(this.org) || this.oidArray.includes(this.oid)) {
+            this.stype = 3
+        }
         if (this.role == '1') {
             this.groupA = '0'
         }

+ 19 - 2
src/components/pages/testPerson/examine/index.vue

@@ -72,7 +72,13 @@
                         v-if="allData.type * 1 != 2"
                         type="number"
                         @blur="
-                          saveTab(k.sco1 > k.score ? (k.sco1 = k.score) : '')
+                          saveTab(
+                            k.sco1 > k.score
+                              ? (k.sco1 = k.score)
+                              : '' || k.sco1 < 0
+                              ? (k.sco1 = '')
+                              : ''
+                          )
                         "
                         v-model="k.sco1"
                       />
@@ -226,23 +232,34 @@ export default {
       // }
       let judgeNum = 0;
 
+      // i.type == 1 这个用来判断 科组评价的因为最后两个教师不能打分所以type设为2,下面的循环将他们两个排除出去
       this.PageBaseData.forEach(e => {
         e.children.forEach(i => {
           if (i.type == 1) {
             if (!i.sco1) {
               judgeNum = 1;
             }
+            if (i.sco1 * 1 < 0) {
+              judgeNum = 2;
+            }
           }
         });
       });
 
-      if (judgeNum != 0) {
+      if (judgeNum == 1) {
         this.$message({
           message: "请将【自评】分数列填写完整后再提交。",
           type: "warning"
         });
         return;
       }
+      if (judgeNum == 2) {
+        this.$message({
+          message: "自评分数不可低于0,请检查后重新输入。",
+          type: "warning"
+        });
+        return;
+      }
 
       for (const e of this.PageBaseData) {
         for (const k of e.children) {

+ 3 - 2
src/components/pages/testPerson/info/index.vue

@@ -20,13 +20,13 @@
             <span>{{info.classname ? info.classname : '暂无'}}</span>
           </el-tooltip>
         </div>
-        <div class="i_bottom_span">
+        <div v-if="!oidArray.includes(oid)" class="i_bottom_span">
           <span>学科</span>
           <el-tooltip :content="info.subject ? info.subject : '暂无'" placement="top" effect="dark">
             <span>{{info.subject ? info.subject : '暂无'}}</span>
           </el-tooltip>
         </div>
-        <div class="i_bottom_span">
+        <div v-if="!oidArray.includes(oid)" class="i_bottom_span">
           <span>职务</span>
           <el-tooltip :content="info.job ? info.job : '暂无'" placement="top" effect="dark">
             <span>{{info.job ? info.job : '暂无'}}</span>
@@ -61,6 +61,7 @@ export default {
       avator: avator,
       info: {},
       dialogVisibleInfo:false,
+      oidArray: ["d67940a5-510c-40ea-9c9a-2631ab03013a"]
     }
   },
   watch: {

+ 25 - 4
src/components/pages/testPerson/info/infoDialog/index.vue

@@ -27,13 +27,13 @@
                         </el-select>
                     </div>
                 </div>
-                <div class="info_span">
+                <div v-if="!oidArray.includes(oid)" class="info_span">
                     <span>学科:</span>
                     <div>
                         <el-input v-model="info.subject" placeholder="请输入学科"></el-input>
                     </div>
                 </div>
-                <div class="info_span">
+                <div v-if="!oidArray.includes(oid)" class="info_span">
                     <span>职务:</span>
                     <div>
                         <el-input v-model="info.job" placeholder="请输入职务"></el-input>
@@ -75,7 +75,7 @@ export default {
         dialogVisibleInfo(newVal) {
             if (newVal) {
                 this.getClass2();
-                this.getData();
+
             }
         }
     },
@@ -100,6 +100,7 @@ export default {
             info: {},
             imgLoading: false,
             classJuri: [],
+            oidArray: ["d67940a5-510c-40ea-9c9a-2631ab03013a"]
         };
     },
     methods: {
@@ -144,12 +145,31 @@ export default {
                 .then((res) => {
                     this.info = res.data[0][0]
                     this.info.teacherOffice = []
-                    this.info.teacherOffice = this.info.cclassid.split(',')
+                    let array = []
+                    for(var i = 0; i < this.classJuri.length; i++){
+                        array.push(this.classJuri[i].id)
+                    }
+                    this.info.teacherOffice = this.arrayToArray(this.info.cclassid.split(','), array)
                 })
                 .catch((err) => {
                     console.error(err);
                 });
         },
+        arrayToArray(arrayo, arrayt) {
+            let array1 = arrayo;
+            let array2 = arrayt;
+
+            let commonElements = [];
+
+            for (let i = 0; i < array1.length; i++) {
+                for (let j = 0; j < array2.length; j++) {
+                if (array1[i] === array2[j]) {
+                    commonElements.push(array1[i]);
+                }
+                }
+            }
+            return commonElements;
+        },
         addImg(e) {
             var el = e.currentTarget;
             el.getElementsByTagName("input")[0].click();
@@ -232,6 +252,7 @@ export default {
                 .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
                 .then((res) => {
                     this.classJuri = res.data[0];
+                    this.getData();
                 })
                 .catch((err) => {
                     this.isLoading = false;

Някои файлове не бяха показани, защото твърде много файлове са промени