浏览代码

Merge branch 'alpha'

lsc 1 年之前
父节点
当前提交
64a2f5d450
共有 36 个文件被更改,包括 4477 次插入2330 次删除
  1. 1 1
      dist/index.html
  2. 0 0
      dist/static/css/app.a4e6658656b473025c568c9c66d9ad2f.css
  3. 0 0
      dist/static/css/app.a4e6658656b473025c568c9c66d9ad2f.css.map
  4. 0 0
      dist/static/css/app.ae920e25e60c11b1e637bced5202eb0a.css
  5. 0 0
      dist/static/css/app.ae920e25e60c11b1e637bced5202eb0a.css.map
  6. 二进制
      dist/static/img/model6-6.1c5ef38.png
  7. 二进制
      dist/static/img/model6-7-1.f29bdb4.png
  8. 二进制
      dist/static/img/model6-7-2.4d419cf.png
  9. 0 0
      dist/static/js/app.7fc3e9e58daf85d437b0.js
  10. 0 0
      dist/static/js/app.7fc3e9e58daf85d437b0.js.map
  11. 0 0
      dist/static/js/manifest.571c38d63f24b1ae9e16.js.map
  12. 0 0
      src/assets/css/SourceHanSans-Regular.otf
  13. 29 0
      src/assets/css/button.css
  14. 二进制
      src/assets/icon/ppt/model6-4.png
  15. 二进制
      src/assets/icon/ppt/model6-6.png
  16. 二进制
      src/assets/icon/ppt/model6-7-1.png
  17. 二进制
      src/assets/icon/ppt/model6-7-2.png
  18. 427 72
      src/components/pages/aiAddCourse/addCourse.vue
  19. 556 715
      src/components/pages/aiAddCourse/addCourse3.vue
  20. 27 26
      src/components/pages/aiAddCourse/aiBox.vue
  21. 251 87
      src/components/pages/aiAddCourse/aiCreateDialog.vue
  22. 152 39
      src/components/pages/aiAddCourse/aiCreateVideoDialog.vue
  23. 1 0
      src/components/pages/classroomObservation/components/analysisItem.vue
  24. 1 0
      src/components/pages/classroomObservation/components/baseMessage.vue
  25. 3 1
      src/components/pages/classroomObservation/components/chatArea.vue
  26. 14 1
      src/components/pages/components/studentReport.vue
  27. 1 1
      src/components/pages/components/vpdf.vue
  28. 14 2
      src/components/pages/components/workData.vue
  29. 255 130
      src/components/pages/components/worksDetail2.vue
  30. 54 51
      src/components/pages/components/worksDetail3.vue
  31. 1299 1189
      src/components/pages/teacherOffice/index.vue
  32. 1359 0
      src/components/pages/teacherOffice/teacherType.vue
  33. 5 0
      src/components/pages/test/index.vue
  34. 19 15
      src/components/pages/works.vue
  35. 9 0
      src/router/index.js
  36. 二进制
      static/SourceHanSans-Regular.otf

+ 1 - 1
dist/index.html

@@ -32,7 +32,7 @@
       width: 100%;
       background: #e6eaf0;
       font-family: '黑体';
-    }</style><link href=./static/css/app.a4e6658656b473025c568c9c66d9ad2f.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.ee476e38463461edca63.js></script><script type=text/javascript src=./static/js/app.70e0f8ef6ca58c4eae67.js></script></body></html><script>function stopSafari() {
+    }</style><link href=./static/css/app.ae920e25e60c11b1e637bced5202eb0a.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.ee476e38463461edca63.js></script><script type=text/javascript src=./static/js/app.7fc3e9e58daf85d437b0.js></script></body></html><script>function stopSafari() {
     //阻止safari浏览器双击放大功能
     let lastTouchEnd = 0  //更新手指弹起的时间
     document.documentElement.addEventListener("touchstart", function (event) {

文件差异内容过多而无法显示
+ 0 - 0
dist/static/css/app.a4e6658656b473025c568c9c66d9ad2f.css


文件差异内容过多而无法显示
+ 0 - 0
dist/static/css/app.a4e6658656b473025c568c9c66d9ad2f.css.map


文件差异内容过多而无法显示
+ 0 - 0
dist/static/css/app.ae920e25e60c11b1e637bced5202eb0a.css


文件差异内容过多而无法显示
+ 0 - 0
dist/static/css/app.ae920e25e60c11b1e637bced5202eb0a.css.map


二进制
dist/static/img/model6-6.1c5ef38.png


二进制
dist/static/img/model6-7-1.f29bdb4.png


二进制
dist/static/img/model6-7-2.4d419cf.png


文件差异内容过多而无法显示
+ 0 - 0
dist/static/js/app.7fc3e9e58daf85d437b0.js


文件差异内容过多而无法显示
+ 0 - 0
dist/static/js/app.7fc3e9e58daf85d437b0.js.map


文件差异内容过多而无法显示
+ 0 - 0
dist/static/js/manifest.571c38d63f24b1ae9e16.js.map


+ 0 - 0
dist/static/SourceHanSans-Regular.otf → src/assets/css/SourceHanSans-Regular.otf


+ 29 - 0
src/assets/css/button.css

@@ -25,6 +25,35 @@
   margin-left: 20px;
 }
 
+.c_pub_button_confirm2 {
+  color: #000;
+  background-color: #d8d8d8;
+  padding: 0 24px;
+  font-size: 14px;
+  min-width: 64px;
+  font-weight: 500;
+  border-radius: 4px;
+  box-sizing: border-box;
+  border: none;
+  cursor: pointer;
+  transition: all 0.2s ease-in-out;
+  height: 36px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  line-height: 1;
+}
+
+.c_pub_button_confirm2:hover {
+  background-color: #3681FC !important;
+  color: #fff !important;
+}
+
+.c_pub_button_confirm2 + .c_pub_button_confirm2 {
+  margin-left: 20px;
+}
+
+
 .c_pub_button_add {
   color: #0061FF;
   background-color: #fff;

二进制
src/assets/icon/ppt/model6-4.png


二进制
src/assets/icon/ppt/model6-6.png


二进制
src/assets/icon/ppt/model6-7-1.png


二进制
src/assets/icon/ppt/model6-7-2.png


文件差异内容过多而无法显示
+ 427 - 72
src/components/pages/aiAddCourse/addCourse.vue


文件差异内容过多而无法显示
+ 556 - 715
src/components/pages/aiAddCourse/addCourse3.vue


+ 27 - 26
src/components/pages/aiAddCourse/aiBox.vue

@@ -387,35 +387,36 @@ export default {
         this.$nextTick(() => {
           this.$refs.chatDialog.scrollTop = this.$refs.chatDialog.scrollHeight;
         });
-        // let params = JSON.stringify({
-        //   model: "gpt-3.5-turbo",
-        //   temperature: 0,
-        //   max_tokens: 4096,
-        //   top_p: 1,
-        //   frequency_penalty: 0,
-        //   presence_penalty: 0,
-        //   messages: [{ role: "user", content: message }],
-        //   uid: _uuid,
-        //   mind_map_question: ""
-        // });
         let params = JSON.stringify({
-          message: {
-              anthropic_version: "bedrock-2023-05-31",
-              max_tokens: 4096,
-              temperature: 0,
-              top_p: 1,
-              messages:  [{
-                  "role": "user",
-                  "content": message
-              }] , 
-          },
+          // model: "gpt-3.5-turbo",
+          model: 'gpt-4o-2024-08-06',
+          temperature: 0,
+          max_tokens: 4096,
+          top_p: 1,
+          frequency_penalty: 0,
+          presence_penalty: 0,
+          messages: [{ role: "user", content: message }],
           uid: _uuid,
-          model: "Claude 3 Sonnet" // Claude 3 Sonnet或者Claude 3 Haiku
+          mind_map_question: ""
         });
+        // let params = JSON.stringify({
+        //   message: {
+        //       anthropic_version: "bedrock-2023-05-31",
+        //       max_tokens: 4096,
+        //       temperature: 0,
+        //       top_p: 1,
+        //       messages:  [{
+        //           "role": "user",
+        //           "content": message
+        //       }] , 
+        //   },
+        //   uid: _uuid,
+        //   model: "Claude 3 Sonnet" // Claude 3 Sonnet或者Claude 3 Haiku
+        // });
         this.courseText = "";
 
-        // this.ajax.post("https://gpt4.cocorobo.cn/chat", params).then(res => {
-        this.ajax.post("https://claude3.cocorobo.cn/chat", params).then(res => {
+        this.ajax.post("https://gpt4.cocorobo.cn/chat", params).then(res => {
+        // this.ajax.post("https://claude3.cocorobo.cn/chat", params).then(res => {
             if (res.data.FunctionResponse.result == "发送成功") {
             } else {
               this.$message.warning(res.data.FunctionResponse.result);
@@ -428,8 +429,8 @@ export default {
       }
     },
     getAiContent(_uid) {
-      // let _source = new EventSource(`https://gpt4.cocorobo.cn/stream/${_uid}`); //http://gpt4.cocorobo.cn:8011/stream/     https://gpt4.cocorobo.cn/stream/
-      let _source = new EventSource(`https://claude3.cocorobo.cn/streamChat/${_uid}`); //http://gpt4.cocorobo.cn:8011/stream/     https://gpt4.cocorobo.cn/stream/
+      let _source = new EventSource(`https://gpt4.cocorobo.cn/stream/${_uid}`); //http://gpt4.cocorobo.cn:8011/stream/     https://gpt4.cocorobo.cn/stream/
+      // let _source = new EventSource(`https://claude3.cocorobo.cn/streamChat/${_uid}`); //http://gpt4.cocorobo.cn:8011/stream/     https://gpt4.cocorobo.cn/stream/
       let _allText = "";
       let _mdText = "";
       const md = new MarkdownIt();

+ 251 - 87
src/components/pages/aiAddCourse/aiCreateDialog.vue

@@ -134,6 +134,7 @@ export default {
                             w: "90%",
                             color: '17094F',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -147,6 +148,7 @@ export default {
                                 color: '17094F',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -155,6 +157,7 @@ export default {
                                 w: "90%",
                                 color: "222222",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -163,7 +166,8 @@ export default {
                                 w: "60%",
                                 color: "444444",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         }
                     ],
@@ -175,6 +179,7 @@ export default {
                             w: "90%",
                             color: '17094F',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     }
@@ -189,6 +194,7 @@ export default {
                             w: "90%",
                             color: '052B37',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -202,6 +208,7 @@ export default {
                                 color: '052B37',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -210,6 +217,7 @@ export default {
                                 w: "90%",
                                 color: "222222",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -218,7 +226,8 @@ export default {
                                 w: "60%",
                                 color: "444444",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         }
                     ],
@@ -230,6 +239,7 @@ export default {
                             w: "90%",
                             color: '052B37',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     }
@@ -244,6 +254,7 @@ export default {
                             w: "90%",
                             color: '1D5869',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -257,6 +268,7 @@ export default {
                                 color: '1D5869',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -265,6 +277,7 @@ export default {
                                 w: "90%",
                                 color: "222222",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -273,7 +286,8 @@ export default {
                                 w: "60%",
                                 color: "444444",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         }
                     ],
@@ -285,6 +299,7 @@ export default {
                             w: "90%",
                             color: '1D5869',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     }
@@ -299,6 +314,7 @@ export default {
                             w: "90%",
                             color: '372213',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -312,6 +328,7 @@ export default {
                                 color: '372213',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -320,6 +337,7 @@ export default {
                                 w: "90%",
                                 color: "222222",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -328,7 +346,8 @@ export default {
                                 w: "60%",
                                 color: "444444",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         }
                     ],
@@ -340,6 +359,7 @@ export default {
                             w: "90%",
                             color: '372213',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -355,6 +375,7 @@ export default {
                             w: "90%",
                             color: '674D40',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -368,6 +389,7 @@ export default {
                                 color: '674D40',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -376,6 +398,7 @@ export default {
                                 w: "90%",
                                 color: "222222",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -384,7 +407,8 @@ export default {
                                 w: "60%",
                                 color: "444444",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         }
                     ],
@@ -396,6 +420,7 @@ export default {
                             w: "90%",
                             color: '674D40',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -411,6 +436,7 @@ export default {
                             bold: true,
                             color: 'EA7A93',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -424,6 +450,7 @@ export default {
                                 color: '4F73DA',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             subTitle: {
@@ -432,6 +459,7 @@ export default {
                                 w: "90%",
                                 color: "333333",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "center",
                             },
                             content: {
@@ -440,7 +468,8 @@ export default {
                                 w: "60%",
                                 color: "333333",
                                 fontSize: 18, // 字号
-                                align: "center",
+                                fontFace: '黑体',
+                                align: "left",
                             }
                         },//内容页1
                         {
@@ -452,6 +481,7 @@ export default {
                                 color: 'ffffff',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             subTitle: {
@@ -460,6 +490,7 @@ export default {
                                 w: "30%",
                                 color: "ffffff",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             content: {
@@ -468,6 +499,7 @@ export default {
                                 w: "45%",
                                 color: "333333",
                                 fontSize: 18, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             square: {
@@ -494,6 +526,7 @@ export default {
                                 color: '4F73DA',
                                 bold: true,
                                 fontSize: 35, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             subTitle: {
@@ -502,6 +535,7 @@ export default {
                                 w: "60%",
                                 color: "333333",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             content: {
@@ -510,6 +544,7 @@ export default {
                                 w: "60%",
                                 color: "333333",
                                 fontSize: 18, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             image: {
@@ -521,6 +556,47 @@ export default {
                                 path: require('../../../assets/icon/ppt/model6-3.png')
                             },
                         },//内容页3
+                        {
+                            img: require('../../../assets/icon/ppt/model6-2.png'),
+                            title: {
+                                x: "10%", // 横坐标
+                                y: "4%",
+                                h: 0.75,
+                                w: "80%",
+                                color: 'ffffff',
+                                fill: { color: "4F73DA"},
+                                bold: true,
+                                fontSize: 35, // 字号
+                                fontFace: '黑体',
+                                align: "center",
+                            },
+                            subTitle: {
+                                x: "10%", // 横坐标
+                                y: 1.5,
+                                w: "80%",
+                                color: "333333",
+                                fontSize: 20, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            content: {
+                                x: "10%", // 横坐标
+                                y: 2.3,
+                                w: "80%",
+                                color: "333333",
+                                fontSize: 18, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            image: {
+                                x: "2.5%",
+                                y: "10%",
+                                w: "95%",
+                                h: "80%",
+                                sizing: "contain",
+                                path: require('../../../assets/icon/ppt/model6-4.png')
+                            },
+                        },//内容页4
                         {
                             img: require('../../../assets/icon/ppt/model6-2.png'),
                             title: {
@@ -531,6 +607,7 @@ export default {
                                 color: 'ffffff',
                                 bold: true,
                                 fontSize: 30, // 字号
+                                fontFace: '黑体',
                                 align: "right",
                                 fill: { color: "4F73DA"},
                                 margin: 10,
@@ -541,6 +618,7 @@ export default {
                                 w: "53%",
                                 color: "333333",
                                 fontSize: 20, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             content: {
@@ -549,6 +627,7 @@ export default {
                                 w: "53%",
                                 color: "333333",
                                 fontSize: 18, // 字号
+                                fontFace: '黑体',
                                 align: "left",
                             },
                             square: {
@@ -563,6 +642,86 @@ export default {
                                 }
                             },
                         }, //内容页5
+                        {
+                            img: require('../../../assets/icon/ppt/model6-2.png'),
+                            title: {
+                                x: "17%", // 横坐标
+                                y: "20%",
+                                h: 0.75,
+                                w: "66%",
+                                color: 'ffffff',
+                                fill: { color: "4F73DA"},
+                                bold: true,
+                                fontSize: 35, // 字号
+                                fontFace: '黑体',
+                                align: "center",
+                            },
+                            subTitle: {
+                                x: "5%", // 横坐标
+                                y: 3,
+                                w: "90%",
+                                color: "333333",
+                                fontSize: 20, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            content: {
+                                x: "5%", // 横坐标
+                                y: 3.8,
+                                w: "90%",
+                                color: "333333",
+                                fontSize: 18, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            image: {
+                                x: 0,
+                                y: 0,
+                                w: "100%",
+                                h: "45%",
+                                sizing: "contain",
+                                path: require('../../../assets/icon/ppt/model6-6.png')
+                            },
+                        },//内容页6
+                        {
+                            img: require('../../../assets/icon/ppt/model6-7-1.png'),
+                            title: {
+                                x: "45%", // 横坐标
+                                y: 1.3,
+                                w: "50%",
+                                color: '4F73DA',
+                                bold: true,
+                                fontSize: 35, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            subTitle: {
+                                x: "45%", // 横坐标
+                                y: 2,
+                                w: "50%",
+                                color: "333333",
+                                fontSize: 20, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            content: {
+                                x: "45%", // 横坐标
+                                y: 3.2,
+                                w: "50%",
+                                color: "333333",
+                                fontSize: 18, // 字号
+                                fontFace: '黑体',
+                                align: "left",
+                            },
+                            image: {
+                                x: "20%",
+                                y: 0,
+                                w: "80%",
+                                h: "100%",
+                                sizing: "contain",
+                                path: require('../../../assets/icon/ppt/model6-7-2.png')
+                            },
+                        },//内容页7
                     ],
                     imgEnd: {
                         img: require('../../../assets/icon/ppt/model6-1-2.png'),
@@ -572,6 +731,7 @@ export default {
                             w: "60%",
                             color: 'EA7A93',
                             fontSize: 38,
+                            fontFace: '黑体',
                             align: "center",
                         }
                     },
@@ -586,7 +746,87 @@ export default {
                 this.loading = false;
                 this.aiGet(2);
                 // this.templateIndex = 5
-                // this.createPpt();
+                // let array = [
+                // {
+                //     "page": 1,
+                //     "title": "引入阶段",
+                //     "task": "课程背景",
+                //     "points": "同学们,让我们一起了解一下这门有趣的熊猫课程吧!今天,我们将探索熊猫的生活环境,并尝试去理解这些环境是如何影响熊猫的生存的。"
+                // },
+                // {
+                //     "page": 2,
+                //     "title": "引入阶段",
+                //     "task": "整体目标和任务要求",
+                //     "points": "这门课程的主要目标是让大家了解熊猫生活的环境以及生存所需的关键因素。我们将完成一个任务,具体要求是观察、记录、绘制和制作模型哦!"
+                // },
+                // {
+                //     "page": 3,
+                //     "title": "引入阶段",
+                //     "task": "驱动性问题",
+                //     "points": "大家思考一下这样一个问题:‘熊猫的生活环境对它们的生存有何重要影响?’ 我们接下去的活动将帮助大家找到答案。"
+                // },
+                // {
+                //     "page": 4,
+                //     "title": "引入阶段",
+                //     "task": "观察与记录技巧",
+                //     "points": "今天我们会运用图片和视频,来帮助大家观察熊猫栖息地和它们所吃的竹子等特征。细心观察,并将所见的特征记录下来是非常重要的技能哦!"
+                // },
+                // {
+                //     "page": 5,
+                //     "title": "探究阶段",
+                //     "task": "绘图工具和材料",
+                //     "points": "现在我们分发绘图工具和材料,来学习基本的绘图和建模技巧吧!熟练掌握这些工具会帮助我们更好地记录和展示我们的观察结果。"
+                // },
+                // {
+                //     "page": 6,
+                //     "title": "探究阶段",
+                //     "task": "观察和记录特征",
+                //     "points": "让我们好好观察一下身边的常见物体,把它们的特征记录下来。这个过程会训练你们的观察力和手眼协调能力。"
+                // },
+                // {
+                //     "page": 7,
+                //     "title": "探究阶段",
+                //     "task": "转换二维图像",
+                //     "points": "接下来,我们要把记录的三维物体转化为二维图像。这个步骤非常有趣,大家可以尽情发挥自己的绘画天赋哦!"
+                // },
+                // {
+                //     "page": 8,
+                //     "title": "探究阶段",
+                //     "task": "三维模型制作",
+                //     "points": "现在我们提供一些简单的材料,比如纸张和纸板,示范一下如何制作三维模型。记住,比例和结构是模型制作的关键!"
+                // },
+                // {
+                //     "page": 9,
+                //     "title": "评估与反馈阶段",
+                //     "task": "评估和检查",
+                //     "points": "大家完成了任务后,我们来检查和评估你们的二维图像和三维模型。确保它们的结构合理、比例协调。"
+                // },
+                // {
+                //     "page": 10,
+                //     "title": "评估与反馈阶段",
+                //     "task": "提出改进建议",
+                //     "points": "针对你们完成的作品,我们会提出一些改进建议。大家也可以相互评价,分享制作经验,这样可以互相学习哦!"
+                // },
+                // {
+                //     "page": 11,
+                //     "title": "评估与反馈阶段",
+                //     "task": "任务总结",
+                //     "points": "最后,我们要总结这次任务的执行情况,并表扬表现特别突出的同学。希望大家都能有所收获,并继续努力!"
+                // },
+                // {
+                //     "page": 12,
+                //     "title": "练习",
+                //     "task": "练习1:二维图像绘制",
+                //     "points": "选择一件日常物品(如书本、杯子),观察其特征,尝试通过手绘将其转换为二维图像。示例:通过绘制书本的正面、侧面和顶面图,展示其主要特征和比例关系。"
+                // },
+                // {
+                //     "page": 13,
+                //     "title": "练习",
+                //     "task": "练习2:三维模型制作",
+                //     "points": "使用纸张和纸板制作简单的模型,比如一个基本的房子或盒子。关注其结构和比例哦! 示例:通过折叠和粘贴纸张,制作一个四面体,确保各个面的比例协调,结构稳定。"
+                // }
+                // ]
+                // this.createPpt(array);
 
             }
         },
@@ -797,6 +1037,7 @@ ${mclass.length ? "面向年级:" + mclass.join(",") : ""}
                 session_name: uuidv4(),
                 userId: this.userid,
                 file_ids: fileid.length ? [...fileid] : "",
+                model: 'gpt-4o-2024-08-06',
             };
             _this.loading = true;
             this.ajax
@@ -863,86 +1104,6 @@ ${mclass.length ? "面向年级:" + mclass.join(",") : ""}
         },
         createPpt(arr) {
             let array = arr
-            // let array = [
-            //     {
-            //         "page": 1,
-            //         "title": "引入阶段",
-            //         "task": "课程背景",
-            //         "points": "同学们,让我们一起了解一下这门有趣的熊猫课程吧!今天,我们将探索熊猫的生活环境,并尝试去理解这些环境是如何影响熊猫的生存的。"
-            //     },
-            //     {
-            //         "page": 2,
-            //         "title": "引入阶段",
-            //         "task": "整体目标和任务要求",
-            //         "points": "这门课程的主要目标是让大家了解熊猫生活的环境以及生存所需的关键因素。我们将完成一个任务,具体要求是观察、记录、绘制和制作模型哦!"
-            //     },
-            //     {
-            //         "page": 3,
-            //         "title": "引入阶段",
-            //         "task": "驱动性问题",
-            //         "points": "大家思考一下这样一个问题:‘熊猫的生活环境对它们的生存有何重要影响?’ 我们接下去的活动将帮助大家找到答案。"
-            //     },
-            //     {
-            //         "page": 4,
-            //         "title": "引入阶段",
-            //         "task": "观察与记录技巧",
-            //         "points": "今天我们会运用图片和视频,来帮助大家观察熊猫栖息地和它们所吃的竹子等特征。细心观察,并将所见的特征记录下来是非常重要的技能哦!"
-            //     },
-            //     {
-            //         "page": 5,
-            //         "title": "探究阶段",
-            //         "task": "绘图工具和材料",
-            //         "points": "现在我们分发绘图工具和材料,来学习基本的绘图和建模技巧吧!熟练掌握这些工具会帮助我们更好地记录和展示我们的观察结果。"
-            //     },
-            //     {
-            //         "page": 6,
-            //         "title": "探究阶段",
-            //         "task": "观察和记录特征",
-            //         "points": "让我们好好观察一下身边的常见物体,把它们的特征记录下来。这个过程会训练你们的观察力和手眼协调能力。"
-            //     },
-            //     {
-            //         "page": 7,
-            //         "title": "探究阶段",
-            //         "task": "转换二维图像",
-            //         "points": "接下来,我们要把记录的三维物体转化为二维图像。这个步骤非常有趣,大家可以尽情发挥自己的绘画天赋哦!"
-            //     },
-            //     {
-            //         "page": 8,
-            //         "title": "探究阶段",
-            //         "task": "三维模型制作",
-            //         "points": "现在我们提供一些简单的材料,比如纸张和纸板,示范一下如何制作三维模型。记住,比例和结构是模型制作的关键!"
-            //     },
-            //     {
-            //         "page": 9,
-            //         "title": "评估与反馈阶段",
-            //         "task": "评估和检查",
-            //         "points": "大家完成了任务后,我们来检查和评估你们的二维图像和三维模型。确保它们的结构合理、比例协调。"
-            //     },
-            //     {
-            //         "page": 10,
-            //         "title": "评估与反馈阶段",
-            //         "task": "提出改进建议",
-            //         "points": "针对你们完成的作品,我们会提出一些改进建议。大家也可以相互评价,分享制作经验,这样可以互相学习哦!"
-            //     },
-            //     {
-            //         "page": 11,
-            //         "title": "评估与反馈阶段",
-            //         "task": "任务总结",
-            //         "points": "最后,我们要总结这次任务的执行情况,并表扬表现特别突出的同学。希望大家都能有所收获,并继续努力!"
-            //     },
-            //     {
-            //         "page": 12,
-            //         "title": "练习",
-            //         "task": "练习1:二维图像绘制",
-            //         "points": "选择一件日常物品(如书本、杯子),观察其特征,尝试通过手绘将其转换为二维图像。示例:通过绘制书本的正面、侧面和顶面图,展示其主要特征和比例关系。"
-            //     },
-            //     {
-            //         "page": 13,
-            //         "title": "练习",
-            //         "task": "练习2:三维模型制作",
-            //         "points": "使用纸张和纸板制作简单的模型,比如一个基本的房子或盒子。关注其结构和比例哦! 示例:通过折叠和粘贴纸张,制作一个四面体,确保各个面的比例协调,结构稳定。"
-            //     }
-            // ]
             // 1. 创建PPT
             const pres = new Pptxgen();
             const _slideTou = pres.addSlide();
@@ -981,6 +1142,9 @@ ${mclass.length ? "面向年级:" + mclass.join(",") : ""}
                 let tempResult3 = '';
                 if (typeof array[i].points == 'object') {
                     if (Array.isArray(array[i].points)) {
+                        for(var k = 0; k < array[i].points.length; k++){
+                            array[i].points[k] = '· '+array[i].points[k]
+                        }
                         tempResult3 = array[i].points.join('\n')
                     } else {
                         tempResult3 = JSON.stringify(array[i].points)

+ 152 - 39
src/components/pages/aiAddCourse/aiCreateVideoDialog.vue

@@ -3,10 +3,10 @@
         :before-close="handleClose" class="dialog_diy">
         <div style="height: 500px;padding:15px" v-loading="loading" element-loading-text="小可正在努力生成中,请稍等...">
             <div style="position: relative; width: 100%;height: 40px;margin-bottom: 10px;">
-                <el-input class="inputC" style="height: 100%;" placeholder="搜索视频关键字" v-model="detail"
-                @keyup.enter.native="aiGet()"></el-input>
-                <div class="search_img" @click="aiGet" style="right: 10px">
-                <img src="../../../assets/icon/search.png" alt />
+                <el-input class="inputC" style="height: 100%;" placeholder="搜索视频关键字(如需搜索多个可“,”隔开)" v-model="detail"
+                    @keyup.enter.native="searchA()"></el-input>
+                <div class="search_img" @click="searchA" style="right: 10px">
+                    <img src="../../../assets/icon/search.png" alt />
                 </div>
             </div>
             <div class="Box">
@@ -19,13 +19,13 @@
                         <span @click="checkUrl(item.snippet.title,item.id.videoId)">加入</span>
                     </div>
                 </div> -->
-                <div class="video_box video_box2" v-for="(item,index) in data" :key="index">
+                <div class="video_box video_box2" v-for="(item, index) in data" :key="index">
                     <!-- <img :src="item.pic" /> -->
-                    <span class="name" v-html="item.title"></span> 
-                    <span class="detail">{{ item.description }}</span> 
+                    <span class="name" v-html="item.title"></span>
+                    <span class="detail">{{ item.description }}</span>
                     <div class="btn">
                         <span @click="openUrl(item.bvid)">查看</span>
-                        <span @click="checkUrl(item.title,item.bvid)">加入</span>
+                        <span @click="checkUrl(item.title, item.bvid)">加入</span>
                     </div>
                 </div>
             </div>
@@ -39,6 +39,7 @@
 </template>
 
 <script>
+import { v4 as uuidv4 } from "uuid";
 
 export default {
     components: {
@@ -88,10 +89,12 @@ export default {
         dialogVisibleAiCreateVideo(newValue, oldValue) {
             if (newValue) {
                 // if (this.radio == 0) {
-                if(this.courseState == 4){
+                if (this.courseState == 4) {
                     this.detail = this.courseName
-                }else if(this.courseState == 5){
-                    this.detail = this.unitJson[0].chapterInfo[0].taskJson[this.lineCount].task.replace("任务"+(this.lineCount+1)+":","")
+                    this.aiGet()
+                } else if (this.courseState == 5) {
+                    // this.detail = this.unitJson[0].chapterInfo[0].taskJson[this.lineCount].task.replace("任务"+(this.lineCount+1)+":","")
+                    this.againEva()
                 }
                 // }
                 // if (this.radio == 1) {
@@ -101,7 +104,9 @@ export default {
                 //     this.detail = this.aiJson.video
                 // }
                 // this.loading = false
-                this.aiGet()
+
+                // this.aiGet()
+                // this.againEva()
             }
         },
     },
@@ -113,11 +118,11 @@ export default {
         close() {
             this.$emit('update:dialogVisibleAiCreateVideo', false)
         },
-        openUrl(url){
+        openUrl(url) {
             // window.open('https://www.youtube.com/embed/'+url)
             window.open(`//www.bilibili.com/video/${url}`)
         },
-        checkUrl(name,id) {
+        checkUrl(name, id) {
             let json = {
                 name: "链接",
                 title: name.replace(/<[^>]*>?/gm, ''),
@@ -158,21 +163,125 @@ export default {
         async aiGet() {
             let _this = this
             _this.loading = true
-            this.ajax.post(`https://gpt4.cocorobo.cn/get_network_search`,{
-                 engine:"bilibili",
-                keyword:this.detail
-              }).then(response=>{
+            this.ajax.post(`https://gpt4.cocorobo.cn/get_network_search`, {
+                engine: "bilibili",
+                keyword: this.detail
+            }).then(response => {
+                console.log(response);
+                _this.data = response.data.FunctionResponse
+                _this.loading = false
+
+            })
+                .catch((error) => {
+                    _this.loading = false
+                    console.log(error);
+                });
+        },
+        // async aiGet2(msg) {
+        //     let _this = this
+        //     _this.loading = true
+        //     this.ajax
+        //         .get(`https://www.googleapis.com/youtube/v3/search?key=AIzaSyBUvNQ5Wyua4PbStE2vp3t7MIY4htry-4M&part=snippet&q=${msg}&maxResults=10&type=video&order=relevance&regionCode=HK`)
+        //         .then((response) => {
+        //             console.log(response);
+        //             _this.data = response.data.items
+        //             _this.loading = false
+
+        //         })
+        //         .catch((error) => {
+        //             _this.loading = false
+        //             console.log(error);
+        //         });
+        // },
+        async aiGet2(msg) {
+            let _this = this
+            return new Promise((resolve, reject) => {
+                this.ajax.post(`https://gpt4.cocorobo.cn/get_network_search`, {
+                    engine: "bilibili",
+                    keyword: msg
+                }).then(response => {
+                    console.log(response);
+                    // _this.data = [..._this.data,...response.data.FunctionResponse]
+                    resolve(response.data.FunctionResponse)
+                })
+                    .catch((error) => {
+                        resolve([])
+                        console.log(error);
+                    });
+            });
+        },
+        async searchA(){
+            let _this = this
+            if(!_this.detail){
+                _this.$message.error("请输入关键字")
+                return
+            }
+            _this.loading = true
+            let _content = ""
+            if(_this.detail.split(",").length>1){
+                _content = _this.detail.split(",")
+            }else{
+                _content = _this.detail.split(",")
+            }
+            _this.data = []
+            for (var a = 0; a < _content.length; a++) {
+                let _data = await _this.aiGet2(_content[a])
+                _this.data = [..._this.data, ..._data]
+            }
+            _this.data = _this.data.sort(
+                function (a, b) {
+                    return b.play - a.play;
+                }
+            );
+            _this.loading = false
+        },
+        againEva() {
+            let _this = this
+            _this.loading = true
+            let message = `从以下内容中识别出1~2个学科知识点关键词,用于检索知识点相关视频。注意,你仅需要返回关键词,“,”分开。教案:${_this.unitJson[0].chapterInfo[0].taskJson[_this.lineCount].taskDetail3.replaceAll('#', '').replaceAll('*', '').replaceAll('-', '').replaceAll('\n', '')}`
+            let parm = {
+                assistant_id: 'f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b',
+                message: [{ "type": "text", "text": message.replaceAll('\n', " ").replaceAll('*', "") }],
+                session_name: uuidv4(),
+                userId: _this.userid,
+                file_ids: [],
+                model: 'gpt-4o-2024-08-06',
+            }
+            _this.ajax
+                .post("https://gpt4.cocorobo.cn/ai_agent_park_chat", parm)
+                .then(async (response) => {
                     console.log(response);
-                    _this.data = response.data.FunctionResponse
+                    let data = response.data.FunctionResponse
+                    if (data.message) {
+                        console.log(data.message);
+
+                        let content = data.message;
+                        _this.detail = content
+                        let _content = content.split(",")
+                        if(content.split(",").length>1){
+                            _content = content.split(",")
+                        }else{
+                            _content = content.split(",")
+                        }
+                        _this.data = []
+                        for (var a = 0; a < _content.length; a++) {
+                            let _data = await _this.aiGet2(_content[a])
+                            _this.data = [..._this.data, ..._data]
+                        }
+                        _this.data = _this.data.sort(
+                            function (a, b) {
+                                return b.play - a.play;
+                            }
+                        );
+                    }
                     _this.loading = false
 
                 })
                 .catch((error) => {
-                    _this.loading = false
                     console.log(error);
+                    _this.loading = true
                 });
         },
-
     },
 }
 </script>
@@ -261,25 +370,26 @@ export default {
     color: #000;
 }
 
-.inputC >>> .el-input__inner{
+.inputC>>>.el-input__inner {
     padding: '0 35px 0 15px'
 }
+
 .search_img {
-  width: 20px;
-  height: 20px;
-  position: absolute;
-  right: 10px;
-  top: 50%;
-  transform: translateY(-50%);
+    width: 20px;
+    height: 20px;
+    position: absolute;
+    right: 10px;
+    top: 50%;
+    transform: translateY(-50%);
 }
 
 .search_img>img {
-  width: 100%;
-  height: 100%;
+    width: 100%;
+    height: 100%;
 }
 
 
-.Box{
+.Box {
     width: 100%;
     height: calc(100% - 50px);
     overflow: auto;
@@ -288,6 +398,7 @@ export default {
     justify-content: flex-start;
     flex-wrap: wrap;
 }
+
 .video_box {
     width: calc(100% / 2 - 10px);
     /* overflow: hidden; */
@@ -297,21 +408,23 @@ export default {
     margin-bottom: 15px;
     cursor: pointer;
 }
-.video_box > img{
+
+.video_box>img {
     height: 200px;
     object-fit: cover;
 }
 
-.video_box > .detail{
+.video_box>.detail {
     color: #cecece;
 }
-.video_box > .name{
+
+.video_box>.name {
     color: #000;
     margin: 5px 0;
     height: 32px;
 }
 
-.btn{
+.btn {
     width: 100%;
     height: 35px;
     display: flex;
@@ -319,11 +432,11 @@ export default {
     margin-top: auto;
 }
 
-.btn > span:hover{
+.btn>span:hover {
     background: #4087f1;
 }
 
-.btn > span{
+.btn>span {
     width: 100%;
     height: 100%;
     background: #3681fc;
@@ -336,11 +449,11 @@ export default {
     justify-content: center;
 }
 
-.btn > span + span{
+.btn>span+span {
     margin-left: 10px;
 }
 
-.video_box2{
+.video_box2 {
     box-shadow: 0px 0px 4px 2px #d2d2d282;
     padding: 5px 10px 10px;
     box-sizing: border-box;

+ 1 - 0
src/components/pages/classroomObservation/components/analysisItem.vue

@@ -256,6 +256,7 @@ export default {
 					session_name: uuidv4(),
 					userId: this.userId,
 					file_ids: this.fileId?[this.fileId]:'',
+					model: "gpt-4o-2024-08-06",
 				};
 
 				// 👇

+ 1 - 0
src/components/pages/classroomObservation/components/baseMessage.vue

@@ -659,6 +659,7 @@ ${this.data.editorBarData?this.data.editorBarData.content:""}
 					uid: _uuid,
 					mind_map_question: "",
 					stream: false,
+					model: "gpt-4o-2024-08-06",
 				};
 				this.ajax
 					.post("https://gpt4.cocorobo.cn/chat", params)

+ 3 - 1
src/components/pages/classroomObservation/components/chatArea.vue

@@ -1198,6 +1198,7 @@ export default {
             session_name: `${this.tid}-classroomObservation`,
             uid: _uid,
             file_ids: this.fileId ? [this.fileId] : [],
+						model: "gpt-4o-2024-08-06",
           };
           this.ajax
             .post("https://gpt4.cocorobo.cn/ai_agent_park_chat_new", params)
@@ -1238,7 +1239,7 @@ export default {
         // })
         _historyMessage.push({ role: "user", content: _text });
         let params = JSON.stringify({
-          model: "gpt-3.5-turbo",
+          model: "gpt-4o-2024-08-06",
           temperature: 0,
           max_tokens: 4096,
           top_p: 1,
@@ -1617,6 +1618,7 @@ ${JSON.stringify(_list)}
           session_name: _uuid,
           // uid: _uuid,
           file_ids: [],
+					model: "gpt-4o-2024-08-06",
         };
 
         this.ajax

+ 14 - 1
src/components/pages/components/studentReport.vue

@@ -2,7 +2,10 @@
   <div style="width: 100%; height: 100%">
     <div class="sr_head">
       学生成长报告
-      <el-button type="primary" size="small" @click="downloadFile('https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/student01-%E5%AD%A6%E7%94%9F%E6%88%90%E9%95%BF%E6%8A%A5%E5%91%8A1719315423787.pdf');">导出报告</el-button>
+      <div class="sr_headBtnS">
+        <el-button type="primary" size="small" @click="downloadFile('https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/student01-%E5%AD%A6%E7%94%9F%E6%88%90%E9%95%BF%E6%8A%A5%E5%91%8A1719315423787.pdf');">导出报告</el-button>
+        <el-button style="margin-left: 10px;" @click="pageBack" type="primary" size="small">返回</el-button>
+      </div>
       
     </div>
     <div class="sr_body">
@@ -79,6 +82,9 @@ export default {
     },
   },
   methods: {
+    pageBack(){
+      this.$emit('cancelR');
+    },
     downloadFile(url){
       var credentials = {
         accessKeyId: "AKIATLPEDU37QV5CHLMH",
@@ -137,6 +143,13 @@ export default {
   font-weight: bolder;
   text-align: center;
   margin-bottom: 15px;
+  position: relative;
+}
+.sr_headBtnS{
+  position: absolute;
+  right: 0;
+  bottom: 0;
+  display: flex;
 }
 .sr_body {
   width: 100%;

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

@@ -10,7 +10,7 @@
       </pdf>
     </div> -->
     <iframe ref="viframe" style="width: 100%; height: 99%; border: none"
-      :src="'https://cloud.cocorobo.cn/pdf.js/web/viewer.html?file=' + encodeURIComponent(pdfUrl)"></iframe>
+      :src="pdfUrl"></iframe>
     <!-- <div class="rightArea">
       <div class="toolGroup">
         <div class="page">第 {{ page }} / {{ numPages }} 页</div>

+ 14 - 2
src/components/pages/components/workData.vue

@@ -158,7 +158,14 @@
             ></div>
           </div>
           <div style="width: 100%">
-            <div style="width:94%;margin: 0 auto;font-size: 26px;">作业查看</div>
+            <div style="display: flex;align-items: center;padding-bottom: 15px;font-size: 14px;color: rgba(0, 0, 0, 0.4);">
+              <span @click="pageBack" style="height: 100%;cursor: pointer;">评价管理</span>
+              <span style="margin: 0 5px;">
+                <i class="el-icon-arrow-right"></i>
+              </span>
+              <div style="font-weight: 600;color: rgba(0, 0, 0, 0.9);">查看作业</div>
+            </div>
+            <div style="width:94%;margin: 0 auto;font-size: 26px;">{{ dataJson.title }}</div>
             <WorksDetail2 :cid="cid" :uid="uid" :ooid="ooid"></WorksDetail2>
             <!-- <el-table
               ref="table"
@@ -198,7 +205,7 @@ import ScoreData from "./data/scoreData";
 import WorksDetail2 from "./worksDetail2";
 
 export default {
-  props: ["dataJson", "cid", "uid", "ooid"],
+  props: ["dataJson", "cid", "uid", "ooid","dialogVisible"],
   components: {
     WorkData,
     ProblelmData,
@@ -540,6 +547,11 @@ export default {
         return "";
       }
     },
+    pageBack(){
+      console.log('666');
+      
+      this.$emit("update:dialogVisible", false);
+    },
     getData() {
       let params = {
         cid: this.courseId,

+ 255 - 130
src/components/pages/components/worksDetail2.vue

@@ -129,14 +129,14 @@
               <div>{{ scope.row.class ? scope.row.class : "暂无班级" }}</div>
             </template>
           </el-table-column>
-          <el-table-column
+          <!-- <el-table-column
             prop="course"
             label="课程"
             min-width="20"
             align="center"
             show-overflow-tooltip
           >
-          </el-table-column>
+          </el-table-column> -->
           <el-table-column
             prop="course"
             label="阶段"
@@ -146,7 +146,7 @@
           >
             <template slot-scope="scope">
               <div>
-                {{ dyList.length > 0 ? dyList[scope.row.stage].name : "" }}
+                {{ dyList.length > 0 ? dyList[!scope.row.stage ? 0 : scope.row.stage ].name : "" }}
               </div>
             </template>
           </el-table-column>
@@ -161,8 +161,8 @@
               <div>
                 {{
                   dyList.length > 0
-                    ? dyList[scope.row.stage].taskList[scope.row.task]
-                      ? dyList[scope.row.stage].taskList[scope.row.task].name
+                    ? dyList[!scope.row.stage ? 0 : scope.row.stage].taskList[!scope.row.task ? 0 : scope.row.task]
+                      ? dyList[!scope.row.stage ? 0 : scope.row.stage].taskList[!scope.row.task ? 0 : scope.row.task].name
                       : ""
                     : ""
                 }}
@@ -173,9 +173,9 @@
             prop="time"
             label="时间"
             width="100px"
-            align="center"
+            align="center" 
           ></el-table-column>
-          <el-table-column label="操作" width="200px">
+          <el-table-column align="center" label="操作" width="260px">
             <template slot-scope="scope">
               <el-button
                 type="primary"
@@ -183,7 +183,7 @@
                 @click="
                   lookWork(scope.row.id, scope.row.userid, 0, scope.$index)
                 "
-                >查看作业</el-button
+                >查看&批改</el-button
               >
               <!-- <el-button
                 type="primary"
@@ -197,7 +197,7 @@
                 @click="
                   lookWork2(scope.row.id, scope.row.userid, scope.row.courseid)
                 "
-                >导出报告</el-button
+                >导出作业</el-button
               >
               <!-- <el-button
                 class="de_button"
@@ -216,6 +216,7 @@
           width="100%"
           class="dialog_diy2 max_diy"
           :class="{ fullStyle: full }"
+          v-loading="worksLoading"
         >
           <div slot="title" class="header-title">
             <div style="color: #fff">查看作业</div>
@@ -239,7 +240,7 @@
                   size="mini"
                   style="margin-left: 15px;"
                   @click="getPdf"
-                  >导出pdf</el-button
+                  >导出作业集</el-button
                 >
               </div>
 
@@ -618,13 +619,13 @@
                           class="left_top"
                           v-if="worksDetail[sIndex].chooseInfo.length > 0"
                         >
-                          <div>
+                          <div v-for="(lcc, lccindex) in worksDetail[sIndex].chooseInfo" :key="lccindex + 'a'">
                             <div
-                              v-if="worksDetail[sIndex].chooseInfo[0].score"
+                              v-if="lcc.score"
                               style="float: right; margin-right: 10px"
                             >
                               评分:{{
-                                worksDetail[sIndex].chooseInfo[0].score
+                                lcc.score
                               }}
                             </div>
                             <div
@@ -637,7 +638,7 @@
                                 flex-wrap: wrap;
                               "
                             >
-                              <div style="font-size: 16px">选择题工具</div>
+                              <div style="font-size: 16px">选择题工具{{ lccindex + 1 }}</div>
                             </div>
                             <div class="a_addBox">
                               <div style="font-size: 16px; color: #c7c7c7">
@@ -649,29 +650,24 @@
                                     ? 'a_add_box'
                                     : 'isAddBox'
                                 "
-                                v-for="(item1, index1) in worksDetail[sIndex]
-                                  .chooseInfo[0].chooseInfo.testCount"
-                                :key="index1"
+                                v-for="(item1, index1) in lcc.chooseInfo.testJson"
+                                :key="index1 + 'a'"
                               >
                                 <div class="a_add_head">
                                   <div style="display: flex">
                                     {{ index1 + 1 + "、" }}
                                     <div>
                                       题目:{{
-                                        worksDetail[sIndex].chooseInfo[0]
-                                          .chooseInfo.testJson[index1]
-                                          .teststitle
+                                       item1.teststitle
                                       }}
                                     </div>
                                   </div>
                                   <img
                                     v-if="
-                                      worksDetail[sIndex].chooseInfo[0]
-                                        .chooseInfo.testJson[index1].img
+                                      item1.img
                                     "
                                     :src="
-                                      worksDetail[sIndex].chooseInfo[0]
-                                        .chooseInfo.testJson[index1].img
+                                     item1.img
                                     "
                                     style="
                                       height: 300px;
@@ -680,33 +676,28 @@
                                     "
                                   />
                                 </div>
+
                                 <div class="a_add_body">
                                   <div class="a_add_input">
                                     <el-radio-group
                                       v-model="
-                                        worksDetail[sIndex].chooseInfo[0]
-                                          .chooseInfo.radio[index1]
+                                       lcc.chooseInfo.radio[index1]
                                       "
                                       v-if="
-                                        worksDetail[sIndex].chooseInfo[0]
-                                          .chooseInfo.testJson[index1].type ==
-                                        '1'
+                                        item1.type == '1'
                                       "
                                     >
                                       <div class="radioBox">
                                         <el-radio
                                           v-for="(
                                             item2, checkIndex
-                                          ) in worksDetail[sIndex].chooseInfo[0]
-                                            .chooseInfo.testJson[index1]
-                                            .checkList"
-                                          :key="checkIndex"
+                                          ) in item1.checkList"
+                                          :key="checkIndex + 'b'"
                                           :label="checkIndex"
                                           disabled
-                                          class="redioStyle"
+                                          :class="[item1.answer ==  checkIndex ? 'redioStyle5':'redioStyle2']"
                                         >
                                           <div
-                                            style="margin-right: 10px"
                                             v-if="
                                               item2 &&
                                               item2.imgType &&
@@ -726,28 +717,24 @@
                                         </el-radio>
                                       </div>
                                     </el-radio-group>
+
                                     <el-checkbox-group
                                       v-model="
-                                        worksDetail[sIndex].chooseInfo[0]
-                                          .chooseInfo.radio[index1]
+                                       lcc.chooseInfo.radio[index1]
                                       "
                                       v-if="
-                                        worksDetail[sIndex].chooseInfo[0]
-                                          .chooseInfo.testJson[index1].type ==
-                                        '2'
+                                        item1.type == '2'
                                       "
                                     >
                                       <div class="radioBox">
                                         <el-checkbox
                                           v-for="(
                                             item2, checkIndex
-                                          ) in worksDetail[sIndex].chooseInfo[0]
-                                            .chooseInfo.testJson[index1]
-                                            .checkList"
-                                          :key="checkIndex"
+                                          ) in item1.checkList"
+                                          :key="checkIndex + 'c'"
                                           :label="checkIndex"
                                           disabled
-                                          class="redioStyle"
+                                          :class="[item1.answer.includes(checkIndex) ? 'redioStyle3':'redioStyle4']"
                                         >
                                           <div
                                             style="margin-right: 10px"
@@ -776,6 +763,7 @@
                             </div>
                           </div>
                         </div>
+
                         <div
                           class="left_top"
                           v-if="worksDetail[sIndex].wpptInfo.length > 0"
@@ -787,7 +775,7 @@
                             评分:{{ worksDetail[sIndex].wpptInfo[0].score }}
                           </div>
                           <div
-                            style="height: 238px"
+                            style="height: 500px"
                             @click="
                               openFile(worksDetail[sIndex].wpptInfo[0].wpptInfo)
                             "
@@ -799,8 +787,8 @@
                                 )
                               "
                               style="
-                                width: 300px;
-                                height: 300px;
+                                width: 100%;
+                                height: 500px;
                                 position: absolute;
                                 z-index: 999;
                               "
@@ -808,7 +796,7 @@
                             <pdf
                               v-if="showPDF"
                               :pdfUrl="worksDetail[sIndex].wpptInfo[0].wpptInfo"
-                              style="width: 100%; height: 520px; overflow: auto"
+                              style="width: 100%; height: 95%; overflow: auto"
                             ></pdf>
                             <iframe
                               v-else
@@ -819,6 +807,7 @@
                             ></iframe>
                           </div>
                         </div>
+
                         <div
                           class="left_top"
                           v-if="worksDetail[sIndex].pjInfo.length > 0"
@@ -1011,12 +1000,12 @@
                           class="left_top"
                           v-if="worksDetail[sIndex].lccjInfo.length > 0"
                         >
-                          <div class="sentenBox">
+                          <div class="sentenBox" v-for="(lcc, lccindex) in worksDetail[sIndex].lccjInfo" :key="lccindex +'d'">
                             <div
-                              v-if="worksDetail[sIndex].lccjInfo[0].score"
+                              v-if="lcc.score"
                               style="float: right; margin-right: 10px"
                             >
-                              评分:{{ worksDetail[sIndex].lccjInfo[0].score }}
+                              评分:{{ lcc.score }}
                             </div>
                             <div
                               class="a_add_title"
@@ -1031,9 +1020,8 @@
                               <div style="font-size: 16px">排序工具</div>
                             </div>
                             <div
-                              v-for="(st, stIndex) in worksDetail[sIndex]
-                                .lccjInfo"
-                              :key="stIndex"
+                              v-for="(st, stIndex) in lcc.lccjInfo"
+                              :key="stIndex+'e'"
                               style="padding-bottom: 20px"
                             >
                               <div
@@ -1047,13 +1035,12 @@
                               <div class="isWrong">
                                 <div
                                   class="cardList1"
-                                  v-if="st.lccjInfo.chooseSenList"
+                                  v-if="st.chooseSenList"
                                 >
                                   <div class="cardBox">
                                     <div
-                                      v-for="(s, sIndex) in st.lccjInfo
-                                        .chooseSenList"
-                                      :key="sIndex"
+                                      v-for="(s, sIndex) in st.chooseSenList"
+                                      :key="sIndex+'f'"
                                     >
                                       <el-tooltip
                                         class="item"
@@ -1069,15 +1056,15 @@
                                   </div>
                                   <div class="cardAnswerBox">
                                     组成句子:{{
-                                      st.lccjInfo.chooseSenList.join(" ")
+                                      st.chooseSenList.join(" ")
                                     }}
                                   </div>
                                 </div>
                                 <div
                                   class="answerRight isTj"
                                   v-if="
-                                    st.lccjInfo.chooseSenList.toString() ==
-                                    st.lccjInfo.rightAnswer.toString()
+                                    st.chooseSenList.toString() ==
+                                    st.rightAnswer.toString()
                                   "
                                 >
                                   <div class="isTjImg">
@@ -1091,8 +1078,8 @@
                                 <div
                                   class="answerRight isTj"
                                   v-if="
-                                    st.lccjInfo.chooseSenList.toString() !=
-                                    st.lccjInfo.rightAnswer.toString()
+                                    st.chooseSenList.toString() !=
+                                    st.rightAnswer.toString()
                                   "
                                 >
                                   <div class="isTjImg">
@@ -1106,8 +1093,8 @@
                               </div>
                               <div
                                 v-if="
-                                  st.lccjInfo.chooseSenList.toString() !=
-                                  st.lccjInfo.rightAnswer.toString()
+                                  st.chooseSenList.toString() !=
+                                  st.rightAnswer.toString()
                                 "
                               >
                                 <div style="padding: 15px 0 10px 20px">
@@ -1115,7 +1102,7 @@
                                 </div>
                                 <div
                                   class="cardList"
-                                  v-if="st.lccjInfo.rightAnswer"
+                                  v-if="st.rightAnswer"
                                   style="
                                     border: none;
                                     padding: 10px 0 10px 10px;
@@ -1124,9 +1111,8 @@
                                 >
                                   <div class="cardBox">
                                     <div
-                                      v-for="(r, rIndex) in st.lccjInfo
-                                        .rightAnswer"
-                                      :key="rIndex"
+                                      v-for="(r, rIndex) in st.rightAnswer"
+                                      :key="rIndex + 'g'"
                                     >
                                       <el-tooltip
                                         class="item"
@@ -1142,7 +1128,7 @@
                                   </div>
                                   <div class="cardAnswerBox">
                                     组成句子:{{
-                                      st.lccjInfo.rightAnswer.join(" ")
+                                      st.rightAnswer.join(" ")
                                     }}
                                   </div>
                                 </div>
@@ -1380,12 +1366,20 @@
                         position: relative;
                       "
                     >
+                    <div class="worksTimeBlack">
+                      <div class="worksTimeBlackTit">
+                        <div>
+                          任务得分: <span style="color: rgba(54, 129, 252, 1);margin-left: 5px;">{{ totalScore(worksDetail[sIndex].rateList) }}</span>分
+                        </div>
+                      </div>
                       <div class="worksTime">
                         作业提交时间:<span style="width: auto"
                           >{{ worksDetail[sIndex].time }}
                         </span>
                       </div>
-                      <div
+                    </div>
+                     
+                      <!-- <div
                         v-if="
                           // worksDetail[sIndex].img.length == 0 &&
                           // worksDetail[sIndex].askInfo.length == 0 &&
@@ -1429,12 +1423,13 @@
                           <span>全部题的正确率:</span>
                           <span>{{ checkJson[sIndex].allRight + "%" }}</span>
                         </div>
-                      </div>
+                      </div> -->
                       <div v-if="worksDetail[sIndex].eList.length">
-                        <div class="ech" style="margin-left: 23px">
+                        <!-- <div class="ech" style="margin-left: 23px">
                           <img src="../../../assets/icon/pj/score.png" alt="" />
-                        </div>
+                        </div> -->
                         <div>
+                          <div class="score_boxTit"><span>分数详情</span></div>
                           <div
                             class="score_box"
                             v-for="(item, index) in worksDetail[sIndex].eList"
@@ -1456,6 +1451,13 @@
                             ></el-rate>
                           </div>
                         </div>
+                        <div class="worksTarget" v-if="worksDetail[sIndex].eList[0].target"><span>目标</span></div>
+                        <!-- {{ worksDetail[sIndex] }}  -->
+                        <div class="worksTargetCon" v-if="worksDetail[sIndex].eList[0].target">
+                            <div v-for="(item,tarIndex) in worksDetail[sIndex].eList" :key="tarIndex">
+                              <span v-if="item.target"> {{ item.target }}</span>
+                            </div>
+                        </div>
                       </div>
                     </div>
                   </div>
@@ -1571,14 +1573,13 @@
       <pdf
         v-if="showPDF"
         :pdfUrl="pptImgUrl"
-        style="width: 100%; height: 520px; overflow: auto"
+        style="width: 100%; height: 95%; overflow: auto"
       ></pdf>
       <iframe
         v-else
         :src="pptImgUrl"
         frameborder="0"
         width="100%"
-        height="600"
       ></iframe>
     </el-dialog>
   </div>
@@ -1826,8 +1827,25 @@ export default {
       checkJson: [],
       typeCheck: false,
       word2: require("../../../assets/icon/word2.png"),
+      worksLoading:false
     };
   },
+  computed: {
+    totalScore(){
+      return function (val) {
+        let sco = 0
+        let num = 0
+
+        for (const key in val) {
+          if (val[key]  || val[key] == 0) {
+            sco+= val[key] * 1
+          }
+          num+=1
+        }
+        return (sco / (num - 1)).toFixed(1)
+      }
+    }
+  },
   watch: {
     typeCheck(newValue, oldValue) {
       this.loading = true;
@@ -1861,6 +1879,7 @@ export default {
   },
   methods: {
     getPdf(){
+      this.worksLoading = true
       let domHeight = this.$refs.reportPdf.offsetHeight;
       console.log('this.$refs.reportPdf',this.$refs.reportPdf.offsetHeight);
       let maxHeight = 64257;
@@ -1886,21 +1905,15 @@ export default {
         //有两个高度需要区分,一个是html页面的实际高度,和生成pdf的页面高度(841.89)
         //当内容未超过pdf一页显示的范围,无需分页
         // if (leftHeight < pageHeight) {
-            pdf.addImage(pageData, 'JPEG', 10, 0, imgWidth-20, imgHeight );
-        // } else {
-        //     while(leftHeight > 0) {
-        //         pdf.addImage(pageData, 'JPEG', 10, position, imgWidth-20, imgHeight)
-        //         leftHeight -= pageHeight;
-        //         position -= 841.89;
-        //         //避免添加空白页
-        //         if(leftHeight > 0) {
-        //             pdf.addPage();
-        //         }
-        //     }
-        // }
-        pdf.save('js.pdf')
-
+        pdf.addImage(pageData, 'JPEG', 10, 0, imgWidth-20, imgHeight-20 );
+       
+        pdf.save( this.allWorks.course+'-'+ this.allWorks.sName+'学生作业集.pdf')
+        this.worksLoading = false
     })
+    .catch((err) => {
+      this.worksLoading = false
+      console.log(err);
+    });
 
     },
 		changeClass(){//切换班级
@@ -1981,7 +1994,10 @@ export default {
             _ooption = [],
             _rate = [],
             _rateList = [];
+            console.log('res.data',res.data);
           var worksDetail = res.data[1];
+          // let worksDetailCopy = JSON.parse(JSON.stringify(worksDetail))
+          // console.log('worksDetailCopy',worksDetailCopy);
           // this.scopeId = res.data[2][0].id;
           // var scopeId = res.data[2][0].id;
           var askInfo = res.data[3];
@@ -2366,10 +2382,11 @@ export default {
             }
           }
 
+          // 排序
           for (var i = 0; i < lccjInfo.length; i++) {
             var lccj = lccjInfo[i];
             workJson[lccjInfo[i].stage + "-" + lccjInfo[i].task].lccjInfo.push({
-              lccjInfo: JSON.parse(lccj.content)[0],
+              lccjInfo: JSON.parse(lccj.content),
               score: lccjInfo[i].score
                 ? JSON.parse(lccjInfo[i].score).wScore
                 : lccjInfo[i].score,
@@ -2520,6 +2537,8 @@ export default {
                   detail: eListOld[key].detail,
                   score: eListOld[key].score,
                   value: eListOld[key].value,
+                  isai: eListOld[key].isai,
+                  target: eListOld[key].target
                 };
               });
               eList = eListNew;
@@ -2569,6 +2588,8 @@ export default {
                         detail: eListOld[key].detail,
                         score: eListOld[key].score,
                         value: eListOld[key].value,
+                        isai: eListOld[key].isai,
+                        target: eListOld[key].target
                       };
                     });
                     eList = eListNew;
@@ -2616,6 +2637,8 @@ export default {
           }
 
           this.worksDetail = result;
+          console.log('this.worksDetail',this.worksDetail);
+
 
           this.courseDetail = res.data[0][0];
 
@@ -2732,6 +2755,8 @@ export default {
       this.dialogVisible2 = true;
     },
     openFile(f, t) {
+      console.log('fff',f);
+      
       this.pptImgUrl = f;
       if (t == 2) {
         this.showPDF = false;
@@ -3208,6 +3233,7 @@ export default {
             });
           }
 
+          //#region 
           // for (var i = 0; i < pptInfo.length; i++) {
           //   var a = ["PPT", "PPTX", "XLSX", "XLS", "DOC", "DOCX"];
           //   if (
@@ -3241,7 +3267,7 @@ export default {
           //     });
           //   }
           // }
-
+//#endregion
           for (var i = 0; i < answerInfo.length; i++) {
             const element = answerInfo[i];
             workJson.answerInfo.push({
@@ -3296,15 +3322,20 @@ export default {
             }
           }
 
-          for (var i = 0; i < lccjInfo.length; i++) {
-            var lccj = lccjInfo[i];
-            workJson.lccjInfo.push({
-              lccjInfo: JSON.parse(lccj.content)[0],
-              score: lccjInfo[i].score
-                ? JSON.parse(lccjInfo[i].score).wScore
-                : lccjInfo[i].score,
-            });
+          // console.log('lccjInfo',lccjInfo);
+          
+          if (lccjInfo.length > 0) {
+            for (var i = 0; i < lccjInfo.length; i++) {
+              var lccj = lccjInfo[i];
+              workJson.lccjInfo.push({
+                lccjInfo: JSON.parse(lccj.content),
+                score: lccjInfo[i].score
+                  ? JSON.parse(lccjInfo[i].score).wScore
+                  : lccjInfo[i].score,
+              });
+            }
           }
+          
 
           for (var i = 0; i < bgInfo.length; i++) {
             var bg = bgInfo[i];
@@ -3505,6 +3536,8 @@ export default {
                   workJson.chooseInfo[i].chooseInfo.testJson[j].teststitle
                 }  选择:${
                   workJson.chooseInfo[i].chooseInfo.testJson[j].answer
+                } 答案:${
+                  workJson.chooseInfo[i].chooseInfo.testJson[j].type == 1 ? workJson.chooseInfo[i].chooseInfo.radio[j] : workJson.chooseInfo[i].chooseInfo.radio[j].join(',')
                 }</h5> `;
                 var _div3 = document.createElement("div");
                 for (
@@ -3514,7 +3547,7 @@ export default {
                     .length;
                   z++
                 ) {
-                  _div3.innerHTML += `<span style="margin-right:5px">${z + 1}.${
+                  _div3.innerHTML += `<span style="margin-right:5px">${z}.${
                     workJson.chooseInfo[i].chooseInfo.testJson[j].checkList[z]
                   }</span>`;
                 }
@@ -3536,27 +3569,38 @@ export default {
           //   }
           // }
 
+            //  console.log(workJson.lccjInfo)
+          
           var _lccjInfo = "";
-          if (workJson.lccjInfo.length > 0) {
+          // console.log('workJson.lccjInfo',workJson.lccjInfo);
+          
+          if (workJson.lccjInfo.length>0) {
+            if (workJson.lccjInfo[0].lccjInfo.length > 0) {
             var _lccjInfo = "<h3>排序<h3>";
-            for (var i = 0; i < workJson.lccjInfo.length; i++) {
-              var _div = document.createElement("div");
-              _div.innerHTML = `<h4>第一题${workJson.lccjInfo[i].lccjInfo.sentenceTitle}</h4> `;
-              var _div2 = document.createElement("div");
-              for (
-                var j = 0;
-                j < workJson.lccjInfo[i].lccjInfo.chooseSenList.length;
-                j++
-              ) {
-                _div2.innerHTML += ` 句子 ${j + 1} : ${
-                  workJson.lccjInfo[i].lccjInfo.chooseSenList[j]
-                }`;
+              for (var i = 0; i < workJson.lccjInfo[0].lccjInfo.length; i++) {
+                var _div = document.createElement("div");
+                _div.innerHTML = `<h4>第${i+1}题${workJson.lccjInfo[0].lccjInfo[i].sentenceTitle}</h4> `;
+                var _div2 = document.createElement("div");
+                // for (
+                //   var j = 0;
+                //   j < workJson.lccjInfo[0][lccjInfo][i].chooseSenList.length;
+                //   j++
+                // ) {
+                //   _div2.innerHTML += ` 句子 ${j + 1} : ${
+                //     workJson.lccjInfo[0][lccjInfo][i].chooseSenList[j]
+                //   }`;
+                // }
+                _div2.innerHTML+= ` 句子 ${i + 1}:${ workJson.lccjInfo[0].lccjInfo[i].addSentence.join(',')} 选择:${
+                    workJson.lccjInfo[0].lccjInfo[i].chooseSenList.join(',') 
+                  } 答案:${
+                    workJson.lccjInfo[0].lccjInfo[i].rightAnswer.join(',') 
+                  }`
+                _div.innerHTML += `<div>${_div2.innerHTML}</div>`;
+                _lccjInfo += `<div>${_div.innerHTML}</div>`;
               }
-
-              _div.innerHTML += `<div>${_div2.innerHTML}</div>`;
-              _lccjInfo += `<div>${_div.innerHTML}</div>`;
             }
           }
+          
 
           var _bg = "";
           if (workJson.bgInfo.length > 0) {
@@ -4042,25 +4086,43 @@ export default {
   font-size: 15px;
   background: #fff;
   height: 100%;
-  padding-top: 40px;
+  /* padding-top: 40px; */
+  padding: 40px 30px 0;
   border-radius: 5px;
   width: 90%;
   box-shadow: 2px 2px 5px #909090;
   /* overflow: auto; */
 }
+.sd_score .score_boxTit{
+  margin-top: 20px;
+  /* padding: 0 30px; */
+  box-sizing: border-box;
+  font-size: 16px;
+  font-weight: 600;
+  color: rgba(0, 0, 0, 0.9);
+}
+
+.sd_score .score_boxTit > span{
+  border-left: 3px solid rgba(54, 129, 252, 1);
+  padding-left: 5px;
+}
 
 .sd_score .score_box {
   display: flex;
   align-items: center;
-  justify-content: flex-start;
+  font-size: 14px !important;
+  /* justify-content: flex-start; */
+  justify-content: space-between;
   margin-bottom: 15px;
-  margin: 10px 0 0 30px;
+  /* margin: 10px 0 0 30px; */
+  margin: 10px 0;
+
 }
 .sd_score .score_box > span:nth-child(1) {
   margin-right: 20px;
-  text-align-last: justify;
-  max-width: 120px;
-  width: 80px;
+  /* text-align-last: justify; */
+  /* max-width: 300px; */
+  width: 150px;
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;
@@ -4071,7 +4133,7 @@ export default {
 }
 
 .rate_size >>> .el-rate__icon {
-  font-size: 25px;
+  font-size: 22px;
 }
 
 .rate_size >>> .el-icon-star-off {
@@ -4089,7 +4151,30 @@ export default {
   text-overflow: ellipsis;
   font-size: 16px;
 }
-
+.worksTarget {
+  margin: 15px 0;
+  border-left: 3px solid rgba(54, 129, 252, 1);
+  font-size: 16px;
+  font-weight: 600;
+  color: rgba(0, 0, 0, 0.9);
+}
+.worksTarget > span {
+  margin-left: 5px;
+}
+.worksTargetCon {
+  background: rgba(243, 247, 253, 1);
+  margin: 0 30;
+  padding: 10px;
+  border-radius: 5px;
+  box-sizing: border-box;
+  margin-bottom: 10px;
+}
+.worksTargetCon > div {
+  margin-bottom: 10px;
+}
+.worksTargetCon > div:last-child{
+  margin: 0 !important;
+}
 .moreSay {
   margin: 0px 0 5px 20px;
 }
@@ -4268,6 +4353,7 @@ export default {
   flex-wrap: nowrap;
   align-items: flex-start;
   overflow: hidden;
+  border-radius: 5px;
 }
 
 .zyBoxC + .zyBoxC {
@@ -4446,10 +4532,27 @@ export default {
   flex-wrap: wrap;
 }
 
+
 .redioStyle >>> .el-radio__label {
   font-size: 18px;
 }
 
+.redioStyle5 >>> .el-radio__label {
+  font-size: 14px;
+  color: #06a7ff !important;
+}
+.redioStyle2 >>> .el-radio__label {
+  font-size: 14px;
+}
+
+.redioStyle3 >>> .el-checkbox__label {
+  font-size: 14px;
+  color: #06a7ff !important;
+}
+.redioStyle4 >>> .el-checkbox__label {
+  font-size: 14px;
+}
+
 .task_title {
   font-size: 18px;
   font-weight: 700;
@@ -4638,7 +4741,9 @@ export default {
   background: rgb(255, 255, 255);
   /* padding-right: 10px; */
   /* height: 500px; */
-  height: 100%;
+  /* height: 100%; */
+  min-height: 800px;
+  border-radius: 5px;
 }
 
 .cTitle {
@@ -4893,7 +4998,7 @@ export default {
 }
 
 .fullStyle >>> .el-dialog__body {
-  height: 100% !important;
+  height: calc(100% - 68px) !important;
   overflow: auto;
 }
 
@@ -4904,11 +5009,23 @@ export default {
   height: 100% !important;
   margin: 0 !important;
 }
+.worksTimeBlack{
+  /* padding: 0 30px; */
+  box-sizing: border-box;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  color: rgba(0, 0, 0, 0.9);
+}
+.worksTimeBlack > .worksTimeBlackTit{
+  font-size: 18px;
+  font-weight: 600;
+}
 
 .worksTime {
-  position: absolute;
+  /* position: absolute;
   top: 10px;
-  right: 20px;
+  right: 20px; */
   display: flex;
   flex-direction: row;
   flex-wrap: nowrap;
@@ -4949,6 +5066,14 @@ export default {
   flex-wrap: wrap;
   /* align-items: center; */
 }
+.radioBox >>> .el-radio {
+  margin-bottom: 5px;
+}
+
+.radioBox >>> .el-checkbox {
+  margin-bottom: 5px;
+}
+
 .radioBox > div {
   margin: 10px 0 0 10px;
 }

+ 54 - 51
src/components/pages/components/worksDetail3.vue

@@ -346,12 +346,12 @@
                     class="left_top"
                     v-if="worksDetail[sIndex].chooseInfo.length > 0"
                   >
-                    <div>
+                    <div  v-for="(lcc, lccindex) in worksDetail[sIndex].chooseInfo" :key="lccindex + 'a'">
                       <div
-                        v-if="worksDetail[sIndex].chooseInfo[0].score"
+                        v-if="lcc.score"
                         style="float: right; margin-right: 10px"
                       >
-                        评分:{{ worksDetail[sIndex].chooseInfo[0].score }}
+                        评分:{{ lcc.score }}
                       </div>
                       <div
                         class="a_add_title"
@@ -363,7 +363,7 @@
                           flex-wrap: wrap;
                         "
                       >
-                        <div style="font-size: 16px">选择题工具</div>
+                        <div style="font-size: 16px">选择题工具{{ lccindex + 1 }}</div>
                       </div>
                       <div class="a_addBox">
                         <div style="font-size: 16px; color: #c7c7c7">
@@ -375,28 +375,24 @@
                               ? 'a_add_box'
                               : 'isAddBox'
                           "
-                          v-for="(item1, index1) in worksDetail[sIndex]
-                            .chooseInfo[0].chooseInfo.testCount"
-                          :key="index1"
+                          v-for="(item1, index1) in lcc.chooseInfo.testJson"
+                          :key="index1+ 'a'"
                         >
                           <div class="a_add_head">
                             <div style="display: flex">
                               {{ index1 + 1 + "、" }}
                               <div>
                                 题目:{{
-                                  worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                    .testJson[index1].teststitle
+                                   item1.teststitle
                                 }}
                               </div>
                             </div>
                             <img
                               v-if="
-                                worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                  .testJson[index1].img
+                                item1.img
                               "
                               :src="
-                                worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                  .testJson[index1].img
+                                item1.img
                               "
                               style="
                                 height: 300px;
@@ -409,24 +405,19 @@
                             <div class="a_add_input">
                               <el-radio-group
                                 v-model="
-                                  worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                    .radio[index1]
+                                 lcc.chooseInfo.radio[index1]
                                 "
                                 v-if="
-                                  worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                    .testJson[index1].type == '1'
+                                 item1.type == '1'
                                 "
                               >
                                 <div class="radioBox">
                                   <el-radio
-                                    v-for="(item2, checkIndex) in worksDetail[
-                                      sIndex
-                                    ].chooseInfo[0].chooseInfo.testJson[index1]
-                                      .checkList"
-                                    :key="checkIndex"
+                                    v-for="(item2, checkIndex) in item1.checkList"
+                                    :key="checkIndex + 'b'"
                                     :label="checkIndex"
                                     disabled
-                                    class="redioStyle"
+                                    :class="[item1.answer ==  checkIndex ? 'redioStyle5':'redioStyle2']"
                                   >
                                     <div
                                       style="margin-right: 10px"
@@ -449,24 +440,19 @@
                               </el-radio-group>
                               <el-checkbox-group
                                 v-model="
-                                  worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                    .radio[index1]
+                                  lcc.chooseInfo.radio[index1]
                                 "
                                 v-if="
-                                  worksDetail[sIndex].chooseInfo[0].chooseInfo
-                                    .testJson[index1].type == '2'
+                                 item1.type == '2'
                                 "
                               >
                                 <div class="radioBox">
                                   <el-checkbox
-                                    v-for="(item2, checkIndex) in worksDetail[
-                                      sIndex
-                                    ].chooseInfo[0].chooseInfo.testJson[index1]
-                                      .checkList"
-                                    :key="checkIndex"
+                                    v-for="(item2, checkIndex) in item1.checkList"
+                                    :key="checkIndex+ 'c'"
                                     :label="checkIndex"
                                     disabled
-                                    class="redioStyle"
+                                    :class="[item1.answer.includes(checkIndex) ? 'redioStyle3':'redioStyle4']"
                                   >
                                     <div
                                       style="margin-right: 10px"
@@ -720,12 +706,12 @@
                     class="left_top"
                     v-if="worksDetail[sIndex].lccjInfo.length > 0"
                   >
-                    <div class="sentenBox">
+                    <div class="sentenBox" v-for="(lcc, lccindex) in worksDetail[sIndex].lccjInfo" :key="lccindex +'d'">
                       <div
-                        v-if="worksDetail[sIndex].lccjInfo[0].score"
+                        v-if="lcc.score"
                         style="float: right; margin-right: 10px"
                       >
-                        评分:{{ worksDetail[sIndex].lccjInfo[0].score }}
+                        评分:{{lcc.score }}
                       </div>
                       <div
                         class="a_add_title"
@@ -740,8 +726,8 @@
                         <div style="font-size: 16px">排序工具</div>
                       </div>
                       <div
-                        v-for="(st, stIndex) in worksDetail[sIndex].lccjInfo"
-                        :key="stIndex"
+                        v-for="(st, stIndex) in lcc.lccjInfo"
+                        :key="stIndex+'e'"
                         style="padding-bottom: 20px"
                       >
                         <div style="padding: 15px 0 10px 20px; font-size: 20px">
@@ -750,11 +736,11 @@
                         <div class="isWrong">
                           <div
                             class="cardList1"
-                            v-if="st.lccjInfo.chooseSenList"
+                            v-if="st.chooseSenList"
                           >
                             <div class="cardBox">
                               <div
-                                v-for="(s, sIndex) in st.lccjInfo.chooseSenList"
+                                v-for="(s, sIndex) in st.chooseSenList"
                                 :key="sIndex"
                               >
                                 <el-tooltip
@@ -771,15 +757,15 @@
                             </div>
                             <div class="cardAnswerBox">
                               组成句子:{{
-                                st.lccjInfo.chooseSenList.join(" ")
+                                st.chooseSenList.join(" ")
                               }}
                             </div>
                           </div>
                           <div
                             class="answerRight isTj"
                             v-if="
-                              st.lccjInfo.chooseSenList.toString() ==
-                              st.lccjInfo.rightAnswer.toString()
+                              st.chooseSenList.toString() ==
+                              st.rightAnswer.toString()
                             "
                           >
                             <div class="isTjImg">
@@ -793,8 +779,8 @@
                           <div
                             class="answerRight isTj"
                             v-if="
-                              st.lccjInfo.chooseSenList.toString() !=
-                              st.lccjInfo.rightAnswer.toString()
+                              st.chooseSenList.toString() !=
+                              st.rightAnswer.toString()
                             "
                           >
                             <div class="isTjImg">
@@ -808,8 +794,8 @@
                         </div>
                         <div
                           v-if="
-                            st.lccjInfo.chooseSenList.toString() !=
-                            st.lccjInfo.rightAnswer.toString()
+                            st.chooseSenList.toString() !=
+                            st.rightAnswer.toString()
                           "
                         >
                           <div style="padding: 15px 0 10px 20px">
@@ -817,7 +803,7 @@
                           </div>
                           <div
                             class="cardList"
-                            v-if="st.lccjInfo.rightAnswer"
+                            v-if="st.rightAnswer"
                             style="
                               border: none;
                               padding: 10px 0 10px 10px;
@@ -826,7 +812,7 @@
                           >
                             <div class="cardBox">
                               <div
-                                v-for="(r, rIndex) in st.lccjInfo.rightAnswer"
+                                v-for="(r, rIndex) in st.rightAnswer"
                                 :key="rIndex"
                               >
                                 <el-tooltip
@@ -842,7 +828,7 @@
                               </div>
                             </div>
                             <div class="cardAnswerBox">
-                              组成句子:{{ st.lccjInfo.rightAnswer.join(" ") }}
+                              组成句子:{{ st.rightAnswer.join(" ") }}
                             </div>
                           </div>
                         </div>
@@ -1599,6 +1585,7 @@ export default {
               };
             }
             workJson[stagetask].time = res.data[0][k].time;
+            //#region 
             // for (var i = 0; i < askInfo.length; i++) {
             //   if (
             //     res.data[0][k].stage == askInfo[i].stage &&
@@ -1698,6 +1685,7 @@ export default {
             //     checkJson[stagetask].allRight = isCount / a.radio.length;
             //   }
             // }
+            //#endregion
             for (var i = 0; i < chooseInfo.length; i++) {
               if (
                 res.data[0][k].stage == chooseInfo[i].stage &&
@@ -1907,7 +1895,7 @@ export default {
           for (var i = 0; i < lccjInfo.length; i++) {
             var lccj = lccjInfo[i];
             workJson[lccjInfo[i].stage + "-" + lccjInfo[i].task].lccjInfo.push({
-              lccjInfo: JSON.parse(lccj.content)[0],
+              lccjInfo: JSON.parse(lccj.content),
               score: lccjInfo[i].score
                 ? JSON.parse(lccjInfo[i].score).wScore
                 : lccjInfo[i].score,
@@ -3521,7 +3509,22 @@ export default {
 .redioStyle >>> .el-radio__label {
   font-size: 18px;
 }
+.redioStyle5 >>> .el-radio__label {
+  font-size: 18px;
+  color: #06a7ff !important;
+
+}
+.redioStyle2 >>> .el-radio__label {
+  font-size: 18px;
+}
 
+.redioStyle3 >>> .el-checkbox__label {
+  font-size: 18px;
+  color: #06a7ff !important;
+}
+.redioStyle4 >>> .el-checkbox__label {
+  font-size: 18px;
+}
 .task_title {
   font-size: 18px;
   font-weight: 700;

+ 1299 - 1189
src/components/pages/teacherOffice/index.vue

@@ -1,1293 +1,1403 @@
 <template>
-    <div class="pb_content" style="background: unset">
-      <div v-if="ctype == 1" class="pb_content_body" style="
+  <div class="pb_content" style="background: unset">
+    <div v-if="ctype == 1" class="pb_content_body" style="
                 background: #fff;
                 padding: 0px 25px;
                 box-sizing: border-box;
                 border-radius: 5px;
               ">
-        <div class="pb_head top">
-          <span>教研室管理</span>
-          <div class="student_button" style="border-radius: 4px;">
-            <el-button type="primary" class="bgColor" @click="dialogVisible = true">添加教研室</el-button>
-          </div>
+      <div class="pb_head top">
+        <div style="display: flex;align-items: center;">
+          <span class="sub_head">教研室管理</span>
+          <span class="subClick" @click="
+            goTo(
+              '/teacherType?userid=' +
+              userid +
+              '&oid=' +
+              oid +
+              '&org=' +
+              org
+            )
+            ">教研室类型管理</span>
         </div>
-        <div class="student_head">
-          <div class="student_search">
-            <span>
-              <el-input placeholder="请输入教研室名称" v-model="sClassName" clearable>
-              </el-input>
-            </span>
-            <el-button type="primary" @click="searchClass">查询</el-button>
-          </div>
+        <div class="student_button" style="border-radius: 4px;">
+          <el-button type="primary" class="bgColor" @click="openAddTeacher">添加教研室</el-button>
         </div>
       </div>
-      <div class="pb_content_body" v-if="ctype == 1">
-        <div class="student_table">
-          <el-table v-if="ctype == 1" ref="table" :key="1" :data="tableData" border :height="tableHeight" :fit="true"
-            v-loading="isLoading" style="width: 100%; height: 60%" :header-cell-style="{ background: '#f1f1f1' }"
-            :row-class-name="tableRowClassName">
-            <el-table-column prop="name" label="教研室名称" align="center">
-            </el-table-column>
-            <el-table-column prop="pnum" label="人数" align="center">
-            </el-table-column>
-            <el-table-column label="操作" width="400px">
-              <template slot-scope="scope">
-                <el-button type="primary" size="small" @click="getStudent(scope.row.id)">查看老师</el-button>
-                <!-- <el-button type="primary" size="small" @click="updateG(scope.row.pid, scope.row.id)">修改年级</el-button> -->
-                <el-button type="primary" size="small" @click="openUpdate(scope.row.id, scope.row.name)">修改</el-button>
-                <el-button type="primary" size="small" @click="deleteClass(scope.row.id)">删除</el-button>
-              </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 class="student_head">
+        <div class="student_search">
+          <span>
+            <el-input placeholder="请输入教研室名称" v-model="sClassName" clearable>
+            </el-input>
+          </span>
+          <el-button type="primary" @click="searchClass">查询</el-button>
         </div>
       </div>
-      <div v-if="ctype == 2" class="pb_content_body" style="
+    </div>
+    <div class="pb_content_body" v-if="ctype == 1">
+      <div class="student_table">
+        <el-table v-if="ctype == 1" ref="table" :key="1" :data="tableData" border :height="tableHeight" :fit="true"
+          v-loading="isLoading" style="width: 100%; height: 60%" :header-cell-style="{ background: '#f1f1f1' }"
+          :row-class-name="tableRowClassName">
+          <el-table-column prop="name" label="教研室名称" align="center">
+          </el-table-column>
+          <el-table-column prop="typeName" label="教研室类型" align="center">
+            <template slot-scope="scope">
+              <span v-if="scope.row.parentid == 6">教研室</span>
+              <span v-else>{{ scope.row.typeName }}</span>
+            </template>
+          </el-table-column>
+          <el-table-column prop="pnum" label="人数" align="center">
+          </el-table-column>
+          <el-table-column label="操作" width="400px">
+            <template slot-scope="scope">
+              <el-button type="primary" size="small" @click="getStudent(scope.row.id)">查看老师</el-button>
+              <!-- <el-button type="primary" size="small" @Sclick="updateG(scope.row.pid, scope.row.id)">修改年级</el-button> -->
+              <el-button type="primary" size="small" @click="openUpdate(scope.row.id, scope.row.name, scope.row.parentid)">修改</el-button>
+              <el-button type="primary" size="small" @click="deleteClass(scope.row.id)">删除</el-button>
+            </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>
+    <div v-if="ctype == 2" class="pb_content_body" style="
                 background: #fff;
                 padding: 0px 25px;
                 box-sizing: border-box;
                 border-radius: 5px;
               ">
-        <div class="pb_head top">
-          <span>查看老师-{{ getGrade(cid) }}</span>
-          <div class="student_button" style="border-radius: 4px;">
-            <el-button type="primary" class="bgColor" @click="ctype = 1, getClass()">返回</el-button>
-          </div>
+      <div class="pb_head top">
+        <span>查看老师-{{ getGrade(cid) }}</span>
+        <div class="student_button" style="border-radius: 4px;">
+          <el-button type="primary" class="bgColor" @click="ctype = 1, getClass()">返回</el-button>
         </div>
-        <div class="student_head">
-          <div class="head_left">
-            <el-input v-model="sPhoneUser" class="student_input" placeholder="请输入用户名" style="margin:0 10px"></el-input>
-            <!-- <el-select disabled v-model="cid" placeholder="请选择教研室" class="student_input" @change="searchStudent"
+      </div>
+      <div class="student_head">
+        <div class="head_left">
+          <el-input v-model="sPhoneUser" class="student_input" placeholder="请输入用户名" style="margin:0 10px"></el-input>
+          <!-- <el-select disabled v-model="cid" placeholder="请选择教研室" class="student_input" @change="searchStudent"
               style="margin:0 10px">
               <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>
-          </div>
+          <el-button class="student_button" @click="searchStudent">查询</el-button>
+        </div>
+        <div class="head_right">
+          <el-button @click="addStudent">添加老师</el-button>
         </div>
       </div>
-      <div class="pb_content_body" v-if="ctype == 2">
-        <div class="student_table">
-          <el-table v-if="ctype == 2" :key="2" ref="table2" :data="tableData2" 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="
+    </div>
+    <div class="pb_content_body" v-if="ctype == 2">
+      <div class="student_table">
+        <el-table v-if="ctype == 2" :key="2" ref="table2" :data="tableData2" 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>
+                  {{ scope.row.name }}
                 </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="classname2" label="教研室" min-width="15" align="center">
-            </el-table-column>
-            <el-table-column label="操作" width="250px">
-              <template slot-scope="scope">
-                <div class="btnBox">
-                  <el-button class="de_button" type="primary" size="small"
-                    @click="iniPassword(scope.row.userid)" v-show="false">初始化密码</el-button>
-                  <!-- <el-button class="de_button" type="primary" size="small" @click="updateStudentA(scope.row)">修改</el-button> -->
-                  <el-button class="de_button" type="primary" size="small"
-                    @click="deleteClassStudent(scope.row.userid)">移除</el-button>
-                  <!-- <div class="delete">
+              </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="classname2" label="教研室" min-width="15" align="center">
+          </el-table-column>
+          <el-table-column label="操作" width="250px">
+            <template slot-scope="scope">
+              <div class="btnBox">
+                <el-button class="de_button" type="primary" size="small" @click="iniPassword(scope.row.userid)"
+                  v-show="false">初始化密码</el-button>
+                <!-- <el-button class="de_button" type="primary" size="small" @click="updateStudentA(scope.row)">修改</el-button> -->
+                <el-button class="de_button" type="primary" size="small"
+                  @click="deleteClassStudent(scope.row.userid)">移除</el-button>
+                <!-- <div class="delete">
                     <img src="../../../assets/remove.png" alt @click="deleteStudent(scope.row.userid, scope.row.state)" />
                   </div> -->
-                </div>
-              </template>
-            </el-table-column>
-          </el-table>
-        </div>
-        <div class="student_page">
-          <el-pagination background layout="prev, pager, next" :page-size="10" :total="total2" v-if="page2"
-            @current-change="handleCurrentChange2"></el-pagination>
+              </div>
+            </template>
+          </el-table-column>
+        </el-table>
+      </div>
+      <div class="student_page">
+        <el-pagination background layout="prev, pager, next" :page-size="10" :total="total2" v-if="page2"
+          @current-change="handleCurrentChange2"></el-pagination>
+      </div>
+    </div>
+    <el-dialog :visible.sync="dialogVisibleAddStudent" :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-dialog :visible.sync="dialogVisibleAddStudent" :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>
+      <el-form>
+        <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="cid" placeholder="请选择教研室" disabled>
+            <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>
-          <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="cid" placeholder="请选择教研室" disabled>
-              <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>
-      <el-dialog :visible.sync="dialogVisibleUpdate" :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>
+      </el-form>
+      <span slot="footer" class="dialog-footer flex">
+        <el-button class="right" @click="insertStudent">确认</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog :visible.sync="dialogVisibleUpdate" :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>
-        <el-form>
-          <el-form-item label="老师名称" :label-width="formLabelWidth">
-            <span>
-              <el-input placeholder="请输入老师姓名" clearable v-model="userinfo.name" class="add_input"></el-input>
-            </span>
-          </el-form-item>
-          <el-form-item label="老师学号" :label-width="formLabelWidth">
-            <span>
-              <el-input placeholder="请输入老师学号" clearable v-model="userinfo.studentid" class="add_input"></el-input>
-            </span>
-          </el-form-item>
-          <el-form-item label="老师手机号" :label-width="formLabelWidth">
-            <span>
-              <el-input placeholder="请输入老师手机号" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
-            </span>
-          </el-form-item>
-          <el-form-item label="老师账号" :label-width="formLabelWidth">
-            <span>
-              <el-input placeholder="请输入老师账号" clearable v-model="userinfo.un" 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 multiple collapse-tags v-model="userinfo.classid" 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="updateStudent">修改</el-button>
-        </span>
-      </el-dialog>
-      <el-dialog title="添加教研室" :visible.sync="dialogVisible" :append-to-body="true" width="25%" :before-close="handleClose"
-        class="dialog_diy">
-        <el-form>
-          <el-form-item label="教研室名称" :label-width="formLabelWidth">
-            <el-input v-model="className" auto-complete="off" placeholder="请输入教研室..."></el-input>
-          </el-form-item>
-        </el-form>
-        <span slot="footer" class="dialog-footer">
-          <el-button @click="dialogVisible = false">取 消</el-button>
-          <el-button type="primary" @click="insertClass">确 定</el-button>
-        </span>
-      </el-dialog>
-      <el-dialog title="修改年级" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
-        :before-close="handleClose" class="dialog_diy">
-        <el-form>
-          <el-form-item label="选择年级" :label-width="formLabelWidth">
-            <el-select v-model="gid" placeholder="请选择教研室" class="student_input" style="margin:0 10px" clearable>
-              <el-option v-for="(item, index) in grade" :key="index" :label="item.name" :value="item.id"></el-option>
-            </el-select>
-          </el-form-item>
-        </el-form>
-        <span slot="footer" class="dialog-footer">
-          <el-button @click="dialogVisibleGrade = false">取 消</el-button>
-          <el-button type="primary" @click="updateGrade">确 定</el-button>
-        </span>
-      </el-dialog>
-      <el-dialog title="修改教研室" :visible.sync="dialogVisible1" :append-to-body="true" width="25%" :before-close="handleClose"
-        class="dialog_diy">
-        <el-form>
-          <el-form-item label="教研室名称" :label-width="formLabelWidth">
-            <el-input v-model="className1" auto-complete="off" placeholder="请输入教研室..."></el-input>
-          </el-form-item>
-        </el-form>
-        <span slot="footer" class="dialog-footer">
-          <el-button @click="dialogVisible1 = false">取 消</el-button>
-          <el-button type="primary" @click="updateClass">确 定</el-button>
-        </span>
-      </el-dialog>
-      <el-dialog title="添加老师" :visible.sync="dialogVisibleMember" :append-to-body="true" width="500px" height="80%"
-        :before-close="handleClose" class="addNewPP">
-        <div class="people">
-          <div class="people_top">
-            <div class="people_top_right">
-              <div class="people_search">
-                <el-input placeholder="搜索老师姓名" v-model="searchTN" @keyup.enter.native="getClassStudent"></el-input>
-                <div class="search_img" @click="getClassStudent">
-                  <img src="../../../assets/icon/search.png" alt />
-                </div>
+        <div class="title_add_student">修改老师</div>
+      </div>
+      <el-form>
+        <el-form-item label="老师名称" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入老师姓名" clearable v-model="userinfo.name" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="老师学号" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入老师学号" clearable v-model="userinfo.studentid" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="老师手机号" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入老师手机号" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="老师账号" :label-width="formLabelWidth">
+          <span>
+            <el-input placeholder="请输入老师账号" clearable v-model="userinfo.un" 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 multiple collapse-tags v-model="userinfo.classid" 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="updateStudent">修改</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="添加教研室" :visible.sync="dialogVisible" :append-to-body="true" width="25%"
+      :before-close="handleClose" class="dialog_diy">
+      <el-form>
+        <el-form-item label="教研室名称" :label-width="formLabelWidth">
+          <el-input v-model="className" auto-complete="off" placeholder="请输入教研室..."></el-input>
+        </el-form-item>
+        <el-form-item label="教研室类型" :label-width="formLabelWidth">
+          <el-select v-model="typeId" placeholder="类型">
+            <el-option v-for="item in options" :key="item.id" :label="item.name" :value="item.id"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="handleCancel">取 消</el-button>
+        <el-button type="primary" @click="insertClass">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="修改年级" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
+      :before-close="handleClose" class="dialog_diy">
+      <el-form>
+        <el-form-item label="选择年级" :label-width="formLabelWidth">
+          <el-select v-model="gid" placeholder="请选择教研室" class="student_input" style="margin:0 10px" clearable>
+            <el-option v-for="(item, index) in grade" :key="index" :label="item.name" :value="item.id"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleGrade = false">取 消</el-button>
+        <el-button type="primary" @click="updateGrade">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="修改教研室" :visible.sync="dialogVisible1" :append-to-body="true" width="25%"
+      :before-close="handleClose" class="dialog_diy">
+      <el-form>
+        <el-form-item label="教研室名称" :label-width="formLabelWidth">
+          <el-input v-model="className1" auto-complete="off" placeholder="请输入教研室..."></el-input>
+        </el-form-item>
+        <el-form-item label="教研室类型" :label-width="formLabelWidth">
+          <el-select v-model="typeId2" placeholder="类型">
+            <el-option v-for="item in options" :key="item.id" :label="item.name" :value="item.id"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible1 = false">取 消</el-button>
+        <el-button type="primary" @click="updateClass">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="添加老师" :visible.sync="dialogVisibleMember" :append-to-body="true" width="500px" height="80%"
+      :before-close="handleClose" class="addNewPP">
+      <div class="people">
+        <div class="people_top">
+          <div class="people_top_right">
+            <div class="people_search">
+              <el-input placeholder="搜索老师姓名" v-model="searchTN" @keyup.enter.native="getClassStudent"></el-input>
+              <div class="search_img" @click="getClassStudent">
+                <img src="../../../assets/icon/search.png" alt />
               </div>
             </div>
-            <div class="people_nav">选择成员</div>
           </div>
-          <div class="t_j_box" style="
+          <div class="people_nav">选择成员</div>
+        </div>
+        <div class="t_j_box" style="
                     padding: 20px 0 0 25px;
                     width: calc(100% - 55px);
                     margin-left: 25px;
                   ">
-            <span>姓名</span>
-            <span>账号</span>
-          </div>
-          <el-checkbox-group v-model="checkboxList3" class="people_name" v-if="teacherJuri.length" v-loading="isLoading2">
-            <el-checkbox v-for="item in teacherJuri" :key="item.userid" :label="item.userid">
-              <div class="t_j_box">
-                <el-tooltip placement="top" :content="item.name ? item.name : '暂无姓名'">
-                  <span>{{ item.name ? item.name : "暂无姓名" }}</span>
-                </el-tooltip>
-                <el-tooltip placement="top" :content="item.username.split('@')[0]">
-                  <span>{{ item.username.split('@')[0] }}</span>
-                </el-tooltip>
-              </div>
-            </el-checkbox>
-          </el-checkbox-group>
-          <div style="text-align: center; margin-top: 10px" v-else>暂无数据</div>
+          <span>姓名</span>
+          <span>账号</span>
         </div>
-        <div style="margin-top: 10px;">
-          <el-pagination background layout="prev, pager, next" :page-size="pageSize3" :total="total3"
-            v-if="page3 && teacherJuri.length" style="padding-bottom: 20px"
-            @current-change="handleCurrentChange3"></el-pagination>
-        </div>
-        <span slot="footer" class="dialog-footer">
-          <el-button @click="dialogVisibleMember = false">取 消</el-button>
-          <el-button type="primary" @click="addClassStudent">确定</el-button>
-        </span>
-      </el-dialog>
-    </div>
-  </template>
-  
-  <script>
-  import TaskListHeader from 'gantt-elastic/src/components/TaskList/TaskListHeader.vue';
-  
-  export default {
-    data() {
-      return {
-        tableHeight: "500px",
-        isLoading: false,
-        formLabelWidth: "100px",
-        sClassName: "",
-        className: "",
-        className1: "",
-        classid: "",
-        dialogVisible: false,
-        dialogVisible1: false,
-        dialogVisibleUpdate: false,
-        dialogVisibleAddStudent: false,
-        tableData: [],
-        page: 1,
-        total: 0,
-        tableData2: [],
-        page2: 1,
-        total2: 0,
-        userid: this.$route.query.userid,
-        oid: this.$route.query.oid,
-        cid: "",
-        ctype: 1,
-        sName: "",
-        sPhone: "",
-        sId: "",
-        schoolName: "",
-        sByClass: "",
-        sMail: "",
-        classJuri: [],
-        userinfo: {},
-        userinfoA: {},
-        sPhoneUser: "",
-        tx: require("../../../assets/avatar.png"),
-        dialogVisibleMember: false,
-        checkboxList3: [],
-        teacherJuri: [],
-        pageSize3: 10,
-        total3: 0,
-        page3: 1,
-        isLoading2: false,
-        searchTN: "",
-        grade: [],
-        gid: "",
-        dialogVisibleGrade: false
+        <el-checkbox-group v-model="checkboxList3" class="people_name" v-if="teacherJuri.length" v-loading="isLoading2">
+          <el-checkbox v-for="item in teacherJuri" :key="item.userid" :label="item.userid">
+            <div class="t_j_box">
+              <el-tooltip placement="top" :content="item.name ? item.name : '暂无姓名'">
+                <span>{{ item.name ? item.name : "暂无姓名" }}</span>
+              </el-tooltip>
+              <el-tooltip placement="top" :content="item.username.split('@')[0]">
+                <span>{{ item.username.split('@')[0] }}</span>
+              </el-tooltip>
+            </div>
+          </el-checkbox>
+        </el-checkbox-group>
+        <div style="text-align: center; margin-top: 10px" v-else>暂无数据</div>
+      </div>
+      <div style="margin-top: 10px;">
+        <el-pagination background layout="prev, pager, next" :page-size="pageSize3" :total="total3"
+          v-if="page3 && teacherJuri.length" style="padding-bottom: 20px"
+          @current-change="handleCurrentChange3"></el-pagination>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleMember = false">取 消</el-button>
+        <el-button type="primary" @click="addClassStudent">确定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import TaskListHeader from 'gantt-elastic/src/components/TaskList/TaskListHeader.vue';
+
+export default {
+  data() {
+    return {
+      tableHeight: "500px",
+      isLoading: false,
+      formLabelWidth: "100px",
+      sClassName: "",
+      className: "",
+      className1: "",
+      classid: "",
+      dialogVisible: false,
+      dialogVisible1: false,
+      dialogVisibleUpdate: false,
+      dialogVisibleAddStudent: false,
+      tableData: [],
+      page: 1,
+      total: 0,
+      tableData2: [],
+      page2: 1,
+      total2: 0,
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      cid: "",
+      ctype: 1,
+      sName: "",
+      sPhone: "",
+      sId: "",
+      schoolName: "",
+      sByClass: "",
+      sMail: "",
+      classJuri: [],
+      userinfo: {},
+      userinfoA: {},
+      sPhoneUser: "",
+      tx: require("../../../assets/avatar.png"),
+      dialogVisibleMember: false,
+      checkboxList3: [],
+      teacherJuri: [],
+      pageSize3: 10,
+      total3: 0,
+      page3: 1,
+      isLoading2: false,
+      searchTN: "",
+      grade: [],
+      gid: "",
+      dialogVisibleGrade: false,
+      options: [
+        // {
+        //   typeId: 6,
+        //   label: '教研室'
+        // }
+      ],
+      typeId: "",
+      typeId2: ""
+    };
+  },
+  created() {
+    this.page = 1;
+    this.getClass();
+    this.getClass2();
+    this.selectGrage()
+    this.getSchoolName();
+    this.getTeacherType();
+  },
+  computed: {
+    getGrade() {
+      return function (gid) {
+        let name = ''
+        this.grade.forEach(element => {
+          if (element.id == gid) {
+            name = element.name
+          }
+        });
+        return name ? name : '暂无'
+      }
+    }
+  },
+  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: {
+    goTo(path) {
+      this.$router.push(path);
     },
-    created() {
-      this.page = 1;
-      this.getClass();
-      this.getClass2();
-      this.selectGrage()
-      this.getSchoolName();
+    //获取教研室列表
+    selectGrage() {
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+        .then((res) => {
+          this.grade = res.data[0];
+        })
+        .catch((err) => {
+          console.error(err);
+        });
     },
-    computed: {
-      getGrade() {
-        return function (gid) {
-          let name = ''
-          this.grade.forEach(element => {
-            if (element.id == gid) {
-              name = element.name
+    //获取教研室分类列表
+    getTeacherType() {
+      let params = {
+        cu: '',
+        oid: this.oid,
+        cn: '',
+        pid: '10'
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOfficeType", params)
+        .then((res) => {
+          this.options = res.data[0];
+          this.options.push(
+            {
+              id: '6',
+              name:'教研室'
             }
-          });
-          return name ? name : '暂无'
-        }
+          )
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    tableRowClassName({ row, rowIndex }) {
+      if ((rowIndex + 1) % 2 === 0) {
+        return "even_row";
+      } else {
+        return "";
       }
     },
-    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;
-          }
-        };
-      });
+    handleCurrentChange(val) {
+      this.page = val;
+      this.getClass();
     },
-    methods: {
-      //获取教研室列表
-      selectGrage() {
-        let params = {
-          oid: this.oid,
-        };
-        this.ajax
-          .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
-          .then((res) => {
-            this.grade = res.data[0];
-          })
-          .catch((err) => {
-            this.isLoading = false;
-            console.error(err);
-          });
-      },
-      tableRowClassName({ row, rowIndex }) {
-        if ((rowIndex + 1) % 2 === 0) {
-          return "even_row";
-        } else {
-          return "";
-        }
-      },
-      handleCurrentChange(val) {
-        this.page = val;
-        this.getClass();
-      },
-      handleClose(done) {
-        done();
-      },
-      time() {
-        if (!this.now) {
-          this.now = new Date().getTime();
+    handleClose(done) {
+      this.typeId = ''
+      done();
+    },
+    handleCancel() {
+      this.dialogVisible = false;
+      this.typeId = ''; // 清空下拉菜单的值
+    },
+    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 {
-          let time = new Date().getTime();
-          if (time - this.now > 3000) {
-            this.now = time;
-            return true;
-          } else {
-            return false;
-          }
+          return false;
         }
-      },
-      searchClass() {
-        this.page = 1;
-        this.getClass();
-      },
-      updateG(gid, id) {
-        this.gid = gid;
-        this.classid = id;
-        this.dialogVisibleGrade = true;
-      },
-      updateGrade() {
-        this.$confirm("确定修改吗?", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning",
-        })
-          .then(() => {
-            let params = [{
-              cid: this.gid,
-              student: JSON.stringify([this.classid])
-            }];
-            this.ajax
-              .post(this.$store.state.api + "addGradeClass", params)
-              .then((res) => {
-                this.gid = '';
-                this.classid = '';
-                this.dialogVisibleGrade = false
-                this.getClass();
-              })
-              .catch((err) => {
-                console.error(err);
-              });
-          })
-          .catch(() => { });
-      },
-      openUpdate(id, n) {
-        this.classid = id;
-        this.className1 = n;
-        this.dialogVisible1 = true;
-      },
-      //新增教研室
-      insertClass() {
-        let params = {
-          name: this.className,
-          oid: this.oid,
-          uid: this.userid,
-        };
-        this.ajax
-          .get(this.$store.state.api + "insertTeacherOffice", params)
-          .then((res) => {
-            if (res.data[0] && res.data[0][0].classname == 1) {
-              this.$message({
-                message: "不能与其他教研室名称相同!",
-                type: "error",
-              });
-            } else {
-              this.$message({
-                message: "新增成功",
-                type: "success",
-              });
-              this.dialogVisible = false;
-              this.sClassName = "";
-              this.getClass();
-              this.className = "";
-            }
-          })
-          .catch((err) => {
-            this.$message({
-              message: "新增失败",
-              type: "error",
-            });
-            console.error(err);
-          });
-      },
-      //修改教研室
-      updateClass() {
-        let params = {
-          id: this.classid,
-          n: this.className1,
-          oid: this.oid,
-        };
-        this.ajax
-          .get(this.$store.state.api + "updateTeacherOffice", params)
-          .then((res) => {
-            if (res.data[0] && res.data[0][0].classname == 1) {
-              this.$message({
-                message: "不能与其他教研室名称相同!",
-                type: "error",
-              });
-            } else {
-              this.$message({
-                message: "修改成功",
-                type: "success",
-              });
-              this.dialogVisible1 = false;
-              this.getClass();
-              this.classid = "";
-              this.className1 = "";
-            }
-          })
-          .catch((err) => {
-            this.$message({
-              message: "修改失败",
-              type: "error",
-            });
-            console.error(err);
-          });
-      },
-      //获取教研室列表
-      getClass() {
-        this.isLoading = true;
-        let params = {
-          // username: this.$store.state.userInfo.userid,
-          cu: "",
-          oid: this.oid,
-          cn: this.sClassName,
-          page: this.page,
-        };
-        this.ajax
-          .get(this.$store.state.api + "selectTeacherOffice", 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);
-          });
-      },
-      //删除教研室
-      deleteClass(id) {
-        let params = {
-          id: id,
-        };
-        if (this.time()) {
-          this.$confirm("确定删除此教研室吗?", "提示", {
-            confirmButtonText: "确定",
-            cancelButtonText: "取消",
-            type: "warning",
-          })
-            .then(() => {
-              this.ajax
-                .get(this.$store.state.api + "deleteClass", params)
-                .then((res) => {
-                  this.$message({
-                    message: "删除成功",
-                    type: "success",
-                  });
-                  if (this.page != 1 && this.tableData.length == 1) {
-                    this.page - 1;
-                  }
-                  this.getClass();
-                })
-                .catch((err) => {
-                  this.$message.error("删除失败");
-                  console.error(err);
-                });
-            })
-            .catch(() => { });
-        }
-      },
-      addStudent() {
-        // this.dialogVisibleAddStudent = true;
-        // (this.sName = ""), (this.sPhone = ""), (this.sByClass = ""), this.sMail;
-        // this.getClass2();
-        this.dialogVisibleMember = true
-        this.searchTN = ""
-        this.getClassStudent();
-      },
-      //新增老师
-      insertStudent() {
-        if (this.sName === "") {
-          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;
-        }
-  
-        if (this.time()) {
-          let params = { un: this.sMail };
+      }
+    },
+    searchClass() {
+      this.page = 1;
+      this.getClass();
+    },
+    updateG(gid, id) {
+      this.gid = gid;
+      this.classid = id;
+      this.dialogVisibleGrade = true;
+    },
+    updateGrade() {
+      this.$confirm("确定修改吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let params = [{
+            cid: this.gid,
+            student: JSON.stringify([this.classid])
+          }];
           this.ajax
-            .get(this.$store.state.api + "findMail", params)
+            .post(this.$store.state.api + "addGradeClass", params)
             .then((res) => {
-              if (res.data[0].length > 0) {
-                this.$message.error("此老师账号已被注册");
-              } else {
-                this.add_Student();
-              }
+              this.gid = '';
+              this.classid = '';
+              this.dialogVisibleGrade = false
+              this.getClass();
             })
             .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.cid,
-          },
-        ];
-        this.ajax
-          .post(this.$store.state.api + "batchRegistration", params)
-          .then((res) => {
-  
-            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 + "updateUserByEdu", params)
-              .then((res) => {
-                console.log(res);
-              })
-              .catch((err) => {
-                console.error(err);
-              });
+        })
+        .catch(() => { });
+    },
+    openUpdate(id, n, t) {
+      this.classid = id;
+      this.className1 = n;
+      this.typeId2 = t;
+      this.getTeacherType();
+      this.dialogVisible1 = true;
+    },
+    //新增教研室
+    insertClass() {
+      // 检查是否选择了教研室类型
+      if (this.typeId == "") {
+        this.$message({
+          message: "请选择教研室类型",
+          type: "warning",
+        });
+        return; // 停止继续执行
+      }
+      let params = [{
+        name: this.className,
+        oid: this.oid,
+        uid: this.userid,
+        pid: this.typeId,
+      }];
+      this.ajax
+        .post(this.$store.state.api + "insertTeacherOfficeCopy", params)
+        .then((res) => {
+          if (res.data[0] && res.data[0][0].classname == 1) {
+            this.$message({
+              message: "不能与其他教研室名称相同!",
+              type: "error",
+            });
+          } else {
             this.$message({
               message: "新增成功",
               type: "success",
             });
-            this.dialogVisibleAddStudent = false;
-            this.sPhone = "";
-            this.sName = "";
-            this.sByClass = [];
-            this.sMail = "";
-            this.getStudent(this.cid);
-          })
-          .catch((err) => {
-            this.isLoading = false;
+            this.dialogVisible = false;
+            this.sClassName = "";
+            this.getClass();
+            this.className = "";
+          }
+        })
+        .catch((err) => {
+          this.$message({
+            message: "新增失败",
+            type: "error",
+          });
+          console.error(err);
+        });
+    },
+    openAddTeacher(){
+      this.typeId = '6'
+      this.getTeacherType();
+      this.dialogVisible = true
+    },
+    //修改教研室
+    updateClass() {
+      let params = {
+        id: this.classid,
+        n: this.className1,
+        oid: this.oid,
+        pid: this.typeId2,
+      };
+      this.ajax
+        .get(this.$store.state.api + "updateTeacherOffice2", params)
+        .then((res) => {
+          if (res.data[0] && res.data[0][0].classname == 1) {
             this.$message({
-              message: "新增失败",
+              message: "不能与其他教研室名称相同!",
               type: "error",
             });
-            console.error(err);
-          });
-      },
-      updateStudentA(res) {
-        this.userinfo = JSON.parse(JSON.stringify(res));
-        this.userinfoA = JSON.parse(JSON.stringify(res));
-        this.userinfo.classid = this.userinfo.classid.split(",")
-        this.dialogVisibleUpdate = true;
-      },
-      updateStudent() {
-        if (this.userinfo.name === "") {
-          this.$message.error("老师姓名不能为空");
-          return;
-        } else if (!this.userinfo.classid) {
-          this.$message.error("请为老师选择教研室");
-          return;
-        } else if (
-          this.userinfo.phonenumber &&
-          !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.userinfo.phonenumber)
-        ) {
-          this.$message.error("手机号格式不正确");
-          return;
-        } else if (
-          !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
-            this.userinfo.un
-          )
-        ) {
-          this.$message.error("邮箱格式不正确");
-          return;
-        }
-  
-        if (this.time()) {
-          if (this.userinfoA.un != this.userinfo.un) {
-            let params = { un: this.userinfo.un };
-            this.ajax
-              .get(this.$store.state.api + "findMail", params)
-              .then((res) => {
-                if (res.data[0].length > 0) {
-                  this.$message.error("此老师账号已被注册");
-                } else {
-                  this.update_Student();
-                }
-              })
-              .catch((err) => {
-                console.error(err);
-              });
           } else {
-            this.update_Student();
-          }
-        }
-      },
-      update_Student() {
-        let params = [
-          {
-            userid: this.userinfo.userid,
-            username: this.userinfo.un,
-            alias: this.userinfo.name,
-            ph: this.userinfo.phonenumber,
-            sid: this.userinfo.studentid,
-            cid: this.userinfo.classid.join(","),
-          },
-        ];
-        this.ajax
-          .post(this.$store.state.api + "updateStudentInfo", params)
-          .then((res) => {
             this.$message({
               message: "修改成功",
               type: "success",
             });
-            this.dialogVisibleUpdate = false;
-            this.getStudent(this.cid);
-          })
-          .catch((err) => {
-            this.isLoading = false;
-            this.$message({
-              message: "修改失败",
-              type: "error",
-            });
-            console.error(err);
+            this.dialogVisible1 = false;
+            this.getClass();
+            this.classid = "";
+            this.className1 = "";
+          }
+        })
+        .catch((err) => {
+          this.$message({
+            message: "修改失败",
+            type: "error",
           });
-      },
-      deleteClassStudent(id) {
-        let params = [{ uid: id, cid: this.cid }];
-        this.$confirm("确定在本教研室移除此老师吗?", "提示", {
+          console.error(err);
+        });
+    },
+    //获取教研室列表
+    getClass() {
+      this.isLoading = true;
+      let params = {
+        // username: this.$store.state.userInfo.userid,
+        cu: "",
+        oid: this.oid,
+        cn: this.sClassName,
+        pid: "6",
+        page: this.page,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOffice2", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData = res.data[0];
+          console.log(this.tableData, "tableData");
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    //删除教研室
+    deleteClass(id) {
+      let params = {
+        id: id,
+      };
+      if (this.time()) {
+        this.$confirm("确定删除此教研室吗?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
           type: "warning",
         })
           .then(() => {
             this.ajax
-              .post(this.$store.state.api + "deleteClassTeacher", params)
+              .get(this.$store.state.api + "deleteClass", params)
               .then((res) => {
                 this.$message({
-                  message: "操作成功",
+                  message: "删除成功",
                   type: "success",
                 });
-                this.getStudent(this.cid);
+                if (this.page != 1 && this.tableData.length == 1) {
+                  this.page - 1;
+                }
+                this.getClass();
               })
               .catch((err) => {
-                this.$message.error("操作失败");
+                this.$message.error("删除失败");
                 console.error(err);
               });
           })
           .catch(() => { });
-      },
-      //获取教研室列表
-      getClass2() {
-        this.isLoading = true;
-        let params = {
-          oid: this.oid,
-        };
-        this.ajax
-          .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
-          .then((res) => {
-            this.isLoading = false;
-            this.classJuri = res.data[0];
-          })
-          .catch((err) => {
-            this.isLoading = false;
-            console.error(err);
-          });
-      },
-      getSchoolName() {
-        let params = {
-          oid: this.oid,
-        };
+      }
+    },
+    addStudent() {
+      // this.dialogVisibleAddStudent = true;
+      // (this.sName = ""), (this.sPhone = ""), (this.sByClass = ""), this.sMail;
+      // this.getClass2();
+      this.dialogVisibleMember = true
+      this.searchTN = ""
+      this.getClassStudent();
+    },
+    //新增老师
+    insertStudent() {
+      if (this.sName === "") {
+        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;
+      }
+
+      if (this.time()) {
+        let params = { un: this.sMail };
         this.ajax
-          .get(this.$store.state.api + "selectSchoolName2", params)
+          .get(this.$store.state.api + "findMail", params)
           .then((res) => {
-            this.schoolName = res.data[0][0].name;
+            if (res.data[0].length > 0) {
+              this.$message.error("此老师账号已被注册");
+            } else {
+              this.add_Student();
+            }
           })
           .catch((err) => {
             console.error(err);
           });
-      },
-      searchStudent() {
-        this.page2 = 1;
-        this.getStudent(this.cid);
-      },
-      handleCurrentChange2(val) {
-        this.page2 = val;
-        this.getStudent(this.cid);
-      },
-      handleCurrentChange3(val) {
-        this.page3 = val;
-        this.getClassStudent();
-      },
-      getStudent(cid) {
-        this.cid = cid
-        this.ctype = 2
-        this.isLoading = true;
-        let params = {
+      }
+    },
+    add_Student() {
+      let params = [
+        {
+          username: this.sMail,
+          userpassword: 123456,
+          alias: this.sName,
           oid: this.oid,
+          ph: this.sPhone,
+          sid: this.sId,
           cid: this.cid,
-          cu: "",
-          cn: this.sPhoneUser,
-          page: this.page2,
-        };
-        this.ajax
-          .get(this.$store.state.api + "selectTeacher2", params)
-          .then((res) => {
-            this.isLoading = false;
-            this.total2 = res.data[0].length > 0 ? res.data[0][0].num : 0;
-            this.tableData2 = res.data[0];
-            this.getClass2();
-          })
-          .catch((err) => {
-            this.isLoading = false;
-            console.error(err);
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "batchRegistration", params)
+        .then((res) => {
+
+          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 + "updateUserByEdu", params)
+            .then((res) => {
+              console.log(res);
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+          this.$message({
+            message: "新增成功",
+            type: "success",
           });
-      },
-      getClassStudent() {
-        this.isLoading2 = true;
-        let params = {
-          oid: this.oid,
-          cid: this.cid,
-          cn: this.searchTN,
-          page: this.page3,
-          num: this.pageSize3,
-        };
-        this.ajax
-          .get(this.$store.state.api + "getClassTeacher", params)
-          .then((res) => {
-            this.isLoading2 = false;
-            this.total3 = res.data[0].length > 0 ? res.data[0][0].num : 0;
-            this.teacherJuri = res.data[0];
-          })
-          .catch((err) => {
-            this.isLoading2 = false;
-            console.error(err);
+          this.dialogVisibleAddStudent = false;
+          this.sPhone = "";
+          this.sName = "";
+          this.sByClass = [];
+          this.sMail = "";
+          this.getStudent(this.cid);
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          this.$message({
+            message: "新增失败",
+            type: "error",
           });
-      },
-      addClassStudent() {
-        if (!this.checkboxList3.length) {
-          this.$message.error('请选择要添加教研室的老师');
-          return;
+          console.error(err);
+        });
+    },
+    updateStudentA(res) {
+      this.userinfo = JSON.parse(JSON.stringify(res));
+      this.userinfoA = JSON.parse(JSON.stringify(res));
+      this.userinfo.classid = this.userinfo.classid.split(",")
+      this.dialogVisibleUpdate = true;
+    },
+    updateStudent() {
+      if (this.userinfo.name === "") {
+        this.$message.error("老师姓名不能为空");
+        return;
+      } else if (!this.userinfo.classid) {
+        this.$message.error("请为老师选择教研室");
+        return;
+      } else if (
+        this.userinfo.phonenumber &&
+        !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.userinfo.phonenumber)
+      ) {
+        this.$message.error("手机号格式不正确");
+        return;
+      } else if (
+        !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
+          this.userinfo.un
+        )
+      ) {
+        this.$message.error("邮箱格式不正确");
+        return;
+      }
+
+      if (this.time()) {
+        if (this.userinfoA.un != this.userinfo.un) {
+          let params = { un: this.userinfo.un };
+          this.ajax
+            .get(this.$store.state.api + "findMail", params)
+            .then((res) => {
+              if (res.data[0].length > 0) {
+                this.$message.error("此老师账号已被注册");
+              } else {
+                this.update_Student();
+              }
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+        } else {
+          this.update_Student();
         }
-        let params = [{
-          cid: this.cid,
-          student: JSON.stringify(this.checkboxList3)
-        }];
-        this.ajax
-          .post(this.$store.state.api + "addClassTeacher", params)
-          .then((res) => {
-            this.$message.success("添加成功")
-            this.checkboxList3 = []
-            this.dialogVisibleMember = false
-            this.getStudent(this.cid)
-          })
-          .catch((err) => {
-            console.error(err);
+      }
+    },
+    update_Student() {
+      let params = [
+        {
+          userid: this.userinfo.userid,
+          username: this.userinfo.un,
+          alias: this.userinfo.name,
+          ph: this.userinfo.phonenumber,
+          sid: this.userinfo.studentid,
+          cid: this.userinfo.classid.join(","),
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "updateStudentInfo", params)
+        .then((res) => {
+          this.$message({
+            message: "修改成功",
+            type: "success",
           });
-      },
-      iniPassword(id) {
-        this.$confirm("确定" + "初始化" + "此老师的密码吗?", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning",
+          this.dialogVisibleUpdate = false;
+          this.getStudent(this.cid);
         })
-          .then(() => {
-            let params = [
-              {
-                uid: id,
-                pa: 123456,
-              },
-            ];
-            this.ajax
-              .post(this.$store.state.api + "iniPassword", params)
-              .then((res) => {
-                this.$message({
-                  message: "初始化密码成功!",
-                  type: "success",
-                });
-              })
-              .catch((err) => {
-                console.error(err);
+        .catch((err) => {
+          this.isLoading = false;
+          this.$message({
+            message: "修改失败",
+            type: "error",
+          });
+          console.error(err);
+        });
+    },
+    deleteClassStudent(id) {
+      let params = [{ uid: id, cid: this.cid }];
+      this.$confirm("确定在本教研室移除此老师吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.ajax
+            .post(this.$store.state.api + "deleteClassTeacher", params)
+            .then((res) => {
+              this.$message({
+                message: "操作成功",
+                type: "success",
               });
-          })
-          .catch(() => { });
-      },
+              this.getStudent(this.cid);
+            })
+            .catch((err) => {
+              this.$message.error("操作失败");
+              console.error(err);
+            });
+        })
+        .catch(() => { });
+    },
+    //获取教研室列表
+    getClass2() {
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+        .then((res) => {
+          this.classJuri = res.data[0];
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    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);
+        });
+    },
+    searchStudent() {
+      this.page2 = 1;
+      this.getStudent(this.cid);
+    },
+    handleCurrentChange2(val) {
+      this.page2 = val;
+      this.getStudent(this.cid);
+    },
+    handleCurrentChange3(val) {
+      this.page3 = val;
+      this.getClassStudent();
+    },
+    getStudent(cid) {
+      this.cid = cid
+      this.ctype = 2
+      this.isLoading = true;
+      let params = {
+        oid: this.oid,
+        cid: this.cid,
+        cu: "",
+        cn: this.sPhoneUser,
+        page: this.page2,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTeacher2", params)
+        .then((res) => {
+          this.isLoading = false;
+          this.total2 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.tableData2 = res.data[0];
+          this.getClass2();
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    getClassStudent() {
+      this.isLoading2 = true;
+      let params = {
+        oid: this.oid,
+        cid: this.cid,
+        cn: this.searchTN,
+        page: this.page3,
+        num: this.pageSize3,
+      };
+      this.ajax
+        .get(this.$store.state.api + "getClassTeacher", params)
+        .then((res) => {
+          this.isLoading2 = false;
+          this.total3 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.teacherJuri = res.data[0];
+        })
+        .catch((err) => {
+          this.isLoading2 = false;
+          console.error(err);
+        });
+    },
+    addClassStudent() {
+      if (!this.checkboxList3.length) {
+        this.$message.error('请选择要添加教研室的老师');
+        return;
+      }
+      let params = [{
+        cid: this.cid,
+        student: JSON.stringify(this.checkboxList3)
+      }];
+      this.ajax
+        .post(this.$store.state.api + "addClassTeacher", params)
+        .then((res) => {
+          this.$message.success("添加成功")
+          this.checkboxList3 = []
+          this.dialogVisibleMember = false
+          this.getStudent(this.cid)
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    iniPassword(id) {
+      this.$confirm("确定" + "初始化" + "此老师的密码吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let params = [
+            {
+              uid: id,
+              pa: 123456,
+            },
+          ];
+          this.ajax
+            .post(this.$store.state.api + "iniPassword", params)
+            .then((res) => {
+              this.$message({
+                message: "初始化密码成功!",
+                type: "success",
+              });
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+        })
+        .catch(() => { });
     },
-  };
-  </script>
-  
-  <style scoped>
-  .dialog_diy>>>.el-dialog__header {
-    background: #3d67bc !important;
-    padding: 15px 20px;
-  }
-  
-  .dialog_diy>>>.el-dialog__title {
-    color: #fff;
-  }
-  
-  .student_table>>>.el-table--border td {
-    border-right: 0px !important;
-  }
-  
-  .dialog_diy>>>.el-dialog__headerbtn {
-    top: 19px;
-  }
-  
-  .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close {
-    color: #fff;
-  }
-  
-  .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close:hover {
-    color: #fff;
-  }
-  
-  .student_head>>>.el-button--primary {
-    background-color: #2268bc;
-  }
-  
-  .xls_button {
-    font-size: 14px;
-    cursor: pointer;
-    text-decoration: underline;
-    color: rgb(34, 104, 188);
-  }
-  
-  .pb_head {
-    margin: 0 !important;
-    width: 100% !important;
-  }
-  
-  .student_page {
-    margin-top: 10px;
-  }
-  
-  .student_head {
-    margin-top: 10px;
-    padding-bottom: 15px;
-    display: flex;
-    justify-content: space-between;
-  }
-  
-  .student_search {
-    display: flex;
-    width: 300px;
-  }
-  
-  .student_search span {
-    margin: 0 10px 0 0;
-  }
-  
-  .student_button {
-    display: flex;
-    height: 40px;
-  }
-  
-  .student_button .el-button--primary {
-    /* margin-right: 10px; */
-  }
-  
-  .upload-demo {
-    display: flex;
-    flex-direction: column;
-    align-items: end;
-    /* position: relative; */
-    width: 100px;
-    overflow: hidden;
-  }
-  
-  .student_table {
-    margin: 20px 0;
-  }
-  
-  .el-table>>>.even_row {
-    background-color: #f1f1f1;
-  }
-  
-  .top {
-    display: flex;
-    justify-content: space-between;
-  }
-  
-  .bgColor {
-    background: #2167bc;
-  }
-  
-  .student_table>>>.el-table,
-  .student_table>>>.el-table__body-wrapper {
-    height: auto !important;
-  }
-  
-  .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 {
-    width: 190px;
-    font-size: 13px;
-    padding: 0 10px;
-  }
-  
-  .student_button {
-    color: #fff;
-    background: #2268bc;
-  }
-  
-  .head_right>button:nth-child(1) {
-    color: #fff;
-    background: #2268bc;
-  }
-  
-  
-  .head_right>div {
-    line-height: 40px;
-    margin-left: 10px;
-    color: #2a6dbe;
-    text-decoration: underline;
-    cursor: pointer;
-  }
-  
-  .userImg {
-    display: flex;
-    flex-direction: row;
-    justify-content: center;
-    align-items: center;
-  }
-  
-  .tx {
-    width: 40px;
-    margin-right: 10px;
-  }
-  
-  .delete {
-    width: 25px;
-    height: 25px;
-    cursor: pointer;
-    margin-left: 10px;
-  }
-  
-  .tx>img,
-  .delete>img {
-    width: 100%;
-    height: 100%;
-  }
-  
-  .btnBox {
-    display: flex;
-    align-items: center;
-  }
-  
-  .add_student>>>.el-dialog__header {
-    padding: 20px 20px 10px;
-    text-align: center;
-    background: #32455b;
-  }
-  
-  .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: #0e72e6;
-    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: #2268bc;
-    width: 70px;
-    height: 30px;
-    padding: 0 !important;
-    font-size: 12px;
-    line-height: 0 !important;
-  }
-  
-  .people {
-    border: 1px solid rgb(229 229 229);
-    height: 495px;
-    border-radius: 5px;
-    width: 100%;
-    overflow: auto;
-  }
-  
-  .people_top {
-    display: flex;
-    width: 100%;
-    /* justify-content: space-between; */
-    /* align-items: center; */
-    flex-direction: column;
-    padding: 10px 25px 0;
-    box-sizing: border-box;
-  }
-  
-  .people_nav,
-  .people_top_right {
-    /* padding: 20px 0 0 20px; */
-  }
-  
-  .people_top_right {
-    height: 40px;
-    margin-bottom: 10px;
-  }
-  
-  .people_search {
-    display: flex;
-    position: relative;
-  }
-  
-  .people_search>>>.el-input__inner {
-    /* height: 25px; */
-    width: 95%;
-  }
-  
-  .search_img {
-    width: 20px;
-    height: 20px;
-    position: absolute;
-    right: 30px;
-    top: 50%;
-    transform: translateY(-50%);
-  }
-  
-  .search_img>img {
-    width: 100%;
-    height: 100%;
-  }
-  
-  .people_name {
-    display: flex;
-    justify-content: flex-start;
-    padding: 10px 0 0 25px;
-    flex-direction: column;
-    flex-wrap: nowrap;
-    height: calc(100% - 140px);
-    overflow-y: auto;
-    overflow-x: hidden;
-    flex-direction: column;
-  }
-  
-  .people_name>>>.el-checkbox {
-    width: 100%;
-    display: flex;
-    align-items: center;
-    margin-bottom: 10px;
-  }
-  
-  .people_name>>>.el-checkbox__label {
-    text-overflow: ellipsis;
-    overflow: hidden;
-    width: 100%;
-  }
-  
-  .addNewPP>>>.el-dialog__body {
-    padding: 5px 20px;
-  }
-  
-  .t_j_box {
-    display: flex;
-  }
-  
-  .t_j_box span:nth-child(1) {
-    width: 50%;
-    overflow: hidden;
-    margin-right: 10px;
-    text-overflow: ellipsis;
-    white-space: nowrap;
-  }
-  
-  .t_j_box span:nth-child(2) {
-    width: 50%;
-    overflow: hidden;
-    margin-right: 10px;
-    text-overflow: ellipsis;
-    white-space: nowrap;
-  }
-  </style>
-  
+  },
+};
+</script>
+
+<style scoped>
+.dialog_diy>>>.el-dialog__header {
+  background: #3d67bc !important;
+  padding: 15px 20px;
+}
+
+.dialog_diy>>>.el-dialog__title {
+  color: #fff;
+}
+
+.student_table>>>.el-table--border td {
+  border-right: 0px !important;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn {
+  top: 19px;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn .el-dialog__close {
+  color: #fff;
+}
+
+.dialog_diy>>>.el-dialog__headerbtn .el-dialog__close:hover {
+  color: #fff;
+}
+
+.student_head>>>.el-button--primary {
+  background-color: #2268bc;
+}
+
+.xls_button {
+  font-size: 14px;
+  cursor: pointer;
+  text-decoration: underline;
+  color: rgb(34, 104, 188);
+}
+
+.pb_head {
+  margin: 0 !important;
+  width: 100% !important;
+}
+
+.student_page {
+  margin-top: 10px;
+}
+
+.student_head {
+  margin-top: 10px;
+  padding-bottom: 15px;
+  display: flex;
+  justify-content: space-between;
+}
+
+.student_search {
+  display: flex;
+  width: 300px;
+}
+
+.student_search span {
+  margin: 0 10px 0 0;
+}
+
+.student_button {
+  display: flex;
+  height: 40px;
+}
+
+.student_button .el-button--primary {
+  /* margin-right: 10px; */
+}
+
+.upload-demo {
+  display: flex;
+  flex-direction: column;
+  align-items: end;
+  /* position: relative; */
+  width: 100px;
+  overflow: hidden;
+}
+
+.student_table {
+  margin: 20px 0;
+}
+
+.el-table>>>.even_row {
+  background-color: #f1f1f1;
+}
+.top {
+  display: flex;
+  justify-content: space-between;
+}
+
+.bgColor {
+  background: #2167bc;
+}
+
+.student_table>>>.el-table,
+.student_table>>>.el-table__body-wrapper {
+  height: auto !important;
+}
+
+.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 {
+  width: 190px;
+  font-size: 13px;
+  padding: 0 10px;
+}
+
+.student_button {
+  color: #fff;
+  background: #2268bc;
+}
+
+.head_right>button:nth-child(1) {
+  color: #fff;
+  background: #2268bc;
+}
+
+
+.head_right>div {
+  line-height: 40px;
+  margin-left: 10px;
+  color: #2a6dbe;
+  text-decoration: underline;
+  cursor: pointer;
+}
+
+.userImg {
+  display: flex;
+  flex-direction: row;
+  justify-content: center;
+  align-items: center;
+}
+
+.tx {
+  width: 40px;
+  margin-right: 10px;
+}
+
+.delete {
+  width: 25px;
+  height: 25px;
+  cursor: pointer;
+  margin-left: 10px;
+}
+
+.tx>img,
+.delete>img {
+  width: 100%;
+  height: 100%;
+}
+
+.btnBox {
+  display: flex;
+  align-items: center;
+}
+
+.add_student>>>.el-dialog__header {
+  padding: 20px 20px 10px;
+  text-align: center;
+  background: #32455b;
+}
+
+.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: #0e72e6;
+  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: #2268bc;
+  width: 70px;
+  height: 30px;
+  padding: 0 !important;
+  font-size: 12px;
+  line-height: 0 !important;
+}
+
+.people {
+  border: 1px solid rgb(229 229 229);
+  height: 495px;
+  border-radius: 5px;
+  width: 100%;
+  overflow: auto;
+}
+
+.people_top {
+  display: flex;
+  width: 100%;
+  /* justify-content: space-between; */
+  /* align-items: center; */
+  flex-direction: column;
+  padding: 10px 25px 0;
+  box-sizing: border-box;
+}
+
+.people_nav,
+.people_top_right {
+  /* padding: 20px 0 0 20px; */
+}
+
+.people_top_right {
+  height: 40px;
+  margin-bottom: 10px;
+}
+
+.people_search {
+  display: flex;
+  position: relative;
+}
+
+.people_search>>>.el-input__inner {
+  /* height: 25px; */
+  width: 95%;
+}
+
+.search_img {
+  width: 20px;
+  height: 20px;
+  position: absolute;
+  right: 30px;
+  top: 50%;
+  transform: translateY(-50%);
+}
+
+.search_img>img {
+  width: 100%;
+  height: 100%;
+}
+
+.people_name {
+  display: flex;
+  justify-content: flex-start;
+  padding: 10px 0 0 25px;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  height: calc(100% - 140px);
+  overflow-y: auto;
+  overflow-x: hidden;
+  flex-direction: column;
+}
+
+.people_name>>>.el-checkbox {
+  width: 100%;
+  display: flex;
+  align-items: center;
+  margin-bottom: 10px;
+}
+
+.people_name>>>.el-checkbox__label {
+  text-overflow: ellipsis;
+  overflow: hidden;
+  width: 100%;
+}
+
+.addNewPP>>>.el-dialog__body {
+  padding: 5px 20px;
+}
+
+.t_j_box {
+  display: flex;
+}
+
+.t_j_box span:nth-child(1) {
+  width: 50%;
+  overflow: hidden;
+  margin-right: 10px;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.t_j_box span:nth-child(2) {
+  width: 50%;
+  overflow: hidden;
+  margin-right: 10px;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+
+.sub_head {
+  position: relative;
+}
+
+.sub_head::after {
+  content: "";
+  width: 100%;
+  background: #5a9cea;
+  height: 2px;
+  position: absolute;
+  left: 0;
+  bottom: -10px;
+}
+
+.subClick {
+  /* font-size: 16px; */
+  font-size: 26px;
+  cursor: pointer;
+  margin-left: 17.5px;
+  /* color: #ab582f; */
+  /* color: #409eff; */
+  color: #999;
+}
+
+.subClick:hover {
+  color: #000;
+}
+</style>

+ 1359 - 0
src/components/pages/teacherOffice/teacherType.vue

@@ -0,0 +1,1359 @@
+<template>
+    <div class="pb_content" style="background: unset">
+      <div v-if="ctype == 1" class="pb_content_body" style="
+                background: #fff;
+                padding: 0px 25px;
+                box-sizing: border-box;
+                border-radius: 5px;
+              ">
+        <div class="pb_head top">
+          <div style="display: flex;align-items: center;">
+            <span class="subClick" @click="
+              goTo(
+                '/teacherOffice?userid=' +
+                userid +
+                '&oid=' +
+                oid +
+                '&org=' +
+                org
+              )
+              ">教研室管理</span>
+            <span class="sub_head">教研室类型管理</span>
+          </div>
+          <div class="student_button" style="border-radius: 4px;">
+            <el-button type="primary" class="bgColor" @click="dialogVisible = true">添加教研室类型</el-button>
+          </div>
+        </div>
+        <div class="student_head">
+          <div class="student_search">
+            <span>
+              <el-input placeholder="请输入教研室类型" v-model="sClassName" clearable>
+              </el-input>
+            </span>
+            <el-button type="primary" @click="searchClass">查询</el-button>
+          </div>
+        </div>
+      </div>
+      <div class="pb_content_body" v-if="ctype == 1">
+        <div class="student_table">
+          <el-table v-if="ctype == 1" ref="table" :key="1" :data="tableData" border :height="tableHeight" :fit="true"
+            v-loading="isLoading" style="width: 100%; height: 60%" :header-cell-style="{ background: '#f1f1f1' }"
+            :row-class-name="tableRowClassName">
+            <el-table-column prop="name" label="教研室类型" align="center">
+            </el-table-column>
+            <!-- <el-table-column prop="pnum" label="人数" align="center">
+            </el-table-column> -->
+            <el-table-column label="操作" width="400px">
+              <template slot-scope="scope">
+                <!-- <el-button type="primary" size="small" @click="getStudent(scope.row.id)">查看老师</el-button> -->
+                <!-- <el-button type="primary" size="small" @click="updateG(scope.row.pid, scope.row.id)">修改年级</el-button> -->
+                <el-button type="primary" size="small" @click="openUpdate(scope.row.id, scope.row.name)">修改</el-button>
+                <el-button type="primary" size="small" @click="deleteClass(scope.row.id)">删除</el-button>
+              </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>
+      <div v-if="ctype == 2" class="pb_content_body" style="
+                background: #fff;
+                padding: 0px 25px;
+                box-sizing: border-box;
+                border-radius: 5px;
+              ">
+        <div class="pb_head top">
+          <span>查看老师-{{ getGrade(cid) }}</span>
+          <div class="student_button" style="border-radius: 4px;">
+            <el-button type="primary" class="bgColor" @click="ctype = 1, getClass()">返回</el-button>
+          </div>
+        </div>
+        <div class="student_head">
+          <div class="head_left">
+            <el-input v-model="sPhoneUser" class="student_input" placeholder="请输入用户名" style="margin:0 10px"></el-input>
+            <!-- <el-select disabled v-model="cid" placeholder="请选择教研室" class="student_input" @change="searchStudent"
+              style="margin:0 10px">
+              <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>
+          </div>
+        </div>
+      </div>
+      <div class="pb_content_body" v-if="ctype == 2">
+        <div class="student_table">
+          <el-table v-if="ctype == 2" :key="2" ref="table2" :data="tableData2" 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="classname2" label="教研室" min-width="15" align="center">
+            </el-table-column>
+            <el-table-column label="操作" width="250px">
+              <template slot-scope="scope">
+                <div class="btnBox">
+                  <el-button class="de_button" type="primary" size="small"
+                    @click="iniPassword(scope.row.userid)" v-show="false">初始化密码</el-button>
+                  <!-- <el-button class="de_button" type="primary" size="small" @click="updateStudentA(scope.row)">修改</el-button> -->
+                  <el-button class="de_button" type="primary" size="small"
+                    @click="deleteClassStudent(scope.row.userid)">移除</el-button>
+                  <!-- <div class="delete">
+                    <img src="../../../assets/remove.png" alt @click="deleteStudent(scope.row.userid, scope.row.state)" />
+                  </div> -->
+                </div>
+              </template>
+            </el-table-column>
+          </el-table>
+        </div>
+        <div class="student_page">
+          <el-pagination background layout="prev, pager, next" :page-size="10" :total="total2" v-if="page2"
+            @current-change="handleCurrentChange2"></el-pagination>
+        </div>
+      </div>
+      <el-dialog :visible.sync="dialogVisibleAddStudent" :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>
+          <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="cid" placeholder="请选择教研室" disabled>
+              <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>
+      <el-dialog :visible.sync="dialogVisibleUpdate" :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>
+          <el-form-item label="老师名称" :label-width="formLabelWidth">
+            <span>
+              <el-input placeholder="请输入老师姓名" clearable v-model="userinfo.name" class="add_input"></el-input>
+            </span>
+          </el-form-item>
+          <el-form-item label="老师学号" :label-width="formLabelWidth">
+            <span>
+              <el-input placeholder="请输入老师学号" clearable v-model="userinfo.studentid" class="add_input"></el-input>
+            </span>
+          </el-form-item>
+          <el-form-item label="老师手机号" :label-width="formLabelWidth">
+            <span>
+              <el-input placeholder="请输入老师手机号" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
+            </span>
+          </el-form-item>
+          <el-form-item label="老师账号" :label-width="formLabelWidth">
+            <span>
+              <el-input placeholder="请输入老师账号" clearable v-model="userinfo.un" 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 multiple collapse-tags v-model="userinfo.classid" 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="updateStudent">修改</el-button>
+        </span>
+      </el-dialog>
+      <el-dialog title="添加教研室类型" :visible.sync="dialogVisible" :append-to-body="true" width="25%" :before-close="handleClose"
+        class="dialog_diy">
+        <el-form>
+          <el-form-item label="教研室类型" :label-width="formLabelWidth">
+            <el-input v-model="className" auto-complete="off" placeholder="请输入教研室类型..."></el-input>
+          </el-form-item>
+        </el-form>
+
+        <span slot="footer" class="dialog-footer">
+          <el-button @click="dialogVisible = false">取 消</el-button>
+          <el-button type="primary" @click="insertClass">确 定</el-button>
+        </span>
+      </el-dialog>
+      <el-dialog title="修改年级" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
+        :before-close="handleClose" class="dialog_diy">
+        <el-form>
+          <el-form-item label="选择年级" :label-width="formLabelWidth">
+            <el-select v-model="gid" placeholder="请选择教研室" class="student_input" style="margin:0 10px" clearable>
+              <el-option v-for="(item, index) in grade" :key="index" :label="item.name" :value="item.id"></el-option>
+            </el-select>
+          </el-form-item>
+        </el-form>
+        <span slot="footer" class="dialog-footer">
+          <el-button @click="dialogVisibleGrade = false">取 消</el-button>
+          <el-button type="primary" @click="updateGrade">确 定</el-button>
+        </span>
+      </el-dialog>
+      <el-dialog title="修改教研室" :visible.sync="dialogVisible1" :append-to-body="true" width="25%" :before-close="handleClose"
+        class="dialog_diy">
+        <el-form>
+          <el-form-item label="教研室名称" :label-width="formLabelWidth">
+            <el-input v-model="className1" auto-complete="off" placeholder="请输入教研室..."></el-input>
+          </el-form-item>
+        </el-form>
+        <span slot="footer" class="dialog-footer">
+          <el-button @click="dialogVisible1 = false">取 消</el-button>
+          <el-button type="primary" @click="updateClass">确 定</el-button>
+        </span>
+      </el-dialog>
+      <el-dialog title="添加老师" :visible.sync="dialogVisibleMember" :append-to-body="true" width="500px" height="80%"
+        :before-close="handleClose" class="addNewPP">
+        <div class="people">
+          <div class="people_top">
+            <div class="people_top_right">
+              <div class="people_search">
+                <el-input placeholder="搜索老师姓名" v-model="searchTN" @keyup.enter.native="getClassStudent"></el-input>
+                <div class="search_img" @click="getClassStudent">
+                  <img src="../../../assets/icon/search.png" alt />
+                </div>
+              </div>
+            </div>
+            <div class="people_nav">选择成员</div>
+          </div>
+          <div class="t_j_box" style="
+                    padding: 20px 0 0 25px;
+                    width: calc(100% - 55px);
+                    margin-left: 25px;
+                  ">
+            <span>姓名</span>
+            <span>账号</span>
+          </div>
+          <el-checkbox-group v-model="checkboxList3" class="people_name" v-if="teacherJuri.length" v-loading="isLoading2">
+            <el-checkbox v-for="item in teacherJuri" :key="item.userid" :label="item.userid">
+              <div class="t_j_box">
+                <el-tooltip placement="top" :content="item.name ? item.name : '暂无姓名'">
+                  <span>{{ item.name ? item.name : "暂无姓名" }}</span>
+                </el-tooltip>
+                <el-tooltip placement="top" :content="item.username.split('@')[0]">
+                  <span>{{ item.username.split('@')[0] }}</span>
+                </el-tooltip>
+              </div>
+            </el-checkbox>
+          </el-checkbox-group>
+          <div style="text-align: center; margin-top: 10px" v-else>暂无数据</div>
+        </div>
+        <div style="margin-top: 10px;">
+          <el-pagination background layout="prev, pager, next" :page-size="pageSize3" :total="total3"
+            v-if="page3 && teacherJuri.length" style="padding-bottom: 20px"
+            @current-change="handleCurrentChange3"></el-pagination>
+        </div>
+        <span slot="footer" class="dialog-footer">
+          <el-button @click="dialogVisibleMember = false">取 消</el-button>
+          <el-button type="primary" @click="addClassStudent">确定</el-button>
+        </span>
+      </el-dialog>
+    </div>
+  </template>
+
+  <script>
+  import TaskListHeader from 'gantt-elastic/src/components/TaskList/TaskListHeader.vue';
+
+  export default {
+    data() {
+      return {
+        tableHeight: "500px",
+        isLoading: false,
+        formLabelWidth: "100px",
+        sClassName: "",
+        className: "",
+        className1: "",
+        classid: "",
+        dialogVisible: false,
+        dialogVisible1: false,
+        dialogVisibleUpdate: false,
+        dialogVisibleAddStudent: false,
+        tableData: [],
+        page: 1,
+        total: 0,
+        tableData2: [],
+        page2: 1,
+        total2: 0,
+        userid: this.$route.query.userid,
+        oid: this.$route.query.oid,
+        cid: "",
+        ctype: 1,
+        sName: "",
+        sPhone: "",
+        sId: "",
+        schoolName: "",
+        sByClass: "",
+        sMail: "",
+        classJuri: [],
+        userinfo: {},
+        userinfoA: {},
+        sPhoneUser: "",
+        tx: require("../../../assets/avatar.png"),
+        dialogVisibleMember: false,
+        checkboxList3: [],
+        teacherJuri: [],
+        pageSize3: 10,
+        total3: 0,
+        page3: 1,
+        isLoading2: false,
+        searchTN: "",
+        grade: [],
+        gid: "",
+        dialogVisibleGrade: false
+      };
+    },
+    created() {
+      this.page = 1;
+      this.getClass();
+      this.getClass2();
+      this.selectGrage()
+      this.getSchoolName();
+    },
+    computed: {
+      getGrade() {
+        return function (gid) {
+          let name = ''
+          this.grade.forEach(element => {
+            if (element.id == gid) {
+              name = element.name
+            }
+          });
+          return name ? name : '暂无'
+        }
+      }
+    },
+    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: {
+      goTo(path) {
+        this.$router.push(path);
+      },
+      //获取教研室列表
+      selectGrage() {
+        let params = {
+          oid: this.oid,
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+          .then((res) => {
+            this.grade = res.data[0];
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      },
+      tableRowClassName({ row, rowIndex }) {
+        if ((rowIndex + 1) % 2 === 0) {
+          return "even_row";
+        } else {
+          return "";
+        }
+      },
+      handleCurrentChange(val) {
+        this.page = val;
+        this.getClass();
+      },
+      handleClose(done) {
+        done();
+      },
+      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;
+          }
+        }
+      },
+      searchClass() {
+        this.page = 1;
+        this.getClass();
+      },
+      updateG(gid, id) {
+        this.gid = gid;
+        this.classid = id;
+        this.dialogVisibleGrade = true;
+      },
+      updateGrade() {
+        this.$confirm("确定修改吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+          .then(() => {
+            let params = [{
+              cid: this.gid,
+              student: JSON.stringify([this.classid])
+            }];
+            this.ajax
+              .post(this.$store.state.api + "addGradeClass", params)
+              .then((res) => {
+                this.gid = '';
+                this.classid = '';
+                this.dialogVisibleGrade = false
+                this.getClass();
+              })
+              .catch((err) => {
+                console.error(err);
+              });
+          })
+          .catch(() => { });
+      },
+      openUpdate(id, n) {
+        this.classid = id;
+        this.className1 = n;
+        this.dialogVisible1 = true;
+      },
+      //新增教研室
+      insertClass() {
+        let params = [{
+          name: this.className,
+          oid: this.oid,
+          uid: this.userid,
+          pid: '10',
+        }];
+        this.ajax
+          .post(this.$store.state.api + "insertTeacherOfficeCopy", params)
+          .then((res) => {
+            if (res.data[0] && res.data[0][0].classname == 1) {
+              this.$message({
+                message: "不能与其他教研室类型名称相同!",
+                type: "error",
+              });
+            } else {
+              this.$message({
+                message: "新增成功",
+                type: "success",
+              });
+              this.dialogVisible = false;
+              this.sClassName = "";
+              this.getClass();
+              this.className = "";
+            }
+          })
+          .catch((err) => {
+            this.$message({
+              message: "新增失败",
+              type: "error",
+            });
+            console.error(err);
+          });
+      },
+      //修改教研室
+      updateClass() {
+        let params = {
+          id: this.classid,
+          n: this.className1,
+          oid: this.oid,
+        };
+        this.ajax
+          .get(this.$store.state.api + "updateTeacherOffice", params)
+          .then((res) => {
+            if (res.data[0] && res.data[0][0].classname == 1) {
+              this.$message({
+                message: "不能与其他教研室名称相同!",
+                type: "error",
+              });
+            } else {
+              this.$message({
+                message: "修改成功",
+                type: "success",
+              });
+              this.dialogVisible1 = false;
+              this.getClass();
+              this.classid = "";
+              this.className1 = "";
+            }
+          })
+          .catch((err) => {
+            this.$message({
+              message: "修改失败",
+              type: "error",
+            });
+            console.error(err);
+          });
+      },
+      getType(){
+
+        let params = {
+          cu:"",
+          oid:this.oid,
+          cn:this.sClassName,
+          pid:this.pid
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectTeacherOfficeType",params)
+          .then((res) => {
+            this.tableData = res.data[0];
+            console.log(this.tableData,"tableData在此");
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      },
+      //获取教研室列表
+      getClass() {
+        this.isLoading = true;
+        let params = {
+          // username: this.$store.state.userInfo.userid,
+          cu: "",
+          oid: this.oid,
+          cn: this.sClassName,
+          pid: '10',
+          page: this.page
+
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectTeacherofficeTypeLim", 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);
+          });
+      },
+      //删除教研室
+      deleteClass(id) {
+        let params = {
+          id: id,
+        };
+        if (this.time()) {
+          this.$confirm("确定删除此教研室吗?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning",
+          })
+            .then(() => {
+              this.ajax
+                .get(this.$store.state.api + "deleteClass", params)
+                .then((res) => {
+                  this.$message({
+                    message: "删除成功",
+                    type: "success",
+                  });
+                  if (this.page != 1 && this.tableData.length == 1) {
+                    this.page - 1;
+                  }
+                  this.getClass();
+                })
+                .catch((err) => {
+                  this.$message.error("删除失败");
+                  console.error(err);
+                });
+            })
+            .catch(() => { });
+        }
+      },
+      addStudent() {
+        // this.dialogVisibleAddStudent = true;
+        // (this.sName = ""), (this.sPhone = ""), (this.sByClass = ""), this.sMail;
+        // this.getClass2();
+        this.dialogVisibleMember = true
+        this.searchTN = ""
+        this.getClassStudent();
+      },
+      //新增老师
+      insertStudent() {
+        if (this.sName === "") {
+          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;
+        }
+
+        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,
+            oid: this.oid,
+            ph: this.sPhone,
+            sid: this.sId,
+            cid: this.cid,
+          },
+        ];
+        this.ajax
+          .post(this.$store.state.api + "batchRegistration", params)
+          .then((res) => {
+
+            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 + "updateUserByEdu", params)
+              .then((res) => {
+                console.log(res);
+              })
+              .catch((err) => {
+                console.error(err);
+              });
+            this.$message({
+              message: "新增成功",
+              type: "success",
+            });
+            this.dialogVisibleAddStudent = false;
+            this.sPhone = "";
+            this.sName = "";
+            this.sByClass = [];
+            this.sMail = "";
+            this.getStudent(this.cid);
+          })
+          .catch((err) => {
+            this.isLoading = false;
+            this.$message({
+              message: "新增失败",
+              type: "error",
+            });
+            console.error(err);
+          });
+      },
+      updateStudentA(res) {
+        this.userinfo = JSON.parse(JSON.stringify(res));
+        this.userinfoA = JSON.parse(JSON.stringify(res));
+        this.userinfo.classid = this.userinfo.classid.split(",")
+        this.dialogVisibleUpdate = true;
+      },
+      updateStudent() {
+        if (this.userinfo.name === "") {
+          this.$message.error("老师姓名不能为空");
+          return;
+        } else if (!this.userinfo.classid) {
+          this.$message.error("请为老师选择教研室");
+          return;
+        } else if (
+          this.userinfo.phonenumber &&
+          !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.userinfo.phonenumber)
+        ) {
+          this.$message.error("手机号格式不正确");
+          return;
+        } else if (
+          !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
+            this.userinfo.un
+          )
+        ) {
+          this.$message.error("邮箱格式不正确");
+          return;
+        }
+
+        if (this.time()) {
+          if (this.userinfoA.un != this.userinfo.un) {
+            let params = { un: this.userinfo.un };
+            this.ajax
+              .get(this.$store.state.api + "findMail", params)
+              .then((res) => {
+                if (res.data[0].length > 0) {
+                  this.$message.error("此老师账号已被注册");
+                } else {
+                  this.update_Student();
+                }
+              })
+              .catch((err) => {
+                console.error(err);
+              });
+          } else {
+            this.update_Student();
+          }
+        }
+      },
+      update_Student() {
+        let params = [
+          {
+            userid: this.userinfo.userid,
+            username: this.userinfo.un,
+            alias: this.userinfo.name,
+            ph: this.userinfo.phonenumber,
+            sid: this.userinfo.studentid,
+            cid: this.userinfo.classid.join(","),
+          },
+        ];
+        this.ajax
+          .post(this.$store.state.api + "updateStudentInfo", params)
+          .then((res) => {
+            this.$message({
+              message: "修改成功",
+              type: "success",
+            });
+            this.dialogVisibleUpdate = false;
+            this.getStudent(this.cid);
+          })
+          .catch((err) => {
+            this.isLoading = false;
+            this.$message({
+              message: "修改失败",
+              type: "error",
+            });
+            console.error(err);
+          });
+      },
+      deleteClassStudent(id) {
+        let params = [{ uid: id, cid: this.cid }];
+        this.$confirm("确定在本教研室移除此老师吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+          .then(() => {
+            this.ajax
+              .post(this.$store.state.api + "deleteClassTeacher", params)
+              .then((res) => {
+                this.$message({
+                  message: "操作成功",
+                  type: "success",
+                });
+                this.getStudent(this.cid);
+              })
+              .catch((err) => {
+                this.$message.error("操作失败");
+                console.error(err);
+              });
+          })
+          .catch(() => { });
+      },
+      //获取教研室列表
+      getClass2() {
+        this.isLoading = true;
+        let params = {
+          oid: this.oid,
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectTeacherOfficeBySchool", params)
+          .then((res) => {
+            this.isLoading = false;
+            this.classJuri = res.data[0];
+          })
+          .catch((err) => {
+            this.isLoading = false;
+            console.error(err);
+          });
+      },
+      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);
+          });
+      },
+      searchStudent() {
+        this.page2 = 1;
+        this.getStudent(this.cid);
+      },
+      handleCurrentChange2(val) {
+        this.page2 = val;
+        this.getStudent(this.cid);
+      },
+      handleCurrentChange3(val) {
+        this.page3 = val;
+        this.getClassStudent();
+      },
+      getStudent(cid) {
+        this.cid = cid
+        this.ctype = 2
+        this.isLoading = true;
+        let params = {
+          oid: this.oid,
+          cid: this.cid,
+          cu: "",
+          cn: this.sPhoneUser,
+          page: this.page2,
+        };
+        this.ajax
+          .get(this.$store.state.api + "selectTeacher2", params)
+          .then((res) => {
+            this.isLoading = false;
+            this.total2 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+            this.tableData2 = res.data[0];
+            this.getClass2();
+          })
+          .catch((err) => {
+            this.isLoading = false;
+            console.error(err);
+          });
+      },
+      getClassStudent() {
+        this.isLoading2 = true;
+        let params = {
+          oid: this.oid,
+          cid: this.cid,
+          cn: this.searchTN,
+          page: this.page3,
+          num: this.pageSize3,
+        };
+        this.ajax
+          .get(this.$store.state.api + "getClassTeacher", params)
+          .then((res) => {
+            this.isLoading2 = false;
+            this.total3 = res.data[0].length > 0 ? res.data[0][0].num : 0;
+            this.teacherJuri = res.data[0];
+          })
+          .catch((err) => {
+            this.isLoading2 = false;
+            console.error(err);
+          });
+      },
+      addClassStudent() {
+        if (!this.checkboxList3.length) {
+          this.$message.error('请选择要添加教研室的老师');
+          return;
+        }
+        let params = [{
+          cid: this.cid,
+          student: JSON.stringify(this.checkboxList3)
+        }];
+        this.ajax
+          .post(this.$store.state.api + "addClassTeacher", params)
+          .then((res) => {
+            this.$message.success("添加成功")
+            this.checkboxList3 = []
+            this.dialogVisibleMember = false
+            this.getStudent(this.cid)
+          })
+          .catch((err) => {
+            console.error(err);
+          });
+      },
+      iniPassword(id) {
+        this.$confirm("确定" + "初始化" + "此老师的密码吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+          .then(() => {
+            let params = [
+              {
+                uid: id,
+                pa: 123456,
+              },
+            ];
+            this.ajax
+              .post(this.$store.state.api + "iniPassword", params)
+              .then((res) => {
+                this.$message({
+                  message: "初始化密码成功!",
+                  type: "success",
+                });
+              })
+              .catch((err) => {
+                console.error(err);
+              });
+          })
+          .catch(() => { });
+      },
+    },
+  };
+  </script>
+
+  <style scoped>
+  .dialog_diy>>>.el-dialog__header {
+    background: #3d67bc !important;
+    padding: 15px 20px;
+  }
+
+  .dialog_diy>>>.el-dialog__title {
+    color: #fff;
+  }
+
+  .student_table>>>.el-table--border td {
+    border-right: 0px !important;
+  }
+
+  .dialog_diy>>>.el-dialog__headerbtn {
+    top: 19px;
+  }
+
+  .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close {
+    color: #fff;
+  }
+
+  .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close:hover {
+    color: #fff;
+  }
+
+  .student_head>>>.el-button--primary {
+    background-color: #2268bc;
+  }
+
+  .xls_button {
+    font-size: 14px;
+    cursor: pointer;
+    text-decoration: underline;
+    color: rgb(34, 104, 188);
+  }
+
+  .pb_head {
+    margin: 0 !important;
+    width: 100% !important;
+  }
+
+  .student_page {
+    margin-top: 10px;
+  }
+
+  .student_head {
+    margin-top: 10px;
+    padding-bottom: 15px;
+    display: flex;
+    justify-content: space-between;
+  }
+
+  .student_search {
+    display: flex;
+    width: 300px;
+  }
+
+  .student_search span {
+    margin: 0 10px 0 0;
+  }
+
+  .student_button {
+    display: flex;
+    height: 40px;
+  }
+
+  .student_button .el-button--primary {
+    /* margin-right: 10px; */
+  }
+
+  .upload-demo {
+    display: flex;
+    flex-direction: column;
+    align-items: end;
+    /* position: relative; */
+    width: 100px;
+    overflow: hidden;
+  }
+
+  .student_table {
+    margin: 20px 0;
+  }
+
+  .el-table>>>.even_row {
+    background-color: #f1f1f1;
+  }
+
+  .top {
+    display: flex;
+    justify-content: space-between;
+  }
+
+  .bgColor {
+    background: #2167bc;
+  }
+
+  .student_table>>>.el-table,
+  .student_table>>>.el-table__body-wrapper {
+    height: auto !important;
+  }
+
+  .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 {
+    width: 190px;
+    font-size: 13px;
+    padding: 0 10px;
+  }
+
+  .student_button {
+    color: #fff;
+    background: #2268bc;
+  }
+
+  .head_right>button:nth-child(1) {
+    color: #fff;
+    background: #2268bc;
+  }
+
+
+  .head_right>div {
+    line-height: 40px;
+    margin-left: 10px;
+    color: #2a6dbe;
+    text-decoration: underline;
+    cursor: pointer;
+  }
+
+  .userImg {
+    display: flex;
+    flex-direction: row;
+    justify-content: center;
+    align-items: center;
+  }
+
+  .tx {
+    width: 40px;
+    margin-right: 10px;
+  }
+
+  .delete {
+    width: 25px;
+    height: 25px;
+    cursor: pointer;
+    margin-left: 10px;
+  }
+
+  .tx>img,
+  .delete>img {
+    width: 100%;
+    height: 100%;
+  }
+
+  .btnBox {
+    display: flex;
+    align-items: center;
+  }
+
+  .add_student>>>.el-dialog__header {
+    padding: 20px 20px 10px;
+    text-align: center;
+    background: #32455b;
+  }
+
+  .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: #0e72e6;
+    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: #2268bc;
+    width: 70px;
+    height: 30px;
+    padding: 0 !important;
+    font-size: 12px;
+    line-height: 0 !important;
+  }
+
+  .people {
+    border: 1px solid rgb(229 229 229);
+    height: 495px;
+    border-radius: 5px;
+    width: 100%;
+    overflow: auto;
+  }
+
+  .people_top {
+    display: flex;
+    width: 100%;
+    /* justify-content: space-between; */
+    /* align-items: center; */
+    flex-direction: column;
+    padding: 10px 25px 0;
+    box-sizing: border-box;
+  }
+
+  .people_nav,
+  .people_top_right {
+    /* padding: 20px 0 0 20px; */
+  }
+
+  .people_top_right {
+    height: 40px;
+    margin-bottom: 10px;
+  }
+
+  .people_search {
+    display: flex;
+    position: relative;
+  }
+
+  .people_search>>>.el-input__inner {
+    /* height: 25px; */
+    width: 95%;
+  }
+
+  .search_img {
+    width: 20px;
+    height: 20px;
+    position: absolute;
+    right: 30px;
+    top: 50%;
+    transform: translateY(-50%);
+  }
+
+  .search_img>img {
+    width: 100%;
+    height: 100%;
+  }
+
+  .people_name {
+    display: flex;
+    justify-content: flex-start;
+    padding: 10px 0 0 25px;
+    flex-direction: column;
+    flex-wrap: nowrap;
+    height: calc(100% - 140px);
+    overflow-y: auto;
+    overflow-x: hidden;
+    flex-direction: column;
+  }
+
+  .people_name>>>.el-checkbox {
+    width: 100%;
+    display: flex;
+    align-items: center;
+    margin-bottom: 10px;
+  }
+
+  .people_name>>>.el-checkbox__label {
+    text-overflow: ellipsis;
+    overflow: hidden;
+    width: 100%;
+  }
+
+  .addNewPP>>>.el-dialog__body {
+    padding: 5px 20px;
+  }
+
+  .t_j_box {
+    display: flex;
+  }
+
+  .t_j_box span:nth-child(1) {
+    width: 50%;
+    overflow: hidden;
+    margin-right: 10px;
+    text-overflow: ellipsis;
+    white-space: nowrap;
+  }
+
+  .t_j_box span:nth-child(2) {
+    width: 50%;
+    overflow: hidden;
+    margin-right: 10px;
+    text-overflow: ellipsis;
+    white-space: nowrap;
+  }
+
+
+  .sub_head {
+  position: relative;
+}
+
+.sub_head::after {
+  content: "";
+  width: 100%;
+  background: #5a9cea;
+  height: 2px;
+  position: absolute;
+  left: 0;
+  bottom: -10px;
+
+}
+
+.subClick {
+  /* font-size: 16px; */
+  font-size: 26px;
+  cursor: pointer;
+  /* color: #ab582f; */
+  /* color: #409eff; */
+  color: #999;
+  margin-right: 17.5px;
+
+}
+
+.subClick:hover {
+  color: #000;
+}
+  </style>

+ 5 - 0
src/components/pages/test/index.vue

@@ -1321,6 +1321,11 @@ export default {
             this.getCourse2();
         }
         this.selectTestType();
+        window.onbeforeunload = function(event) {
+            event.preventDefault();
+            event.returnValue = false;
+            return false
+        }
     },
 };
 </script>

+ 19 - 15
src/components/pages/works.vue

@@ -78,7 +78,7 @@
                 :label="c.name"
               ></el-option>
             </el-select>
-            <div
+            <!-- <div
               style="
                 line-height: 35px;
                 font-size: 14px;
@@ -87,8 +87,8 @@
               "
             >
               目标筛选
-            </div>
-            <el-select v-model="eChoose" @change="search" clear="mbCss">
+            </div> -->
+            <!-- <el-select v-model="eChoose" @change="search" clear="mbCss">
               <el-option label="全部" value="">全部</el-option>
               <el-option
                 v-for="(e, eIndex) in evaJuri"
@@ -96,7 +96,7 @@
                 :value="e.id"
                 :label="e.title"
               ></el-option>
-            </el-select>
+            </el-select> -->
             <el-input
               v-model="cn"
               placeholder="筛选项目名称"
@@ -135,7 +135,7 @@
           >
             <el-table-column
               prop="title"
-              label="项目"
+              label="课程"
               min-width="30"
               align="center"
             ></el-table-column>
@@ -154,7 +154,7 @@
               min-width="30"
               align="center"
             ></el-table-column>
-            <el-table-column
+            <!-- <el-table-column
               prop="evaTitle"
               label="目标名称"
               min-width="30"
@@ -169,8 +169,8 @@
               label="时间"
               min-width="20"
               align="center"
-            ></el-table-column>
-            <el-table-column label="操作" width="200px">
+            ></el-table-column> -->
+            <el-table-column align="center" label="操作" width="200px">
               <template slot-scope="scope">
                 <!-- <el-button
                 type="primary"
@@ -191,7 +191,7 @@
                   type="primary"
                   size="small"
                   @click="getWorkData(scope.row)"
-                  >查看课程</el-button
+                  >查看作业</el-button
                 >
                 <el-button
                   type="primary"
@@ -237,6 +237,7 @@
       :uid="userid"
       :cid="dataJson.courseId"
       :ooid="oid"
+      :dialogVisible.sync="dialogVisible"
       v-if="dialogVisible"
       class="workdates"
     ></WorkDate>
@@ -320,8 +321,9 @@
               prop="sName"
               label="姓名"
               min-width="20"
+              align="center"
             ></el-table-column>
-            <el-table-column label="操作" min-width="20">
+            <el-table-column align="center" label="操作" min-width="20">
               <template slot-scope="scope">
                 <el-button
                   type="primary"
@@ -351,12 +353,13 @@
       <studentReport
         :checkCourse="checkCourse"
         :checkStudent="checkStudent"
+        @cancelR="cancelR"
         :oid="oid"
       ></studentReport>
     </div>
-    <div class="cancelbox" v-if="reportVisible">
+    <!-- <div class="cancelbox" v-if="reportVisible">
       <el-button @click="cancelR" type="primary" size="small">返回</el-button>
-    </div>
+    </div> -->
   </div>
 </template>
 
@@ -776,12 +779,13 @@ export default {
 .cancelbox {
   position: absolute;
   z-index: 2;
-  left: 50%;
-  width: 95%;
+  /* left: 50%; */
+  right: 0;
+  /* width: 95%; */
   transform: translateX(-50%);
   display: flex;
   justify-content: flex-end;
-  padding: 0 90px 0px 0px;
+  /* padding: 0 90px 0px 0px; */
   box-sizing: border-box;
 }
 

+ 9 - 0
src/router/index.js

@@ -4,6 +4,7 @@ import ElementUI from 'element-ui'
 import 'element-ui/lib/theme-chalk/index.css'
 import classA from '@/components/pages/studentManage/class'
 import teacherOffice from '@/components/pages/teacherOffice'
+import teacherType from '@/components/pages/teacherOffice/teacherType'
 import grade from '@/components/pages/studentManage/grade'
 import classGM from '@/components/pages/classGM'
 import course from '@/components/pages/course'
@@ -159,6 +160,14 @@ export default new Router({
                 requireAuth: ''
             }
         },
+        {
+            path: '/teacherType',
+            name: 'teacherType',
+            component: teacherType,
+            meta: {
+                requireAuth: ''
+            }
+        },
         {
             path: '/classGM',
             name: 'classGM',

二进制
static/SourceHanSans-Regular.otf


部分文件因为文件数量过多而无法显示