Selaa lähdekoodia

后去beta分支最新代码

11wqe1 2 viikkoa sitten
vanhempi
commit
f59809d6fe
88 muutettua tiedostoa jossa 25515 lisäystä ja 1526 poistoa
  1. 3 0
      src/assets/icon/liyuan/arrow-up.svg
  2. 5 0
      src/assets/icon/liyuan/courseEdit.svg
  3. 12 0
      src/assets/icon/liyuan/courseEditC.svg
  4. BIN
      src/assets/icon/secondToolList/ppt.png
  5. 3 0
      src/assets/icon/workPage/start_icon.svg
  6. 4 0
      src/assets/icon/workPage/status_icon.svg
  7. 3 0
      src/assets/icon/workPage/stop_icon.svg
  8. 8 3
      src/common/Export2Excel.js
  9. 2 1
      src/common/tools.js
  10. 698 0
      src/components/pages/PersonnelManagement/components/classL.vue
  11. 344 0
      src/components/pages/PersonnelManagement/components/grade.vue
  12. 969 0
      src/components/pages/PersonnelManagement/components/student.vue
  13. 383 0
      src/components/pages/PersonnelManagement/index.vue
  14. 257 9
      src/components/pages/aiAddCourse/addCourse.vue
  15. 275 7
      src/components/pages/aiEasy/addCourse.vue
  16. 9 2
      src/components/pages/classroomObservation/components/analysisSpecialItem.vue
  17. 556 456
      src/components/pages/classroomObservation/components/chatArea.vue
  18. 5 3
      src/components/pages/classroomObservation/components/messageArea.vue
  19. 1 1
      src/components/pages/classroomObservation/components/transcription.vue
  20. 25 4
      src/components/pages/classroomObservation/dialog/batchCreationClassDialog.vue
  21. 188 93
      src/components/pages/classroomObservation/index.vue
  22. 4 4
      src/components/pages/classroomObservation/newComponents/batchClassCard.vue
  23. 150 84
      src/components/pages/classroomObservation/tools/mixin.js
  24. 59 5
      src/components/pages/course.vue
  25. 36 1
      src/components/pages/data.vue
  26. 216 0
      src/components/pages/dialog/selectHtmlPageDialog.vue
  27. 360 35
      src/components/pages/easy/addCourse.vue
  28. 1 1
      src/components/pages/evaluation.vue
  29. 11 4
      src/components/pages/inviteLoginST/inviteLogin.vue
  30. 58 8
      src/components/pages/inviteLoginSZ/inviteLogin.vue
  31. 55 1
      src/components/pages/library/fileBox.vue
  32. 397 2
      src/components/pages/liyuan/CourseCon.vue
  33. 13 4
      src/components/pages/liyuan/aiOffice.vue
  34. 18 6
      src/components/pages/liyuan/components/backPage.vue
  35. 49 12
      src/components/pages/liyuan/components/card.vue
  36. 87 28
      src/components/pages/liyuan/page/examine/index.vue
  37. 1 1
      src/components/pages/liyuan/page/portrait/index.vue
  38. 1 1
      src/components/pages/liyuan/page/student.vue
  39. 127 74
      src/components/pages/liyuan/page/teadTest.vue
  40. 3 3
      src/components/pages/liyuan/schoolSafe.vue
  41. 13 4
      src/components/pages/liyuan/teacherDevelop.vue
  42. 82 0
      src/components/pages/liyuan/topTalent.vue
  43. 294 11
      src/components/pages/newCourse/addCourse.vue
  44. 274 0
      src/components/pages/noticeCenter/component/received.vue
  45. 250 0
      src/components/pages/noticeCenter/dialog/noticeDetailDialog.vue
  46. 62 0
      src/components/pages/noticeCenter/index.vue
  47. 12414 0
      src/components/pages/pptEasy/addCourse.vue
  48. 360 0
      src/components/pages/pptEasy/commpont/englishRight.vue
  49. 250 0
      src/components/pages/pptEasy/dialog/InteractiveToolDialog.vue
  50. 45 16
      src/components/pages/sassPlatform/index.vue
  51. 26 13
      src/components/pages/studentManage/student.vue
  52. 39 2
      src/components/pages/sz/teacher.vue
  53. 122 122
      src/components/pages/teacherOffice/index.vue
  54. 112 112
      src/components/pages/teacherOffice/teacherType.vue
  55. 55 53
      src/components/pages/test/add/addTest.vue
  56. 17 2
      src/components/pages/test/add/setInfo/index.vue
  57. 2 2
      src/components/pages/test/aggregate/index.vue
  58. 5 3
      src/components/pages/test/check/check.vue
  59. 1 1
      src/components/pages/test/check/docxTemplateDialog.vue
  60. 554 177
      src/components/pages/test/check/index.vue
  61. 333 0
      src/components/pages/test/check/returnTestDialog.vue
  62. 43 7
      src/components/pages/test/checkAi/aiLeader.vue
  63. 7 3
      src/components/pages/test/databoard.vue
  64. 499 34
      src/components/pages/test/examine/conpoments/personPage.vue
  65. 122 10
      src/components/pages/test/examine/conpoments/targetPage.vue
  66. 13 6
      src/components/pages/test/examine/index.vue
  67. 55 10
      src/components/pages/test/index.vue
  68. 1 12
      src/components/pages/test/smarter.vue
  69. 95 29
      src/components/pages/testPerson/examine/index.vue
  70. 1 1
      src/components/pages/testPerson/info/index.vue
  71. 936 0
      src/components/pages/testPerson/info/infoDialognew/index.vue
  72. 18 3
      src/components/pages/testPerson/test/index.vue
  73. 66 6
      src/components/pages/testPerson/test/test.vue
  74. 110 24
      src/components/pages/testStudent/view/preview.vue
  75. 1 1
      src/components/pages/test_old/examine/conpoments/personPage.vue
  76. 4 4
      src/components/pages/test_old/examine/conpoments/targetPage.vue
  77. 415 0
      src/components/pages/workPage/components/choiceQuestion.vue
  78. 32 0
      src/components/pages/workPage/components/questionsAndAnswers.vue
  79. 343 0
      src/components/pages/workPage/components/wangEnduit.vue
  80. 777 0
      src/components/pages/workPage/index.vue
  81. 791 0
      src/components/pages/workPage/index_new.vue
  82. 1 1
      src/components/pages/works.vue
  83. 3 2
      src/components/tools/hevue-img-preview/hevue-img-preview.vue
  84. 293 0
      src/components/tools/uploadFileMixin.js
  85. 2 2
      src/config/config.js
  86. 65 0
      src/router/index.js
  87. 33 0
      src/router/index2.js
  88. 83 0
      src/workPage/main.js

+ 3 - 0
src/assets/icon/liyuan/arrow-up.svg

@@ -0,0 +1,3 @@
+<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M9.87109 7C9.87109 7.12775 9.83001 7.23249 9.74805 7.31445L4.86719 11.9629C4.77591 12.0448 4.67575 12.0859 4.56641 12.0859C4.45706 12.0859 4.3569 12.0448 4.26563 11.9629L4.25195 11.9629C4.17 11.8809 4.12891 11.783 4.12891 11.6689C4.12892 11.5549 4.17001 11.4569 4.25195 11.375L8.8457 7L4.25195 2.625C4.17001 2.54305 4.12892 2.44507 4.12891 2.33105C4.12891 2.21701 4.16999 2.11907 4.25195 2.03711L4.26563 2.03711C4.3569 1.95519 4.45706 1.91406 4.56641 1.91406C4.67575 1.91406 4.77591 1.95519 4.86719 2.03711L9.74805 6.68555C9.83001 6.76751 9.87109 6.87225 9.87109 7Z" fill="#969BA3"/>
+</svg>

+ 5 - 0
src/assets/icon/liyuan/courseEdit.svg

@@ -0,0 +1,5 @@
+<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
+<rect x="0.25" y="0.25" width="27.5" height="27.5" rx="13.75" stroke="black" stroke-width="0.5"/>
+<path d="M14 8H9.33333C8.97971 8 8.64057 8.14048 8.39052 8.39052C8.14048 8.64057 8 8.97971 8 9.33333V18.6667C8 19.0203 8.14048 19.3594 8.39052 19.6095C8.64057 19.8595 8.97971 20 9.33333 20H18.6667C19.0203 20 19.3594 19.8595 19.6095 19.6095C19.8595 19.3594 20 19.0203 20 18.6667V14" stroke="black" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M18.2499 7.75003C18.5151 7.48481 18.8748 7.33582 19.2499 7.33582C19.625 7.33582 19.9847 7.48481 20.2499 7.75003C20.5151 8.01525 20.6641 8.37496 20.6641 8.75003C20.6641 9.1251 20.5151 9.48481 20.2499 9.75003L14.2412 15.7594C14.0829 15.9175 13.8874 16.0333 13.6726 16.096L11.7572 16.656C11.6999 16.6728 11.6391 16.6738 11.5812 16.6589C11.5233 16.6441 11.4705 16.614 11.4282 16.5717C11.3859 16.5295 11.3558 16.4766 11.341 16.4188C11.3262 16.3609 11.3272 16.3001 11.3439 16.2427L11.9039 14.3274C11.9669 14.1127 12.0829 13.9174 12.2412 13.7594L18.2499 7.75003Z" stroke="black" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+</svg>

+ 12 - 0
src/assets/icon/liyuan/courseEditC.svg

@@ -0,0 +1,12 @@
+<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g clip-path="url(#clip0_61_67)">
+<path d="M27.75 14C27.75 6.40608 21.5939 0.25 14 0.25C6.40608 0.25 0.25 6.40608 0.25 14C0.25 21.5939 6.40608 27.75 14 27.75C21.5939 27.75 27.75 21.5939 27.75 14Z" stroke="#C4C4C4" stroke-width="0.5"/>
+<path d="M14 8H9.33333C8.97971 8 8.64057 8.14048 8.39052 8.39052C8.14048 8.64057 8 8.97971 8 9.33333V18.6667C8 19.0203 8.14048 19.3594 8.39052 19.6095C8.64057 19.8595 8.97971 20 9.33333 20H18.6667C19.0203 20 19.3594 19.8595 19.6095 19.6095C19.8595 19.3594 20 19.0203 20 18.6667V14" stroke="#606266" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M18.2494 7.75015C18.5146 7.48493 18.8743 7.33594 19.2494 7.33594C19.6245 7.33594 19.9842 7.48493 20.2494 7.75015C20.5146 8.01537 20.6636 8.37508 20.6636 8.75015C20.6636 9.12522 20.5146 9.48493 20.2494 9.75015L14.2407 15.7595C14.0824 15.9176 13.8869 16.0334 13.6721 16.0961L11.7567 16.6561C11.6994 16.6729 11.6386 16.6739 11.5807 16.659C11.5228 16.6442 11.47 16.6141 11.4277 16.5718C11.3854 16.5296 11.3553 16.4767 11.3405 16.4189C11.3257 16.361 11.3267 16.3002 11.3434 16.2428L11.9034 14.3275C11.9664 14.1128 12.0824 13.9175 12.2407 13.7595L18.2494 7.75015Z" stroke="#606266" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
+</g>
+<defs>
+<clipPath id="clip0_61_67">
+<rect width="28" height="28" fill="white"/>
+</clipPath>
+</defs>
+</svg>

BIN
src/assets/icon/secondToolList/ppt.png


+ 3 - 0
src/assets/icon/workPage/start_icon.svg

@@ -0,0 +1,3 @@
+<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M5.43945 4.13574C5.74868 3.95725 6.13016 3.9574 6.43945 4.13574L18.5605 11.1338C18.8697 11.3124 19.0605 11.6429 19.0605 12C19.0605 12.3571 18.8698 12.6876 18.5605 12.8662L12.5 16.3652L6.43945 19.8633C6.13009 20.0418 5.74878 20.0419 5.43945 19.8633C5.1305 19.6846 4.93956 19.355 4.93945 18.998V5.00195C4.93952 4.64485 5.13024 4.31437 5.43945 4.13574Z" fill="black" fill-opacity="0.9"/>
+</svg>

+ 4 - 0
src/assets/icon/workPage/status_icon.svg

@@ -0,0 +1,4 @@
+<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
+<circle cx="10" cy="10" r="10" fill="#E7E7E7"/>
+<circle cx="9.99993" cy="9.99944" r="5.71429" fill="#86909C"/>
+</svg>

+ 3 - 0
src/assets/icon/workPage/stop_icon.svg

@@ -0,0 +1,3 @@
+<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M12 1C18.0751 1 23 5.92487 23 12C23 18.0751 18.0751 23 12 23C5.92487 23 1 18.0751 1 12C1 5.92487 5.92487 1 12 1ZM12 3C7.02943 3 3 7.02943 3 12C3 16.9706 7.02943 21 12 21C16.9706 21 21 16.9706 21 12C21 7.02943 16.9706 3 12 3ZM14.5 8.5C15.0523 8.5 15.5 8.94772 15.5 9.5V14.5C15.5 15.0523 15.0523 15.5 14.5 15.5H9.5C8.94772 15.5 8.5 15.0523 8.5 14.5V9.5C8.5 8.94772 8.94772 8.5 9.5 8.5H14.5Z" fill="#F53F3F"/>
+</svg>

+ 8 - 3
src/common/Export2Excel.js

@@ -150,10 +150,8 @@ export function export_table_to_excel(id) {
 function formatJson(jsonData) {
   console.log(jsonData)
 }
-export function export_json_to_excel(th, jsonData, defaultTitle) {
-
+export function export_json_to_excel(th, jsonData, defaultTitle, colWidths) {
   /* original data */
-
   var data = jsonData;
   data.unshift(th);
   var ws_name = "SheetJS";
@@ -161,6 +159,13 @@ export function export_json_to_excel(th, jsonData, defaultTitle) {
   var wb = new Workbook(),
     ws = sheet_from_array_of_arrays(data);
 
+  // 设置列宽
+  if (colWidths && ws) {
+    ws['!cols'] = colWidths.map(function(width) {
+      // colWidths为每列对应的宽度数字,单位为字符数
+      return { wch: width };
+    });
+  }
 
   /* add worksheet to workbook */
   wb.SheetNames.push(ws_name);

+ 2 - 1
src/common/tools.js

@@ -41,4 +41,5 @@ export const tools = {
     71: { name: "AI智能体" },
     56: { name: "投票" },
     72: { name: "应用中心" },
-};
+    73: { name: "PPT" },
+};

+ 698 - 0
src/components/pages/PersonnelManagement/components/classL.vue

@@ -0,0 +1,698 @@
+<template>
+  <div>
+    <el-table
+      ref="table"
+      :key="1"
+      :data="tableData"
+      :fit="true"
+      v-loading="isLoading"
+      style="width: 100%; height: 60%"
+      :header-cell-style="{ background: '#f1f1f1' }"
+    >
+      <el-table-column prop="name" label="班级名称" align="center">
+      </el-table-column>
+      <el-table-column label="所属年级" align="center" v-if="!gidL">
+        <template slot-scope="{ row }">
+          {{ getGrade(row.pid) }}
+        </template>
+      </el-table-column>
+      <el-table-column prop="pnum" label="人数" align="center">
+      </el-table-column>
+      <el-table-column label="操作" width="280px">
+        <template slot-scope="scope">
+          <div class="classButtonBox" v-if="gidL">
+            <span @click="deleteClassStudent(scope.row.id)">移除</span>
+          </div>
+          <div class="classButtonBox" v-else>
+            <!-- getStudent() -->
+            <span @click="lookStudent(scope.row.id)">查看学生</span>
+            <span @click="updateG(scope.row.pid, scope.row.id)">修改年级</span>
+            <span @click="openUpdate(scope.row.id, scope.row.name)"
+              >修改名称</span
+            >
+            <span @click="deleteClass(scope.row.id)" style="color: red;">删除</span>
+          </div>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <div class="fontPage">
+      <el-pagination
+        background
+        layout="prev, pager, next"
+        :page-size="10"
+        :total="total"
+        :current-page="currentPage"
+        @current-change="handleCurrentChange"
+      ></el-pagination>
+    </div>
+    <!-- 添加班级  -->
+    <el-dialog
+      title="添加班级"
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <el-form>
+        <el-form-item label="班级名称">
+          <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="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="handleCurrentChange3(1)"
+              ></el-input>
+              <div class="search_img" @click="handleCurrentChange3(1)">
+                <img src="../../../../assets/icon/search.png" alt />
+              </div>
+            </div>
+          </div>
+          <div class="people_nav">选择班级</div>
+        </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.id"
+            :label="item.id"
+          >
+            <div class="t_j_box">
+              <span>{{ item.name }}</span>
+            </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="10"
+          :total="total3"
+          v-if="page3 && teacherJuri.length"
+          style="padding-bottom: 20px"
+          :current-page="SelectClasscurrentPage"
+          @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>
+
+    <!-- 修改年级 -->
+    <el-dialog
+      title="修改年级"
+      :visible.sync="dialogVisibleGrade"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <el-form>
+        <el-form-item label="选择年级">
+          <el-select
+            v-model="gid"
+            placeholder="请选择班级"
+            class="student_input"
+            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="500px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <el-form>
+        <el-form-item label="班级名称">
+          <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>
+  </div>
+</template>
+
+<script>
+import student from "./student.vue";
+export default {
+  props: ["userid", "oid", "org", "role", "searhValue", "gidL"],
+  components: {
+    student
+  },
+  data() {
+    return {
+      currentPage: 1,//table 分页数据
+      tableData: [],//班级table数据
+      isLoading: false,//班级tableLoading
+      total: 0,//班级table数据total
+
+
+      // 选择添加班级添加到年级 
+        dialogVisibleMember: false,
+        teacherJuri: [], //选择班级数据
+        searchTN: "", //搜索框
+        total3: 0,//选择班级数据总数
+        page3: 1, //页数
+        isLoading2:false,
+        SelectClasscurrentPage:1, //选择年级弹框分页
+        checkboxList3: [],// 选择班级弹框已选择数据 
+
+      // 修改年级
+        dialogVisibleGrade: false, //修改年级弹框
+        gid: "",// 修改年级选择的id
+        classid: "", //查看,修改班级学生,班级id
+        grade: [], //年级数据
+
+      // 添加班级弹框 
+        dialogVisible: false, //添加班级
+        className: "",//添加班级名称
+
+      // 修改班级名称 
+        dialogVisible1: false,//修改班级名称
+        className1: ""
+
+
+    };
+  },
+  computed: {
+    getGrade() {
+      // 展示所属年级
+      return function(gid) {
+        let name = "";
+        this.grade.forEach(element => {
+          if (element.id == gid) {
+            name = element.name;
+          }
+        });
+        return name ? name : "暂无";
+      };
+    }
+  },
+  mounted() {
+    this.selectGrage();
+  },
+  methods: {
+
+    //获取班级table数据 gidL包含两个接口
+    getClass() {
+      this.isLoading = true;
+
+      let params = {};
+      if (this.gidL) {
+        params = {
+          cid: this.gidL,
+          oid: this.oid,
+          cn: this.searhValue,
+          page: this.currentPage
+        };
+      } else {
+        params = {
+          cu: "",
+          oid: this.oid,
+          cn: this.searhValue,
+          page: this.currentPage
+        };
+      }
+
+      this.ajax
+        .get(
+          this.$store.state.api + (this.gidL ? "selectClass2" : "selectClass"),
+          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);
+        });
+    },
+    //获取班级列表
+    selectGrage() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectGrageBySchool", params)
+        .then(res => {
+          this.grade = res.data[0];
+        })
+        .catch(err => {
+          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"
+                });
+                this.getClass();
+              })
+              .catch(err => {
+                this.$message.error("删除失败");
+                console.error(err);
+              });
+          })
+          .catch(() => {});
+      }
+    },
+    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;
+        }
+      }
+    },
+    // table分页
+    handleCurrentChange(val) {
+      this.currentPage = val;
+      this.getClass();
+    },
+
+    // 年级视图函数调用
+      // 移除班级
+      deleteClassStudent(id) {
+        // uid班级id   cid年级id
+        let params = [{ uid: id, cid: this.gidL }];
+        this.$confirm("确定在本年级移除此班级吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+          .then(() => {
+            this.ajax
+              .post(this.$store.state.api + "deleteGradeClass", params)
+              .then(res => {
+                this.$message({
+                  message: "操作成功",
+                  type: "success"
+                });
+                this.getClass()
+              })
+              .catch(err => {
+                this.$message.error("操作失败");
+                console.error(err);
+              });
+          })
+          .catch(() => {});
+      },
+
+    // 选择添加班级弹框
+      // 打开选择添加班级
+      addStudent() {
+        this.dialogVisibleMember = true;
+        this.searchTN = "";
+        this.SelectClasscurrentPage = 1;
+        this.getClassStudent();
+      },
+      // 选择班级弹框数据
+      getClassStudent() {
+        this.isLoading2 = true;
+        let params = {
+          oid: this.oid,
+          cid: this.gidL,
+          cn: this.searchTN,
+          page: this.SelectClasscurrentPage,
+          num: 10
+        };
+        this.ajax
+          .get(this.$store.state.api + "getGradeClass", 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.gidL,
+            student: JSON.stringify(this.checkboxList3)
+          }
+        ];
+        this.ajax
+          .post(this.$store.state.api + "addGradeClass", params)
+          .then(res => {
+            this.checkboxList3 = [];
+            this.dialogVisibleMember = false;
+            this.getClass()
+          })
+          .catch(err => {
+            console.error(err);
+          });
+      },
+      // 选择班级弹框分页查询数据
+      handleCurrentChange3(val) {
+        this.SelectClasscurrentPage = val;
+        this.getClassStudent();
+      },
+
+    // 学生视图函数调用
+      // 查看班级学生
+      lookStudent(cid) {
+        this.$emit("lookstudentL", cid);
+      },
+
+    // 关闭弹框
+    handleClose(done) {
+      done();
+    },
+
+    //首页调用新增班级
+    insertClass() {
+      let params = {
+        name: this.className,
+        oid: this.oid,
+        uid: this.userid
+      };
+      this.ajax
+        .get(this.$store.state.api + "insertClass", 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.getClass();
+            this.className = "";
+            this.$emit('getClassdata')
+          }
+        })
+        .catch(err => {
+          this.$message({
+            message: "新增失败",
+            type: "error"
+          });
+          console.error(err);
+        });
+    },
+
+
+    // 修改年级弹框
+        // 打开修改年级弹框
+        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;
+        },
+        //确定修改班级名称弹框
+        updateClass() {
+          let params = {
+            id: this.classid,
+            n: this.className1,
+            oid: this.oid
+          };
+          this.ajax
+            .get(this.$store.state.api + "updateClass", 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);
+            });
+        },
+
+  }
+};
+</script>
+
+<style scoped>
+.fontPage {
+  height: 70px;
+  display: flex;
+  justify-content: end;
+  align-content: center;
+  box-sizing: border-box;
+  padding: 15px 0;
+}
+.classButtonBox {
+  display: flex;
+  gap: 15px;
+}
+
+.classButtonBox span {
+  color: #6b6b6b;
+  font-size: 14px;
+  cursor: pointer;
+}
+.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 {
+  display: flex;
+}
+
+.add_student >>> .el-form-item__content {
+  margin: 0 !important;
+}
+
+.add_student >>> .el-dialog__footer {
+  text-align: center !important;
+}
+.header-title {
+  display: flex;
+}
+
+
+.addNewPP >>> .el-dialog {
+  margin-top: 5vh !important;
+}
+
+.addNewPP >>> .el-dialog__body {
+  padding: 5px 20px; 
+}
+.people {
+  border: 1px solid rgb(229 229 229);
+  height: 450px;
+  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_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%;
+}
+</style>

+ 344 - 0
src/components/pages/PersonnelManagement/components/grade.vue

@@ -0,0 +1,344 @@
+<template>
+  <div>
+    <el-table
+      ref="table"
+      :key="1"
+      :data="tableData"
+      :fit="true"
+      v-loading="isLoading"
+      :header-cell-style="{ background: '#f1f1f1' }"
+    >
+      <el-table-column
+        prop="name"
+        label="年级名称"
+        min-width="40%"
+        align="center"
+      >
+      </el-table-column>
+      <el-table-column
+        prop="pnum"
+        label="班级数"
+        min-width="40%"
+        align="center"
+      >
+      </el-table-column>
+      <el-table-column label="操作" width="250px">
+        <template slot-scope="scope">
+          <div class="baseFlex">
+            <span @click="getStudent(scope.row.id)">查看班级</span>
+            <span @click="openUpdate(scope.row.id, scope.row.name)">修改</span>
+            <span @click="deleteGrade(scope.row.id)" style="color: red;">删除</span>
+          </div>
+        </template>
+      </el-table-column>
+    </el-table>
+    <div class="fontPage">
+      <el-pagination
+        background
+        layout="prev, pager, next"
+        :page-size="10"
+        :total="total"
+        :current-page="currentPage"
+        @current-change="handleCurrentChange"
+      ></el-pagination>
+    </div>
+
+    <el-dialog
+      title="添加年级"
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <el-form>
+        <el-form-item label="添加年级" >
+          <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="insertGrade">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="修改年级名称"
+      :visible.sync="dialogVisible1"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="add_student"
+    >
+      <el-form>
+        <el-form-item label="年级名称" >
+          <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="updateGrade">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+export default {
+  props: ["userid", "oid", "org", "role", "searhValue"],
+
+  data() {
+    return {
+      tableData: [],
+      isLoading: false,
+      total: 0,
+      currentPage: 1,
+
+      // 修改年级名称
+      dialogVisible1: false,
+      className1: "",
+
+      // 添加年级
+      dialogVisible: false,
+      className: ""
+    };
+  },
+  methods: {
+    //获取年级table列表
+    getClass() {
+      this.isLoading = true;
+      let params = {
+        // username: this.$store.state.userInfo.userid,
+        cu: "",
+        oid: this.oid,
+        cn: this.searhValue,
+        page: this.currentPage
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectGrade", 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);
+        });
+    },
+    handleClose(done) {
+      done();
+    },
+    //删除年级
+    deleteGrade(id) {
+      let params = {
+        id: id,
+      };
+      if (this.time()) {
+        this.$confirm("确定删除此年级吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+          .then(() => {
+            this.ajax
+              .get(this.$store.state.api + "deleteGrade", params)
+              .then((res) => {
+                this.$message({
+                  message: "删除成功",
+                  type: "success",
+                });
+                if (this.currentPage != 1 && this.tableData.length == 1) {
+                  this.currentPage - 1;
+                }
+                this.getClass();
+              })
+              .catch((err) => {
+                this.$message.error("删除失败");
+                console.error(err);
+              });
+          })
+          .catch(() => { });
+      }
+    },
+    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;
+        }
+      }
+    },
+    // 修改年级
+      openUpdate(id, n) {
+        this.classid = id;
+        this.className1 = n;
+        this.dialogVisible1 = true;
+      },
+      //修改年级
+      updateGrade() {
+        let params = {
+          id: this.classid,
+          n: this.className1,
+          oid: this.oid
+        };
+        this.ajax
+          .get(this.$store.state.api + "updateGrade", 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);
+          });
+      },
+
+    // 查看班级
+    getStudent(cid) {
+      this.$emit('lookgradeL',cid)
+    },
+
+
+    //首页调用新增年级
+    insertGrade() {
+      let params = {
+        name: this.className,
+        oid: this.oid,
+        uid: this.userid
+      };
+      this.ajax
+        .get(this.$store.state.api + "insertGrade", 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.getClass();
+            this.className = "";
+            this.$emit('getgradeData')
+          }
+        })
+        .catch(err => {
+          this.$message({
+            message: "新增失败",
+            type: "error"
+          });
+          console.error(err);
+        });
+    },
+
+    handleCurrentChange(val) {
+      this.page = val;
+      this.getClass();
+    }
+  }
+};
+</script>
+
+<style scoped>
+.fontPage {
+  height: 70px;
+  display: flex;
+  justify-content: end;
+  align-content: center;
+  box-sizing: border-box;
+  padding: 15px 0;
+}
+.baseFlex {
+  display: flex;
+  gap: 15px;
+}
+.baseFlex > span {
+  color: #6b6b6b;
+  font-size: 14px;
+  cursor: pointer;
+}
+.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;
+}
+.header-title {
+  display: flex;
+}
+
+.logoImg {
+  width: 30px;
+}
+
+.logoImg > img {
+  width: 100%;
+  height: 100%;
+}
+
+.title_add_student {
+  margin: 0 auto;
+  color: #fff;
+}
+</style>

+ 969 - 0
src/components/pages/PersonnelManagement/components/student.vue

@@ -0,0 +1,969 @@
+<template>
+  <div>
+    <div class="fontlist" v-loading="isLoading">
+      <div class="listA" v-for="i in tableData" :key="i.userid">
+        <div class="baseFlex">
+          <img :src="i.headportrait ? i.headportrait : tx" alt />
+          <div
+            style="display: flex;flex-direction: column;justify-content: space-between;color: #666666;height: 100%;"
+          >
+            <div style="font-size: 16px;color: #000;">{{ i.username }}</div>
+            <div>{{ i.acc }}</div>
+          </div>
+        </div>
+        <div class="baseFlex">
+          <el-tag size="mini" v-if="i.gname" style="background: #E9F6FE;color: #5498F7;">{{ i.gname }}</el-tag>
+          <el-tag size="mini" v-else type="danger" style="background: #FDF1F0;color: #E76337;">无年级</el-tag>
+
+          <el-tag size="mini" v-if="i.classname" type="success" style="background: #F8FFEE;color: #73C241;">{{
+            i.classname
+          }}</el-tag>
+          <el-tag size="mini" v-else type="danger" style="background: #FDF1F0;color: #E76337;">无班级</el-tag>
+
+         
+            <span @click="iniPassword(i.userid)">初始化密码</span>
+            <span @click="updateStudentA(i)">编辑</span>
+            <template v-if="cidL">
+                <span @click="deleteClassStudent(i.userid)">移出</span>
+            </template>
+            <span v-else @click="deleteStudent(i.userid, i.state)" style="color: red;">删除</span>
+
+          
+        </div>
+      </div>
+    </div>
+    <div class="fontPage">
+      <el-pagination
+        @size-change="handleSizeChange"
+        @current-change="handleCurrentChange"
+        :current-page="currentPage"
+        :page-sizes="[10, 20, 50, 100]"
+        :page-size="pageSize"
+        layout="total, sizes, prev, pager, next, jumper"
+        :total="total"
+      >
+      </el-pagination>
+    </div>
+    <!-- 添加学生  -->
+    <el-dialog
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="600px"
+      :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="100px">
+          <span>
+            <el-input
+              placeholder="请输入学生姓名"
+              clearable
+              v-model="sName"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="学生账号" label-width="100px">
+          <span>
+            <el-input
+              placeholder="请输入学生账号"
+              clearable
+              v-model="sMail"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="所属学校" label-width="100px">
+          <el-input
+            disabled
+            style="width: 300px"
+            v-model="schoolName"
+          ></el-input>
+        </el-form-item>
+        <el-form-item label="班级" label-width="100px">
+          <el-select
+            multiple
+            collapse-tags
+            v-model="sByClass"
+            placeholder="请选择班级"
+            filterable
+          >
+            <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">
+          注:添加学生的账号密码为Coco1234
+        </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="600px"
+      :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="100px">
+          <span>
+            <el-input
+              placeholder="请输入学生姓名"
+              clearable
+              v-model="userinfo.username"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="学生账号" label-width="100px">
+          <span>
+            <el-input
+              placeholder="请输入学生账号"
+              clearable
+              v-model="userinfo.acc"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="所属学校" label-width="100px">
+          <el-input
+            disabled
+            style="width: 300px"
+            v-model="schoolName"
+          ></el-input>
+        </el-form-item>
+        <el-form-item label="班级" label-width="100px">
+          <el-select
+            multiple
+            collapse-tags
+            v-model="userinfo.classid"
+            v-loading="optionLoading"
+            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">
+          注:添加学生的账号密码为Coco1234
+        </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="dialogVisibleMember"
+      :append-to-body="true"
+      width="600px"
+      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">
+                <span>{{ item.username }}</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="10"
+          :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 pinyin from "../../../../../node_modules/js-pinyin/index";
+
+export default {
+  props: ["userid", "oid", "org", "role", "searhValue","cid","cidL"],
+  data() {
+    return {
+      // 学生视图
+        tableData: [], //学生视图数据
+        tx: require("../../../../assets/avatar.png"),
+        isLoading: false,
+        total: 0,
+        currentPage: 1,
+        pageSize: 10,
+
+      // 班级添加学生弹框
+        dialogVisibleMember:false,
+        isLoading2:false,
+        teacherJuri:[], //数据
+        total3: 0, //学生总数
+        checkboxList3:[], //勾选中的学生
+        page3: 1, //页数
+        searchTN:'', //搜索框
+
+      // 修改学生弹框
+        dialogVisibleUpdate: false,
+        userinfo: {},
+        userinfoA: {},
+        classJuri: [], //班级列表
+        optionLoading: false, //班级列表loading
+
+      // 添加学生弹框
+        dialogVisible: false,
+        sName: "", 
+        sByClass: "", //班级
+        sMail: "", //学生账号
+        sPhone: "",
+        userSuffix: "", //后缀
+        sId: "",
+
+      schoolName: "",//学校名称
+      schoolChar: "",
+
+
+    };
+  },
+  methods: {
+
+
+    // 获取table获取学生
+    getStudent() {
+      this.isLoading = true;
+      let params = {
+        oid: this.oid,
+        cid: this.cid,
+        inp: this.searhValue,
+        page: this.currentPage,
+        num: this.pageSize
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectStudentManage", 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);
+        });
+    },
+    // 获取创建学生用户后缀
+    getUser() {
+      let params = {
+        userid: this.userid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectUser", params)
+        .then(res => {
+          this.userSuffix = res.data[0][0].accountNumber.split("@")[1];
+        })
+        .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;
+          const cleanedSchoolName = res.data[0][0].name.replace(
+            /[,。;:!“”‘’()()]/g,
+            ""
+          ); // 去掉标点符号
+          // console.log(pinyin);
+          // console.log(pinyin.getFullChars(cleanedSchoolName));
+          // console.log(pinyin.getCamelChars(cleanedSchoolName));
+          this.schoolChar = pinyin
+            .getCamelChars(cleanedSchoolName)
+            .toLowerCase();
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    //获取班级列表
+    getClass() {
+      this.optionLoading = true;
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectClassBySchool", params)
+        .then(res => {
+          this.optionLoading = false;
+          this.classJuri = res.data[0];
+        })
+        .catch(err => {
+          this.optionLoading = false;
+          console.error(err);
+        });
+    },
+    // 初始化密码
+    iniPassword(id) {
+      this.$confirm("确定" + "初始化" + "此学生的密码吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
+        .then(() => {
+          let params = [
+            {
+              uid: id,
+              pa: "Coco1234"
+            }
+          ];
+          this.ajax
+            .post(this.$store.state.api + "iniPassword", params)
+            .then(res => {
+              this.$message({
+                message: "初始化密码成功!",
+                type: "success"
+              });
+            })
+            .catch(err => {
+              console.error(err);
+            });
+        })
+        .catch(() => {});
+    },
+    // 删除学生
+    deleteStudent(id, state) {
+      state = 0;
+      let params = [{ uid: id, state: state }];
+      this.$confirm("确定删除此学生吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
+        .then(() => {
+          this.ajax
+            .post(this.$store.state.api + "deleteStudent", params)
+            .then(res => {
+              this.$message({
+                message: "操作成功",
+                type: "success"
+              });
+              this.getStudent();
+            })
+            .catch(err => {
+              this.$message.error("操作失败");
+              console.error(err);
+            });
+        })
+        .catch(() => {});
+    },
+    // 修改每页获取个数
+    handleSizeChange(val) {
+      this.pageSize = val;
+      this.currentPage = 1;
+      this.getStudent();
+      console.log(`每页 ${val} 条`);
+    },
+    // 跳转页数
+    handleCurrentChange(val) {
+      this.currentPage = val;
+      this.getStudent();
+      console.log(`当前页: ${val}`);
+    },
+    // 关闭弹框
+    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;
+        }
+      }
+    },
+
+    // 班级添加学生弹框
+        // 首页调用打开班级添加学生弹框
+        diaAdd(){
+          this.dialogVisibleMember = true;
+          this.searchTN = "";
+          this.getClassStudent();
+        },
+        // 添加学生弹框获取数据
+        getClassStudent() {
+          this.isLoading2 = true;
+          let params = {
+            oid: this.oid,
+            cid: this.cid,
+            cn: this.searchTN,
+            page: this.page3,
+            num: 10
+          };
+          this.ajax
+            .get(this.$store.state.api + "getClassStudent", 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 + "addClassStudent", params)
+            .then(res => {
+              this.checkboxList3 = [];
+              this.dialogVisibleMember = false;
+              this.getStudent();
+            })
+            .catch(err => {
+              console.error(err);
+            });
+        },
+      
+       
+    //添加学生弹框
+        addStudent() {
+          this.dialogVisible = true;
+          this.sName = "";
+          this.sPhone = "";
+          this.sByClass = "" ;
+          this.sMail='';
+          // this.getClass();
+        },
+        //确认添加学生新增学生前判断是否被注册以及格式问题
+        insertStudent() {
+          this.dialogVisible = true;
+          if (this.sName === "") {
+            this.$message.error("学生姓名不能为空");
+            return;
+          } else if (this.sByClass === "") {
+            this.$message.error("请为学生选择班级");
+            return;
+          } else if (
+            this.sPhone != "" &&
+            !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.sPhone)
+          ) {
+            this.$message.error("手机号格式不正确");
+            return;
+          } else if (this.sMail === "") {
+            this.$message.error("学生账号不能为空");
+            return;
+          }
+
+          let mail = "";
+          if (
+            /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
+          ) {
+            mail = this.sMail;
+          } else {
+            if (
+              this.org != "" &&
+              this.org != "null" &&
+              this.org != undefined &&
+              this.org &&
+              this.schoolChar
+            ) {
+              mail = this.sMail + "@" + this.schoolChar + "." + this.userSuffix;
+            } else {
+              mail = this.sMail + "@" + this.userSuffix;
+            }
+          }
+          if (this.time()) {
+            let params = { un: mail };
+            this.ajax
+              .get(this.$store.state.api + "findMail", params)
+              .then(res => {
+                if (res.data[0].length > 0) {
+                  this.$message.error("此学生账号已被注册");
+                } else {
+                  this.comfirmAddStudent();
+                }
+              })
+              .catch(err => {
+                console.error(err);
+              });
+          }
+        },
+        // 最终添加学生函数
+        comfirmAddStudent() {
+          let mail = "";
+          if (
+            /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
+          ) {
+            mail = this.sMail;
+          } else {
+            if (
+              this.org != "" &&
+              this.org != "null" &&
+              this.org != undefined &&
+              this.org &&
+              this.schoolChar
+            ) {
+              mail = this.sMail + "@" + this.schoolChar + "." + this.userSuffix;
+            } else {
+              mail = this.sMail + "@" + this.userSuffix;
+            }
+          }
+          let params = [
+            {
+              username: mail,
+              userpassword: "Coco1234",
+              alias: this.sName,
+              oid: this.oid,
+              ph: this.sPhone,
+              sid: this.sId,
+              cid: this.sByClass.join(","),
+              org: this.org
+            }
+          ];
+          console.log("params", params);
+
+          this.ajax
+            .post(this.$store.state.api + "batchRegistrationOrg", params)
+            .then(res => {
+              this.$message({
+                message: "新增成功",
+                type: "success"
+              });
+
+              this.dialogVisible = false;
+              this.sPhone = "";
+              this.sName = "";
+              // this.sBySchool = [];
+              this.sByClass = [];
+              this.sMail = "";
+              this.getStudent();
+              this.addOp3("1", "", { type: "student_user_add" }, "success");
+            })
+            .catch(err => {
+              this.isLoading = false;
+              this.addOp3("1", "", { type: "student_user_add" }, err);
+
+              this.$message({
+                message: "新增失败",
+                type: "error"
+              });
+              console.error(err);
+            });
+        },
+        // 控制添加学生分页
+        handleCurrentChange3(val) {
+          this.page3 = val;
+          this.getClassStudent();
+        },
+
+
+    // 修改,编辑学生弹框(班级视图的与学生视图的学生编辑修改共用一个修改函数)
+        // 打开编辑学生弹框
+        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.username === "") {
+            this.$message.error("学生姓名不能为空");
+            return;
+          } else if (!this.userinfo.classid) {
+            this.$message.error("请为学生选择班级");
+            return;
+          } else if (
+            !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(
+              this.userinfo.acc
+            )
+          ) {
+            this.$message.error("邮箱格式不正确");
+            return;
+          }
+
+          if (this.time()) {
+            if (this.userinfoA.acc != this.userinfo.acc) {
+              let params = { un: this.userinfo.acc };
+              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.acc,
+              alias: this.userinfo.username,
+              ph: this.userinfo.phonenumber,
+              sid: this.userinfo.studentid,
+              cid: this.userinfo.classid.join(",")
+            }
+          ];
+          console.log("params", params);
+
+          this.ajax
+            .post(this.$store.state.api + "updateStudentInfo", params)
+            .then(res => {
+              this.$message({
+                message: "修改成功",
+                type: "success"
+              });
+              this.dialogVisibleUpdate = false;
+              this.getStudent();
+            })
+            .catch(err => {
+              this.isLoading = false;
+              this.$message({
+                message: "修改失败",
+                type: "error"
+              });
+              console.error(err);
+            });
+        },
+
+    // 班级视图调用学生视图方法 
+        // 将学生移除班级
+        deleteClassStudent(id) {
+          let params = [{ uid: id, cid: this.cidL }];
+          this.$confirm("确定移除此学生在本班级吗?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning",
+          })
+            .then(() => {
+              this.ajax
+                .post(this.$store.state.api + "deleteClassStudent", params)
+                .then((res) => {
+                  this.$message({
+                    message: "操作成功",
+                    type: "success",
+                  });
+                  this.getStudent();
+                })
+                .catch((err) => {
+                  this.$message.error("操作失败");
+                  console.error(err);
+                });
+            })
+            .catch(() => { });
+        },
+
+
+  },
+  mounted() {
+    this.getUser();
+    this.getSchoolName();
+    this.getClass();
+    // this.getStudent();
+  }
+};
+</script>
+
+<style scoped>
+
+.baseFlex {
+  display: flex;
+  align-items: center;
+  gap: 15px;
+  height: 100%;
+}
+.baseFlex > img {
+  /* width: 50px; */
+  height: 100%;
+  object-fit: cover;
+}
+.baseFlex > span {
+  color: #6b6b6b;
+  font-size: 14px;
+  cursor: pointer;
+}
+.fontlist {
+  border-radius: 10px;
+  overflow: auto;
+  background: #fff;
+  flex: 1;
+  min-height: 250px;
+}
+.listA {
+  display: flex;
+  justify-content: space-between;
+  border-bottom: 1px #e7e7e7 solid;
+  height: 70px;
+  align-items: center;
+  box-sizing: border-box;
+  padding: 15px;
+  /* background: #fff; */
+}
+.fontPage {
+  height: 70px;
+  display: flex;
+  justify-content: end;
+  align-content: center;
+  box-sizing: border-box;
+  padding: 15px 0;
+}
+.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;
+}
+.header-title {
+  display: flex;
+}
+
+.logoImg {
+  width: 30px;
+}
+
+.logoImg > img {
+  width: 100%;
+  height: 100%;
+}
+
+.title_add_student {
+  margin: 0 auto;
+  color: #fff;
+}
+.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_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>

+ 383 - 0
src/components/pages/PersonnelManagement/index.vue

@@ -0,0 +1,383 @@
+<template>
+  <div class="manageper" style="background-color: #FAFAFA;min-height: 100%;">
+    <div class="topTit">
+      <div style="font-size: 22px;font-weight: bold;">
+        <span>学生管理</span>
+        <!-- <span v-if="isCollapse == 0">学生管理</span>
+        <span v-if="isCollapse == 1">班级管理</span>
+        <span v-if="isCollapse == 2">年级管理</span> -->
+      </div>
+      <div></div>
+    </div>
+    <div class="manageper" style="padding: 0 12%;flex: 1;overflow: auto;">
+      <div class="midcon">
+        <el-button size="small" @click="addviewData(0)" type="primary"
+          >添加学生</el-button
+        >
+        <el-button size="small" @click="addviewData(1)" type="primary"
+          >添加班级</el-button
+        >
+        <el-button size="small" @click="addviewData(2)" type="primary"
+          >添加年级</el-button
+        >
+      </div>
+      <div class="viewCut" style="justify-content: space-between;">
+        <div class="viewCut">
+          <el-radio-group @change="cutList()" v-model="isCollapse">
+            <el-radio-button :label="0">学生视图</el-radio-button>
+            <el-radio-button :label="1">班级视图</el-radio-button>
+            <el-radio-button :label="2">年级视图</el-radio-button>
+          </el-radio-group>
+          <el-input
+            @blur="getinpData()"
+            style="width: 200px;"
+            placeholder="搜索学生、班级或年级…"
+            v-model.trim="searhValue"
+          >
+          </el-input>
+          <div style="width: 120px;">
+            <el-select
+              v-if="isCollapse == 0"
+              style="width: 120px;"
+              v-model="cid"
+              clearable
+              :disabled="classLcid ? true : false"
+              @change="changeCid"
+              placeholder="请选择"
+            >
+              <el-option label="显示全部" value=""> </el-option>
+              <el-option
+                v-for="item in classJuri"
+                :key="item.id"
+                :label="item.name"
+                :value="item.id"
+              >
+              </el-option>
+            </el-select>
+          </div>
+        </div>
+        <div class="viewCut" v-if="classLcid">
+          <span
+            >班级:{{ classJuri.filter(e => e.id == classLcid)[0].name }}</span
+          >
+          <el-button size="small" @click="addclassStu" type="primary"
+            >添加学生</el-button
+          >
+          <el-button
+            size="small"
+            type="primary"
+            @click="(classLcid = ''), getData()"
+            >返回</el-button
+          >
+        </div>
+
+        <div class="viewCut" v-if="gidL">
+          <span>年级:{{ gradeJuri.filter(e => e.id == gidL)[0].name }}</span>
+          <el-button size="small" @click="addgid" type="primary"
+            >添加年级</el-button
+          >
+          <el-button size="small" type="primary" @click="(gidL = ''), getData()"
+            >返回</el-button
+          >
+        </div>
+      </div>
+
+      <student
+        ref="studentref"
+        v-if="isCollapse == 0 || classLcid"
+        :userid="userid"
+        :oid="oid"
+        :org="org"
+        :role="role"
+        :cid="cid"
+        :cidL="classLcid"
+        :searhValue="searhValue"
+      />
+
+      <classL
+        ref="classLref"
+        v-else-if="isCollapse == 1 || gidL"
+        :userid="userid"
+        :oid="oid"
+        :org="org"
+        :role="role"
+        :gidL="gidL"
+        :searhValue="searhValue"
+        @lookstudentL="lookstudentL"
+        @getClassdata="getClassdata"
+      />
+
+      <grade
+        ref="graderef"
+        v-else
+        :userid="userid"
+        :oid="oid"
+        :org="org"
+        :role="role"
+        :searhValue="searhValue"
+        @lookgradeL="lookgradeL"
+        @getgradeData="getgradeData"
+      />
+    </div>
+  </div>
+</template>
+
+<script>
+import pinyin from "../../../../node_modules/js-pinyin/index";
+import student from "./components/student.vue";
+import classL from "./components/classL";
+import grade from "./components/grade.vue";
+import Class from "../studentManage/class.vue";
+
+export default {
+  components: {
+    student,
+    classL,
+    grade,
+    Class
+  },
+  data() {
+    return {
+      searhValue: "", //搜索框
+      isCollapse: 0, //展示视图
+      cid: "", //班级id
+      classLcid: "", //班级id防止与使用cid时冲突
+      gidL: "", //年级视图点击查看班级存储的数据
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      role: this.$route.query.role,
+      classJuri: [], //班级列表
+      gradeJuri: "", //年级列表
+      tableData: [] //学生视图数据
+    };
+  },
+  methods: {
+    // 学生视图函数调用
+      // 筛选年级学生
+      changeCid() {
+        // console.log("cid", this.cid);
+        this.$nextTick(() => {
+          this.$refs.studentref.getStudent();
+        });
+      },
+      // 添加学生到班级
+      addclassStu() {
+        this.$refs.studentref.diaAdd();
+      },
+
+    // 班级视图函数调用
+      // 年级添加班级
+      addgid() {
+        this.$refs.classLref.addStudent();
+      },
+      // 查看班级学生
+      lookstudentL(val) {
+        this.classLcid = val;
+        this.cid = val;
+        // this.$nextTick(() => {
+        this.getData();
+        // });
+      },
+
+    //年级视图函数调用
+      // 查看年级班级
+      lookgradeL(val) {
+        this.gidL = val;
+        console.log('this.gidL',this.gidL);
+        
+        this.$nextTick(() => {
+          this.$refs.classLref.getClass();
+        });
+      },
+
+    //获取年级列表
+    getgradeData() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectGrageBySchool", params)
+        .then(res => {
+          this.gradeJuri = res.data[0];
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+
+    //获取班级列表
+    getClassdata() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectClassBySchool", params)
+        .then(res => {
+          this.classJuri = res.data[0];
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+
+    // 添加学生,班级,年级弹框
+    addviewData(val) {
+      this.isCollapse = val;
+      this.gidL = "";
+      this.classLcid = "";
+
+      if (this.isCollapse == 0) {
+        this.$nextTick(() => {
+          this.$refs.studentref.getStudent();
+
+          this.$refs.studentref.addStudent();
+        });
+      } else if (this.isCollapse == 1) {
+        this.$nextTick(() => {
+          this.$refs.classLref.dialogVisible = true;
+          this.$refs.classLref.getClass();
+        });
+      } else {
+        this.$nextTick(() => {
+          this.$refs.graderef.getClass();
+          this.$refs.graderef.dialogVisible = true;
+        });
+      }
+    },
+
+    // 搜索框查询数据
+    getinpData() {
+      // if (!this.searhValue) return;
+      if (this.isCollapse == 0 || this.classLcid) {
+        this.$nextTick(() => {
+          this.$refs.studentref.getStudent();
+        });
+      } else if (this.isCollapse == 1 || this.gidL) {
+        this.$nextTick(() => {
+          this.$refs.classLref.getClass();
+        });
+      } else {
+        this.$nextTick(() => {
+          this.$refs.graderef.getClass();
+        });
+      }
+    },
+    
+    // 搜索框与监听调用获取视图数据
+    getData() {
+      if (this.isCollapse == 0 || this.classLcid) {
+        this.$nextTick(() => {
+          this.$refs.studentref.getStudent();
+        });
+      } else if (this.isCollapse == 1) {
+        this.$nextTick(() => {
+          this.$refs.classLref.getClass();
+        });
+      } else {
+        this.$nextTick(() => {
+          this.$refs.graderef.getClass();
+        });
+      }
+    },
+    // 切换列表
+    cutList() {
+      this.searhValue = "";
+      this.classLcid = "";
+      this.gidL = "";
+      this.cid = "";
+      if (this.isCollapse == 0) {
+        this.$nextTick(() => {
+          this.$refs.studentref.getStudent();
+        });
+      } else if (this.isCollapse == 1) {
+        this.$nextTick(() => {
+          this.$refs.classLref.getClass();
+        });
+      } else {
+        this.$nextTick(() => {
+          this.$refs.graderef.getClass();
+        });
+      }
+    }
+  },
+  mounted() {
+    this.getData();
+    this.getClassdata();
+    this.getgradeData();
+  }
+};
+</script>
+
+<style scoped>
+.manageper {
+  display: flex;
+  flex-direction: column;
+  gap: 20px;
+  box-sizing: border-box;
+}
+.topTit {
+  display: flex;
+  width: 100%;
+  background: #fff;
+  justify-content: space-between;
+  box-sizing: border-box;
+  padding: 0 10%;
+  align-items: center;
+  height: 85px;
+}
+.midcon {
+  height: 85px;
+  display: flex;
+  align-items: center;
+  background: #fff;
+  border-radius: 10px;
+  padding: 0 20px;
+  border: 1px#e7e7e7 solid;
+}
+.viewCut {
+  height: 70px;
+  display: flex;
+  gap: 15px;
+  align-items: center;
+  border-bottom: 1px #e7e7e7 solid;
+}
+.baseFlex {
+  display: flex;
+  align-items: center;
+  gap: 10px;
+  height: 100%;
+}
+.baseFlex > img {
+  /* width: 50px; */
+  height: 100%;
+  object-fit: cover;
+}
+.baseFlex > span {
+  color: #6b6b6b;
+  font-size: 14px;
+  cursor: pointer;
+}
+.fontlist {
+  border-radius: 10px;
+  overflow: auto;
+  background: #fff;
+  flex: 1;
+  min-height: 250px;
+}
+.listA {
+  display: flex;
+  justify-content: space-between;
+  border-bottom: 1px #e7e7e7 solid;
+  height: 70px;
+  align-items: center;
+  box-sizing: border-box;
+  padding: 15px;
+  /* background: #fff; */
+}
+.fontPage {
+  height: 70px;
+  display: flex;
+  justify-content: end;
+}
+</style>

+ 257 - 9
src/components/pages/aiAddCourse/addCourse.vue

@@ -7,7 +7,7 @@
       @click="cancelAjax('teacherTask')">停止</div>
     <div class="pb_content_body" style="position: relative; margin: 0;overflow: hidden;">
       <div class="courseTop" :style="{width: !gotype ? '100%' :'100px'}">
-        <!-- <div class="stepsNav">
+        <div class="stepsNav" v-if="!gotype">
             <el-breadcrumb separator-class="el-icon-arrow-right">
               <el-breadcrumb-item :to="{
                 path:
@@ -24,7 +24,7 @@
                 <span style="color: rgb(15, 126, 255)">添加课程</span>
               </el-breadcrumb-item>
             </el-breadcrumb>
-          </div> -->
+          </div>
         <div class="r_pub_button_retrun" style="margin-left: auto" @click="retrunCourse">返回</div>
       </div>
       <div class="right" style="height: calc(100% - 36px); margin-top: 36px;"
@@ -3455,6 +3455,11 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                   </div>
                                   <div class="chapter_upload_n">
                                     <input
@@ -3522,6 +3527,22 @@
                                         overflow: hidden;
                                         text-overflow: ellipsis;
                                       " readonly="true" @click="selectLine(itemTaskIndex, index1)" />
+                                     <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  />
                                     <input :placeholder="
                                         item1.title ? item1.title : '链接'
                                       " v-if="item1.type == 14" style="
@@ -3614,6 +3635,13 @@
                                       @click="selectLine(itemTaskIndex, index1)">
                                       <div></div>
                                     </div>
+                                    <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                     <div class="chapter_upload_ic_edit" v-if="item1.type == 14" @click="
                                         openUpdateSource(itemTaskIndex, index1)
                                       ">
@@ -3689,6 +3717,13 @@
                           >
                             代码编辑器
                           </button>
+
+                          <button
+                            class="c_pub_button_add pub_btn_add_img"
+                                @click="uploadZIPFile(itemTaskIndex)"
+                          >
+                            代码上传
+                          </button>
                           </div>
                           <div v-if="
                               unitJson[unitIndex].chapterInfo[0].taskJson[
@@ -3808,6 +3843,11 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                   </div>
                                   <div class="chapter_upload_n">
                                     <span style="
@@ -3862,6 +3902,22 @@
                                         text-overflow: ellipsis;
                                       " readonly="true" @click="selectLine(itemTaskIndex, index1)" />
                                       <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  />
+                                      <input
                                     :placeholder="
                                       item1.title ? item1.title : 'Ai应用'
                                     "
@@ -7634,7 +7690,7 @@
     <wOffice :dialogVisibleOffice.sync="dialogVisibleOffice" :url="wurl"></wOffice>
     <appDialog ref="appDialog" @success="selectAppSuccess"></appDialog>
     <CodeEditor ref="CodeEditorRef" @success="addHtmlSuccess"></CodeEditor>
-
+    <selectHtmlPageDialog ref="selectHtmlPageDialogRef" @success="selectHtmlPageSuccess"/>
   </div>
 </template>
 
@@ -7678,6 +7734,7 @@ let convertApi = ConvertApi.auth('secret_U1EO5rhgMCnoBnBT')
 import appDialog from '../components/appDialog.vue'
 import { myMixin } from "@/mixins/mixin.js"
 import CodeEditor from "../components/CodeEditor";
+import { uploadFileMixin } from "../../tools/uploadFileMixin.js";
 
 var OpenCC = require("opencc-js");
 let converter = OpenCC.Converter({
@@ -7689,6 +7746,7 @@ let converter2 = OpenCC.Converter({
 		from:'cn',
 		to:'hk'
 })
+import selectHtmlPageDialog from '../dialog/selectHtmlPageDialog.vue'
 
 const getFile = (url) => {
   return new Promise((resolve, reject) => {
@@ -7729,7 +7787,7 @@ const getFile = (url) => {
 };
 
 export default {
-  mixins: [ myMixin ],
+  mixins: [ myMixin,uploadFileMixin ],
   components: {
     CodeEditor,
     EditorBar,
@@ -7756,11 +7814,12 @@ export default {
     evaList,
     MindTask,
     recordV,
-    appDialog
+    appDialog,
+    selectHtmlPageDialog
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       checkAll: false,
       checkAll2: false,
       chooseType: 1,
@@ -8268,8 +8327,8 @@ export default {
       knowFileType: "",
       knowFileTypeArray1: ['上册', '下册'],
       knowFileTypeArray: ['作业', '教案', '其他'],
-      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
-
+      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'],
+      changeId:"",
     };
   },
   directives: {
@@ -26216,7 +26275,196 @@ ${msg}
       }
       this.imgChange1(null, null, 8, this.lineCount);
       this.dialogVisible7 = false;
-    }
+    },
+    // zip压缩文件上传
+    uploadZIPFile(i){
+      this.lineCount = i;
+      // 只支持上传zip文件
+      let input = document.createElement('input');
+      input.type = 'file';
+      input.accept = '.zip';
+      input.style.display = 'none';
+      // 只允许上传一个文件
+      input.multiple = false;
+      input.onchange = async (e) => {
+        let file = e.target.files[0];
+        if (!file) return;
+        if (file.type !== 'application/zip' && !file.name.endsWith('.zip')) {
+          this.$message.error('只支持上传zip文件');
+          return;
+        }
+        try{
+          const zip = new JSZip();
+          const content = await zip.loadAsync(file);
+          let _fileStructure = this.buildFileStructure(file,content);
+          let _time = new Date().getTime();
+          let _resultList = await this.uploadZipFileFn(_fileStructure.files,`${_time}_${_fileStructure.folderName}`);
+          this.changeId = "";
+          this.$refs.selectHtmlPageDialogRef.open(_resultList);
+        
+        }catch(e){
+          console.log(e)
+          this.$message.error("解析zip文件失败")
+        }
+      
+      };
+      document.body.appendChild(input);
+      input.click();
+      setTimeout(() => {
+        document.body.removeChild(input);
+      }, 1000);
+      },
+      // 构建文件结构树
+      buildFileStructure(file,zip) {
+      const root = {
+        folderName: file.name.replace(/\.[^/.]+$/, ""), // 移除扩展名
+        files: []
+      };
+      
+      // 遍历ZIP文件中的所有文件/文件夹
+      zip.forEach((relativePath, file) => {
+        if (file.dir) return; // 跳过目录
+      
+        const parts = relativePath.split('/');
+        let currentLevel = root.files;
+      
+        for (let i = 0; i < parts.length; i++) {
+          const part = parts[i];
+          const isLast = i === parts.length - 1;
+        
+          if (isLast) {
+            // 添加文件
+            currentLevel.push({fileName:part,file:file});
+          } else {
+            // 查找或创建文件夹
+            let folder = currentLevel.find(item =>
+              typeof item === 'object' && item.folderName === part
+            );
+          
+            if (!folder) {
+              folder = {
+                folderName: part,
+                files: []
+              };
+              currentLevel.push(folder);
+            }
+          
+            currentLevel = folder.files;
+          }
+        }
+      });
+      
+      return root;
+      },
+      //按路径上传文件
+      async uploadZipFileFn(fileList,path){
+      return new Promise(async (resolve)=>{
+        let _copyFileList = fileList;
+      
+        let promise = [];
+        for(let i = 0; i < _copyFileList.length; i++){
+          if(_copyFileList[i].folderName){
+            let _path = `${path}/${_copyFileList[i].folderName}`;
+            promise.push(this.uploadZipFileFn(_copyFileList[i].files,_path).then(res=>{
+              _copyFileList[i].files = res;
+            }))
+          }else if(_copyFileList[i].fileName){
+            // 将 ZIP 条目转换为文件对象
+            const blob = await _copyFileList[i].file.async('blob');
+            // 根据文件名设置type
+            let type = 'text/html';
+            if (_copyFileList[i].fileName.endsWith('.js')) {
+              type = 'application/javascript';
+            } else if (_copyFileList[i].fileName.endsWith('.css')) {
+              type = 'text/css';
+            } else if (_copyFileList[i].fileName.endsWith('.json')) {
+              type = 'application/json';
+            } else if (_copyFileList[i].fileName.endsWith('.png')) {
+              type = 'image/png';
+            } else if (_copyFileList[i].fileName.endsWith('.jpg') || _copyFileList[i].fileName.endsWith('.jpeg')) {
+              type = 'image/jpeg';
+            } else if (_copyFileList[i].fileName.endsWith('.gif')) {
+              type = 'image/gif';
+            } else if (_copyFileList[i].fileName.endsWith('.svg')) {
+              type = 'image/svg+xml';
+            } else if (_copyFileList[i].fileName.endsWith('.html') || _copyFileList[i].fileName.endsWith('.htm')) {
+              type = 'text/html';
+            } else if (_copyFileList[i].fileName.endsWith('.txt')) {
+              type = 'text/plain';
+            } else if (_copyFileList[i].fileName.endsWith('.pdf')) {
+              type = 'application/pdf';
+            } else if (_copyFileList[i].fileName.endsWith('.mp3')) {
+              type = 'audio/mpeg';
+            } else if (_copyFileList[i].fileName.endsWith('.mp4')) {
+              type = 'video/mp4';
+            } else if (_copyFileList[i].fileName.endsWith('.zip')) {
+              type = 'application/zip';
+            } else if (_copyFileList[i].fileName.endsWith('.xml')) {
+              type = 'application/xml';
+            } else if (_copyFileList[i].fileName.endsWith('.csv')) {
+              type = 'text/csv';
+            } else if (_copyFileList[i].fileName.endsWith('.md')) {
+              type = 'text/markdown';
+            }
+            let _file = new File([blob], _copyFileList[i].fileName, {type: type, lastModified: new Date().getTime()});
+            promise.push(this.awsupload({file:_file,path:`${path}/${_copyFileList[i].fileName}`}).then(res=>{
+              delete _copyFileList[i].file;
+              _copyFileList[i].url = decodeURIComponent(res.Location);
+            }))
+          }
+        }
+        Promise.all(promise).then(res=>{
+          resolve(_copyFileList);
+        })
+      })
+      },
+      selectHtmlPageSuccess(data){
+      let _selectFile = data.find(i=>i.isSelect==="1");
+      if(!_selectFile){
+        this.changeId = "";
+        return this.$message.info("未选择主页面")
+      }
+      
+      console.log("_selectFile",_selectFile)
+      let _index = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      this.lineCount
+      ].chapterData.findIndex(i => i.type == 17 && i.id == this.changeId);
+      if (_index != -1) {
+        console.log("_index",_index)
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.lineCount
+        ].chapterData[_index] = {
+          name: _selectFile.fileName,
+          title: _selectFile.fileName,
+          id:this.changeId,
+          url: _selectFile.url,
+          fileList:data,
+          type: 17
+        };
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.lineCount
+        ].chapterData.push({
+          name: _selectFile.fileName,
+          title: _selectFile.fileName,
+          id:new Date().getTime(),
+          url: _selectFile.url,
+          fileList:data,
+          type: 17
+        });
+      }
+      this.changeId = "";
+      this.$forceUpdate();
+      this.$refs.selectHtmlPageDialogRef.close();
+      },
+      changeHTmlPage(itemTaskIndex,i){
+        let _data = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].chapterData[i];
+        this.lineCount = itemTaskIndex;
+        this.changeId = _data.id;
+        this.$refs.selectHtmlPageDialogRef.open(_data.fileList);
+      }
   },
   beforeDestroy() {
     // clearTimeout(this.timer);

+ 275 - 7
src/components/pages/aiEasy/addCourse.vue

@@ -4,7 +4,7 @@
     <div class="c_pub_button_confirm stopBtn" v-if="loading && isTeacherTaskCancelToken" @click="cancelAjax('teacherTask')">停止</div>
     <div class="pb_content_body" style="position: relative; margin: 0;overflow: hidden;">
       <div class="courseTop" :style="{width: !gotype ? '100%' :'100px'}">
-          <!-- <div class="stepsNav">
+          <div class="stepsNav" v-if="!gotype">
             <el-breadcrumb separator-class="el-icon-arrow-right">
               <el-breadcrumb-item :to="{
                 path:
@@ -21,7 +21,7 @@
                 <span style="color: rgb(15, 126, 255)">添加课程</span>
               </el-breadcrumb-item>
             </el-breadcrumb>
-          </div> -->
+          </div>
           <div class="r_pub_button_retrun" style="margin-left: auto" @click="retrunCourse">返回</div>
         </div>
       <div class="right" style="height: calc(100% - 36px); margin-top: 36px;" :style="{width:istemplate == 1 ? 'calc(100% - 300px)' : '100%'}">
@@ -471,6 +471,11 @@
 
                                 <div v-if="item1.type == 15" class="chapter_upload_l_i15" style="margin-left: 1px">
                                 </div>
+                                <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                               </div>
                               <div class="chapter_upload_n" :class="{dataTips: !item1.fileid}">
 
@@ -498,6 +503,9 @@
                                 <div v-if="item1.type == 14" class="chapter_upload_box" @click="
                                         openUpdateSource(0, index1)
                                         " >{{ item1.title ? item1.title : '链接' }}</div>
+                                <div v-if="item1.type == 17" class="chapter_upload_box" @click="
+                                        changeHTmlPage(0, index1)
+                                        " >{{ item1.title ? item1.title : '代码上传' }}</div>
                                    <div v-if="item1.type == 15" class="chapter_upload_box" @click="
                                         openUpdateSource(0, index1)
                                         " >{{ item1.title ? item1.title : 'Ai应用' }}</div>
@@ -564,6 +572,13 @@
                                   ">
                                   <div></div>
                                 </div>
+                                <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(0, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                 <div class="chapter_upload_ic_r" @click.stop="
                                   deleteChapterData(
                                     $event,
@@ -625,6 +640,12 @@
                         >
                           代码编辑器
                         </button>
+                        <button
+                            class="c_pub_button_add pub_btn_add_img"
+                                @click="uploadZIPFile(0)"
+                          >
+                            代码上传
+                          </button>
                       </div>
                       <div v-if="
                         unitJson[unitIndex].chapterInfo[0].taskJson[
@@ -1118,6 +1139,22 @@
                                         overflow: hidden;
                                         text-overflow: ellipsis;
                                       " readonly="true" @click="selectLine(index1)" />
+                          <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(0, index1)"
+                                  />
                           <input :placeholder="item1.title ? item1.title : '链接'
                             " v-if="item1.type == 14" style="
                                         border: none;
@@ -2964,6 +3001,11 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                   </div>
                                   <div class="chapter_upload_n">
                                     <input
@@ -3062,6 +3104,23 @@
                                     readonly="true"
                                     @click="selectLine(0, index1)"
                                   />
+                                  <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(0, index1)"
+                                  />
+
                                   </div>
                                   <div class="chapter_upload_ic">
                                     <div
@@ -3147,6 +3206,13 @@
                                     >
                                       <div></div>
                                     </div>
+                                    <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(0, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                     <div
                                       class="chapter_upload_ic_r"
                                       @click.stop="
@@ -3460,6 +3526,13 @@
                                       ">
                                       <div></div>
                                     </div>
+                                    <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(0, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                     <div class="chapter_upload_ic_r" @click.stop="
                                       deleteChapterData(
                                         $event,
@@ -7057,6 +7130,7 @@
     <wOffice :dialogVisibleOffice.sync="dialogVisibleOffice" :url="wurl" ></wOffice>
     <appDialog ref="appDialog" @success="selectAppSuccess"></appDialog>
     <CodeEditor ref="CodeEditorRef" @success="addHtmlSuccess"></CodeEditor>
+    <selectHtmlPageDialog ref="selectHtmlPageDialogRef" @success="selectHtmlPageSuccess"/>
   </div>
 </template>
 
@@ -7100,6 +7174,7 @@ let convertApi = ConvertApi.auth('secret_U1EO5rhgMCnoBnBT')
 import appDialog from '../components/appDialog.vue'
 import { myMixin } from "@/mixins/mixin.js"
 import CodeEditor from "../components/CodeEditor";
+import { uploadFileMixin } from "../../tools/uploadFileMixin.js";
 
 var OpenCC = require("opencc-js");
 let converter = OpenCC.Converter({
@@ -7112,6 +7187,9 @@ let converter2 = OpenCC.Converter({
 		to:'hk'
 })
 
+
+import selectHtmlPageDialog from '../dialog/selectHtmlPageDialog.vue'
+
 const getFile = (url) => {
   return new Promise((resolve, reject) => {
     var credentials = {
@@ -7151,7 +7229,7 @@ const getFile = (url) => {
 };
 
 export default {
-  mixins: [ myMixin ],
+  mixins: [ myMixin,uploadFileMixin],
   components: {
     CodeEditor,
     EditorBar,
@@ -7179,10 +7257,11 @@ export default {
     MindTask,
     recordV,
     appDialog,
+    selectHtmlPageDialog
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       checkAll: false,
       checkAll2: false,
       chooseType: 1,
@@ -7658,7 +7737,8 @@ export default {
       heightPx: '100%',
       newWidth: 350,
       unitLoading: false,
-      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
+      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'],
+      changeId:""
 
     };
   },
@@ -8094,7 +8174,7 @@ export default {
         }
         this.inputShow = true;
         if (cPan == 2) {
-          // this.steps = old;
+          this.steps = old;
           return;
         }
         this.goTo(
@@ -25527,7 +25607,195 @@ ${msg}
       }
       this.imgChange1(null, null, 8, this.lineCount);
       this.dialogVisible7 = false;
-    }
+    },
+    // zip压缩文件上传
+    uploadZIPFile(i){
+        this.lineCount = i;
+        // 只支持上传zip文件
+        let input = document.createElement('input');
+        input.type = 'file';
+        input.accept = '.zip';
+        input.style.display = 'none';
+        // 只允许上传一个文件
+        input.multiple = false;
+        input.onchange = async (e) => {
+          let file = e.target.files[0];
+          if (!file) return;
+          if (file.type !== 'application/zip' && !file.name.endsWith('.zip')) {
+            this.$message.error('只支持上传zip文件');
+            return;
+          }
+          try{
+            const zip = new JSZip();
+            const content = await zip.loadAsync(file);
+            let _fileStructure = this.buildFileStructure(file,content);
+            let _time = new Date().getTime();
+            let _resultList = await this.uploadZipFileFn(_fileStructure.files,`${_time}_${_fileStructure.folderName}`);
+            this.changeId = "";
+            this.$refs.selectHtmlPageDialogRef.open(_resultList);
+          
+          }catch(e){
+            console.log(e)
+            this.$message.error("解析zip文件失败")
+          }
+        
+        };
+        document.body.appendChild(input);
+        input.click();
+        setTimeout(() => {
+          document.body.removeChild(input);
+        }, 1000);
+        },
+        // 构建文件结构树
+        buildFileStructure(file,zip) {
+        const root = {
+          folderName: file.name.replace(/\.[^/.]+$/, ""), // 移除扩展名
+          files: []
+        };
+
+        // 遍历ZIP文件中的所有文件/文件夹
+        zip.forEach((relativePath, file) => {
+          if (file.dir) return; // 跳过目录
+        
+          const parts = relativePath.split('/');
+          let currentLevel = root.files;
+        
+          for (let i = 0; i < parts.length; i++) {
+            const part = parts[i];
+            const isLast = i === parts.length - 1;
+          
+            if (isLast) {
+              // 添加文件
+              currentLevel.push({fileName:part,file:file});
+            } else {
+              // 查找或创建文件夹
+              let folder = currentLevel.find(item =>
+                typeof item === 'object' && item.folderName === part
+              );
+            
+              if (!folder) {
+                folder = {
+                  folderName: part,
+                  files: []
+                };
+                currentLevel.push(folder);
+              }
+            
+              currentLevel = folder.files;
+            }
+          }
+        });
+
+        return root;
+        },
+        //按路径上传文件
+        async uploadZipFileFn(fileList,path){
+        return new Promise(async (resolve)=>{
+          let _copyFileList = fileList;
+        
+          let promise = [];
+          for(let i = 0; i < _copyFileList.length; i++){
+            if(_copyFileList[i].folderName){
+              let _path = `${path}/${_copyFileList[i].folderName}`;
+              promise.push(this.uploadZipFileFn(_copyFileList[i].files,_path).then(res=>{
+                _copyFileList[i].files = res;
+              }))
+            }else if(_copyFileList[i].fileName){
+              // 将 ZIP 条目转换为文件对象
+              const blob = await _copyFileList[i].file.async('blob');
+              // 根据文件名设置type
+              let type = 'text/html';
+              if (_copyFileList[i].fileName.endsWith('.js')) {
+                type = 'application/javascript';
+              } else if (_copyFileList[i].fileName.endsWith('.css')) {
+                type = 'text/css';
+              } else if (_copyFileList[i].fileName.endsWith('.json')) {
+                type = 'application/json';
+              } else if (_copyFileList[i].fileName.endsWith('.png')) {
+                type = 'image/png';
+              } else if (_copyFileList[i].fileName.endsWith('.jpg') || _copyFileList[i].fileName.endsWith('.jpeg')) {
+                type = 'image/jpeg';
+              } else if (_copyFileList[i].fileName.endsWith('.gif')) {
+                type = 'image/gif';
+              } else if (_copyFileList[i].fileName.endsWith('.svg')) {
+                type = 'image/svg+xml';
+              } else if (_copyFileList[i].fileName.endsWith('.html') || _copyFileList[i].fileName.endsWith('.htm')) {
+                type = 'text/html';
+              } else if (_copyFileList[i].fileName.endsWith('.txt')) {
+                type = 'text/plain';
+              } else if (_copyFileList[i].fileName.endsWith('.pdf')) {
+                type = 'application/pdf';
+              } else if (_copyFileList[i].fileName.endsWith('.mp3')) {
+                type = 'audio/mpeg';
+              } else if (_copyFileList[i].fileName.endsWith('.mp4')) {
+                type = 'video/mp4';
+              } else if (_copyFileList[i].fileName.endsWith('.zip')) {
+                type = 'application/zip';
+              } else if (_copyFileList[i].fileName.endsWith('.xml')) {
+                type = 'application/xml';
+              } else if (_copyFileList[i].fileName.endsWith('.csv')) {
+                type = 'text/csv';
+              } else if (_copyFileList[i].fileName.endsWith('.md')) {
+                type = 'text/markdown';
+              }
+              let _file = new File([blob], _copyFileList[i].fileName, {type: type, lastModified: new Date().getTime()});
+              promise.push(this.awsupload({file:_file,path:`${path}/${_copyFileList[i].fileName}`}).then(res=>{
+                delete _copyFileList[i].file;
+                _copyFileList[i].url = decodeURIComponent(res.Location);
+              }))
+            }
+          }
+          Promise.all(promise).then(res=>{
+            resolve(_copyFileList);
+          })
+        })
+        },
+        selectHtmlPageSuccess(data){
+        let _selectFile = data.find(i=>i.isSelect==="1");
+        if(!_selectFile){
+          this.changeId = "";
+          return this.$message.info("未选择主页面")
+        }
+
+        console.log("_selectFile",_selectFile)
+        let _index = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          0
+        ].chapterData.findIndex(i => i.type == 17 && i.id == this.changeId);
+        if (_index != -1) {
+          console.log("_index",_index)
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            0
+          ].chapterData[_index] = {
+            name: _selectFile.fileName,
+            title: _selectFile.fileName,
+            id:this.changeId,
+            url: _selectFile.url,
+            fileList:data,
+            type: 17
+          };
+        } else {
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            0
+          ].chapterData.push({
+            name: _selectFile.fileName,
+            title: _selectFile.fileName,
+            id:new Date().getTime(),
+            url: _selectFile.url,
+            fileList:data,
+            type: 17
+          });
+        }
+        this.changeId = "";
+        this.$forceUpdate();
+        this.$refs.selectHtmlPageDialogRef.close();
+        },
+        changeHTmlPage(itemTaskIndex,i){
+        let _data = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].chapterData[i];
+        this.changeId = _data.id;
+        this.$refs.selectHtmlPageDialogRef.open(_data.fileList);
+        }
   },
   beforeDestroy() {
     // clearTimeout(this.timer);

+ 9 - 2
src/components/pages/classroomObservation/components/analysisSpecialItem.vue

@@ -722,6 +722,7 @@ ${JSON.stringify(_dataList)}
     },
     // 教学模式分析
     getTeachingModeData(_dataList, type = 0) {
+    console.log("_dataList",_dataList)
       this.openItem = false;
       this.loading = true;
       let _continuousTime = 0;
@@ -774,11 +775,17 @@ ${JSON.stringify(_dataList)}
 
         if (item.role == "老师") {
           _teacherTime += this.convertToSeconds(item.time);
-        }
 
-        _totalTime += this.convertToSeconds(item.time);
+        }
+        console.log("time",_totalTime,'==>',this.convertToSeconds(item.time))
+        if(item.time){
+          _totalTime += this.convertToSeconds(item.time);
+        }
       });
 
+      console.log("_teacherTime",_teacherTime)
+      console.log("_totalTime",_totalTime)
+      console.log("_continuousTime",_continuousTime)
       let _RT = (_teacherTime / _totalTime).toFixed(2);
       let _CH = (_continuousTime / _totalTime).toFixed(2);
 

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 556 - 456
src/components/pages/classroomObservation/components/chatArea.vue


+ 5 - 3
src/components/pages/classroomObservation/components/messageArea.vue

@@ -279,8 +279,8 @@ export default {
 			return new Promise(resolve => {
 				if(this.bmData && this.bmData.jsonData && this.bmData.jsonData.editorBarData){
 					if(this.bmData.jsonData.editorBarData && (this.bmData.jsonData.editorBarData.content || this.bmData.jsonData.editorBarData.url)){
-						this.$confirm("是否保留本课堂的转录文稿数据至新课堂?","提示").then(_ => {
-							window.localStorage.setItem("saveEditorBarData",JSON.stringify({editorBarData:this.bmData.jsonData.editorBarData,fileId:this.fileId}));
+						this.$confirm("是否复用当前数据?","提示").then(_ => {
+							window.localStorage.setItem("saveEditorBarData",JSON.stringify({fileId:this.fileId,bmData:this.bmData.jsonData,imageList:this.imageList.jsonData}));
 							resolve(1);
 						}).catch(_ => {
 							resolve(2);
@@ -675,7 +675,8 @@ export default {
 							let saveEditorBarData = window.localStorage.getItem("saveEditorBarData")?JSON.parse(window.localStorage.getItem("saveEditorBarData")):null;
 							if(saveEditorBarData){
 								console.log("saveEditorBarData👉",saveEditorBarData)
-								_bmData.jsonData.editorBarData = saveEditorBarData.editorBarData;
+								_bmData.jsonData = saveEditorBarData.bmData;
+                _imageList.jsonData = saveEditorBarData.imageList;
 								// this.fileId = _saveEditorBarData.fileId;
 								window.localStorage.removeItem("saveEditorBarData");
 							}
@@ -711,6 +712,7 @@ export default {
 								console.log("保存数据👉",saveEditorBarData)
 								this.$parent.updateFileId(saveEditorBarData.fileId);
 								this.saveData(this.bmData);
+                this.saveData(this.imageList)
 							}
               resolve();
             } else {

+ 1 - 1
src/components/pages/classroomObservation/components/transcription.vue

@@ -5,7 +5,7 @@
 			<div class="t-h-time">{{ data.time }}</div>
 		</div> -->
 		<div class="t-content">
-			{{ data.content?data.content:"暂无..." }}
+			<div style="white-space: pre-line;" v-html="data.content?data.content:'暂无...'"></div>
 			<span v-if="showGetTextLoading">_(转译中...)</span>
 			<!-- <div class="contentCon" v-for="(i, index) in chatList" :key="index">
 				<div class="conTim">{{ i.timer }}</div>

+ 25 - 4
src/components/pages/classroomObservation/dialog/batchCreationClassDialog.vue

@@ -337,7 +337,9 @@ export default {
                 type: "generateReport",
                 text: "生成报告",
                 status: "0",
-                progress: "0"
+                progress: "0",
+                num: _analysisList.length,
+                successNum: 0
               },
               {
                 type: "createClass",
@@ -397,7 +399,9 @@ export default {
                 type: "generateReport",
                 text: "生成报告",
                 status: "0",
-                progress: "0"
+                progress: "0",
+                num: _analysisList.length,
+                successNum: 0
               },
               {
                 type: "createClass",
@@ -459,7 +463,9 @@ export default {
                 type: "generateReport",
                 text: "生成报告",
                 status: "0",
-                progress: "0"
+                progress: "0",
+                num: _analysisList.length,
+                successNum: 0
               },
               {
                 type: "createClass",
@@ -795,6 +801,7 @@ export default {
               .find(i => i.id === id)
               .jsonData.steps.find(i => i.type == "generateReport").status =
               "0";
+              this.dataList.find(i => i.id === id).jsonData.steps.find(i => i.type == "generateReport").successNum = 0;
               this.dataList
               .find(i => i.id === id)
               .jsonData.steps.find(i => i.type == "createClass").status =
@@ -1000,7 +1007,8 @@ export default {
                 });
               }
 
-              if (["audio/x-m4a", "audio/mpeg"].includes(_file.type)) {
+              // 只对m4a文件进行转wav,mp3文件不再转码
+              if (_file.type === "audio/x-m4a") {
                 let _data = await this.audioToWavMixin(_file);
                 if (_data !== 1) {
                   _file = _data.data;
@@ -1209,6 +1217,7 @@ export default {
           } else if (_step.type === "generateReport") {
             //生成报告
             _stepList[i].status = "2";
+            _stepList[i].successNum = 0;
             _stepList[i].startTime =
               new Date().toLocaleDateString().replaceAll("/", "-") +
               " " +
@@ -1217,6 +1226,7 @@ export default {
             this.dataList.find(
               i => i.id === _startData.id
             ).jsonData.steps = _stepList;
+            let _i = i;
             this.$forceUpdate()
             let _analysisList = _startData.jsonData.analysisList;
 
@@ -1282,7 +1292,17 @@ export default {
                     _startData.jsonData.analysisList[index].status = "success";
                     _startData.jsonData.analysisList[index].jsonData =
                       data.data;
+                    _stepList[_i].successNum += 1;
+                    this.dataList.find(i2 => i2.id === _startData.id).jsonData.steps[_i].successNum = _stepList[_i].successNum;
+                    this.$forceUpdate();
                     resolve();
+
+                    // this.updateTask(_startData.id);
+                    // _startData.jsonData = JSON.parse(
+                    //   JSON.stringify(
+                    //     this.dataList.find(i => i.id === _startData.id).jsonData
+                    //   )
+                    // );
                   }
                 };
                 getAnalysis();
@@ -1586,6 +1606,7 @@ export default {
             .jsonData.steps.find(i2 => i2.type == "generateReport").status =
             "0";
         });
+        this.dataList.find(i => i.id === id).jsonData.steps.find(i => i.type == "generateReport").successNum = 0;
 
         if (!this.dataList.some(i => i.status == "1")) {
           this.startTask(_generateList[0].id);

+ 188 - 93
src/components/pages/classroomObservation/index.vue

@@ -16,6 +16,15 @@
 					class="co-h2-l-icon"
 					@click="$refs.addNewCourseDialogRef.open()"
 				></span> -->
+        <div
+          class="r_pub_button_retrun"
+          style="margin-right: 10px;"
+          v-if="gotype"
+          @click.stop="$router.go(-1)"
+        >
+          <!-- <span class="co-h2-r-b-icon3"></span> -->
+          返回
+        </div>
         <span class="co-h2-l-icon"></span>
         <!-- @click="addNewCourse()" -->
         <!--<span class="co-h2-l-hr"></span>-->
@@ -82,8 +91,11 @@
 				</div> -->
       </div>
       <div class="co-h2-right">
-
-        <div class="co-h2-r-btn" style="background: rgba(54, 129, 252, 1)" @click.stop="batchBtn()">
+        <div
+          class="co-h2-r-btn"
+          style="background: rgba(54, 129, 252, 1)"
+          @click.stop="batchBtn()"
+        >
           <span class="co-h2-r-b-icon3"></span>
           <div style="color: #fff;">批量创建</div>
         </div>
@@ -157,10 +169,6 @@
             />
           </el-tooltip>
         </div>
-        <div :class="['co-h2-r-btn2']"  v-if="gotype" @click.stop="$router.go(-1)">
-          <!-- <span class="co-h2-r-b-icon3"></span> -->
-          返回
-        </div>
         <!-- <div :class="['co-h2-r-btn2']" @click.stop="home">
 					<el-tooltip
 						class="item"
@@ -199,7 +207,7 @@
           @changeTranscription="changeTranscription"
           @changeOptionData="changeOptionData"
           @updateTime="updateTime"
-					@getVideoAudioSuccess="getVideoAudioSuccess"
+          @getVideoAudioSuccess="getVideoAudioSuccess"
         />
       </div>
     </div>
@@ -209,7 +217,11 @@
       ref="changeCourseNameDialogRef"
       @success="changeCourseSuccess"
     />
-    <batchCreationClassDialog ref="batchCreationClassDialogRef" @addNewCourseOption="addNewCourseOption" @changeClass="changeTid"/>
+    <batchCreationClassDialog
+      ref="batchCreationClassDialogRef"
+      @addNewCourseOption="addNewCourseOption"
+      @changeClass="changeTid"
+    />
 
     <!-- <addNewCourseDialog
 			:courseList="optionData"
@@ -240,7 +252,7 @@ import "echarts-wordcloud";
 import htmlDocx from "html-docx-js/dist/html-docx";
 import saveAs from "file-saver";
 import MarkdownIt from "markdown-it";
-import batchCreationClassDialog from './dialog/batchCreationClassDialog.vue'
+import batchCreationClassDialog from "./dialog/batchCreationClassDialog.vue";
 export default {
   components: {
     chatArea,
@@ -252,7 +264,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       loading: false,
       createTime: new Date().toLocaleString().replaceAll("/", "-"),
       tid: "",
@@ -284,20 +296,22 @@ export default {
       }
     };
   },
-	watch:{
-		fileIdId(newValue){
-			let needUpdateFileId = window.localStorage.getItem("needUpdateFileId")?window.localStorage.getItem("needUpdateFileId"):null;
-			if(needUpdateFileId && newValue){
-				console.log("查询到needUpdateFileId,更新fileId👉",needUpdateFileId)
-				this.updateFileId(needUpdateFileId);
-				window.localStorage.removeItem("needUpdateFileId");
-			}
-		}
-	},
+  watch: {
+    fileIdId(newValue) {
+      let needUpdateFileId = window.localStorage.getItem("needUpdateFileId")
+        ? window.localStorage.getItem("needUpdateFileId")
+        : null;
+      if (needUpdateFileId && newValue) {
+        console.log("查询到needUpdateFileId,更新fileId👉", needUpdateFileId);
+        this.updateFileId(needUpdateFileId);
+        window.localStorage.removeItem("needUpdateFileId");
+      }
+    }
+  },
   methods: {
     //切换了课堂
     changeTid(newValue) {
-      if(this.tid!=newValue)this.tid = newValue;
+      if (this.tid != newValue) this.tid = newValue;
       this.$nextTick(async () => {
         this.getFileIdId();
         this.$refs.messageAreaRef.getData();
@@ -393,7 +407,7 @@ export default {
           userid: this.userId,
           template: json
         };
-        console.log("创建新课堂",params);
+        console.log("创建新课堂", params);
         this.ajax
           .post(
             "https://gpt4.cocorobo.cn/insert_classroom_observation_template",
@@ -448,10 +462,10 @@ export default {
       });
     },
     updateFileId(newValue) {
-			if(!this.fileIdId){
-				console.log("未查询到fileIdId,先保存到localStorage👉",newValue)
-				return window.localStorage.setItem("needUpdateFileId",newValue);
-			}
+      if (!this.fileIdId) {
+        console.log("未查询到fileIdId,先保存到localStorage👉", newValue);
+        return window.localStorage.setItem("needUpdateFileId", newValue);
+      }
       this.ajax
         .post("https://gpt4.cocorobo.cn/update_classroom_observation", {
           id: this.fileIdId,
@@ -485,7 +499,7 @@ export default {
     //预览
     preview() {
       if (!this.fileId) return;
-       window.topU.postMessage(
+      window.topU.postMessage(
         {
           tools: "classroom_observation_board",
           type: this.tid
@@ -517,9 +531,6 @@ export default {
           });
         });
 
-
-
-
         let directoryHtml = `<div style="margin-bottom:1in"><div style="text-align:center;font-size:20pt;margin-bottom:0.5in">目录</div>`;
 
         let analysisHtml = ``;
@@ -533,10 +544,10 @@ export default {
           }
           i.dataList.sort((a, b) => a.tIndex - b.tIndex);
           tagHtml += `<h1 style="font-size:16pt;margin-bottom:-1in">${
-            this.tag[i.value]
+            this.tag[c]
           }、${i.name}</h1>`;
           dire += `<p style="font-size:14pt;margin-bottom:-0.8in">${
-            this.tag[i.value]
+            this.tag[c]
           }、${i.name}</p>`;
 
           for (let d = 0; d < i.dataList.length; d++) {
@@ -579,7 +590,14 @@ export default {
               )}"/></div>`;
             }
 
-            let _content = md.render(i2.jsonData.content).replace(/<p>/g, '').replace(/<\/p>/g, '').replace(/<strong>/g, '<span style="font-weight: bold;">').replace(/<\/strong>/g, '</span>');
+            let _content = this.processHtml(
+              md
+                .render(i2.jsonData.content)
+                .replace(/<p>/g, "")
+                .replace(/<\/p>/g, "")
+                .replace(/<strong>/g, '<span style="font-weight: bold;">')
+                .replace(/<\/strong>/g, "</span>")
+            );
             tagHtml += `<p style="font-size:10.5pt;margin-bottom:-0.5in">${_content}</p>`;
           }
           tagHtml += "</div>";
@@ -618,11 +636,13 @@ export default {
 			</div>
 			${directoryHtml}
 
+      <p><br style="page-break-before:always;"></p>
+
 			<div>
 				${analysisHtml}
 			</div>
 			`;
-      // return console.log(analysisHtml.replace(/<img.*?>/g, ''))
+        // return console.log(analysisHtml.replace(/<img.*?>/g, ''))
 
         this.generateDocx(`《${bmData.courseName}》课堂观察报告`, _html);
         this.loading = false;
@@ -650,32 +670,52 @@ export default {
     },
     getEChartsImageSrc(option) {
       return new Promise(resolve => {
-        let hiddenDiv = document.createElement("div");
-        hiddenDiv.style.width = "400px";
-        hiddenDiv.style.height = "400px";
-        hiddenDiv.style.position = "absolute";
-        hiddenDiv.style.left = "-9999px"; // 隐藏div
-        document.body.appendChild(hiddenDiv);
-
-        // 初始化图表
-        let myChart = echarts.init(hiddenDiv);
-
-        // 设置图标配置
-        myChart.setOption(option);
-
-        myChart.on("finished", () => {
-          // 获取图表的图片
-          let base64Image = myChart.getDataURL({
-            type: "png", // 图片格式
-            pixelRatio: 0.9, // 图像清晰度
-            backgroundColor: "#fff" // 背景颜色
-          });
+        try {
+          let hiddenDiv = document.createElement("div");
+          hiddenDiv.style.width = "600px";
+          hiddenDiv.style.height = "400px";
+          hiddenDiv.style.position = "absolute";
+          hiddenDiv.style.left = "-9999px"; // 隐藏div
+          document.body.appendChild(hiddenDiv);
+
+          // 初始化图表
+          let myChart = echarts.init(hiddenDiv);
+
+          console.log(option);
+          option.animation = false;
+
+          let time;
+          myChart
+            .on("rendered", async () => {
+              // console.log("生成echarts成功")
+              // 获取图表的图片
+
+              clearTimeout(time);
+              time = setTimeout(() => {
+                let base64Image = myChart.getDataURL({
+                  type: "png", // 图片格式
+                  pixelRatio: 0.9, // 图像清晰度
+                  backgroundColor: "#fff" // 背景颜色
+                });
 
-          resolve(base64Image);
-          // 清除隐藏的div和图表实例
-          document.body.removeChild(hiddenDiv);
-          myChart.dispose();
-        });
+                resolve(base64Image);
+                // 清除隐藏的div和图表实例
+                document.body.removeChild(hiddenDiv);
+                myChart.dispose();
+              }, 200);
+            })
+            .on("error", error => {
+              console.log("生成echarts失败", error);
+              resolve("#");
+            });
+
+          // 设置图标配置
+          myChart.setOption(option);
+          // console.log("词云图???",option)
+        } catch (error) {
+          console.log(error, "error");
+          resolve("#");
+        }
       });
     },
     getImageSrcToBase64(src) {
@@ -781,7 +821,7 @@ export default {
             }
             _lastI = i;
           }
-          if (canvasWidth2 - _lastI >60) {
+          if (canvasWidth2 - _lastI > 60) {
             ctx.beginPath();
             ctx.strokeStyle = "#BFBFBF";
             ctx.moveTo(canvasWidth2 + 10, canvasHeight - 70);
@@ -790,7 +830,11 @@ export default {
             ctx.fillStyle = "#868686";
             let timeLabel = (sum / 60).toFixed(0); // 时间标识计算
             ctx.font = `${fontSize}px serif`;
-            ctx.fillText(`${timeLabel}min`, canvasWidth2 - 20, canvasHeight - 40);
+            ctx.fillText(
+              `${timeLabel}min`,
+              canvasWidth2 - 20,
+              canvasHeight - 40
+            );
           }
 
           ctx.beginPath();
@@ -824,12 +868,19 @@ export default {
           ctx.imageSmoothingEnabled = false;
           ctx.lineWidth = 1;
           const img = new Image();
-          img.src = require("../../../assets/icon/classroomObservation/rt-ch_echarts2.svg");  //ch_echarts2
+          img.src = require("../../../assets/icon/classroomObservation/rt-ch_echarts2.svg"); //ch_echarts2
           img.onload = () => {
             ctx.drawImage(img, 0, 0, canvasWidth, canvasWidth);
             ctx.beginPath();
-            let _showWidth = canvasWidth-((canvasWidth/8.8)*2)
-            ctx.arc((canvasWidth/8.8)+(_showWidth*parseFloat(data.RT)),(canvasWidth/8.8)+_showWidth-(_showWidth*parseFloat(data.CH)),4,0,2*Math.PI);
+            let _showWidth = canvasWidth - (canvasWidth / 8.8) * 2;
+            ctx.fillStyle = fontColor;
+            ctx.arc(
+              canvasWidth / 8.8 + _showWidth * parseFloat(data.RT),
+              canvasWidth / 8.8 + _showWidth - _showWidth * parseFloat(data.CH),
+              4,
+              0,
+              2 * Math.PI
+            );
             ctx.lineWidth = 0.5; // 设置边框大小
             // ctx.arc((canvasWidth*parseFloat(this.data.RT))+(canvasWidth/8.8),(canvasWidth-(canvasWidth*parseFloat(this.data.CH))+(canvasWidth/8.8)), 4, 0, 2 * Math.PI);
             ctx.fill();
@@ -838,7 +889,11 @@ export default {
             ctx.font = "italic bold 24px Arial";
             const text = `RT=${data.RT}    CH=${data.CH}`;
             const textWidth = ctx.measureText(text).width;
-            ctx.fillText(text, (canvasWidth - textWidth) / 2, canvasHeight - canvasWidth / 12);
+            ctx.fillText(
+              text,
+              (canvasWidth - textWidth) / 2,
+              canvasHeight - canvasWidth / 12
+            );
             const base64Image = canvas.toDataURL("image/png");
             resolve(base64Image);
           };
@@ -887,29 +942,29 @@ export default {
           <title>${name}</title>
           <style>
 						*{
-							font-family: '宋体';
-							margin:0;
-							padding:0;
-							line-height:1;
-						}
+			      	font-family: '宋体';
+			      	margin:0;
+			      	padding:0;
+			      	line-height:1;
+			      }
             table {
               border-collapse: collapse; /* 折叠边框 */
               width: 100%;
-							font-size:10.5pt;
+			      	font-size:10.5pt;
             }
             th, td {
               border: 1px solid black; /* 线条样式 */
               padding: 8px;
               text-align: left;
-							font-size:10.5pt;
+			      	font-size:10.5pt;
             }
-						ol,ul{
-							margin:0;
-							padding:0;
-							margin-right:-1in;
-						}
-						li{
-							position: relative;
+			      ol,ul{
+			      	margin:0;
+			      	padding:0;
+			      	margin-right:-1in;
+			      }
+			      li{
+			      	position: relative;
               padding-left: 1.5em; /* 控制项目符号与文本的距离 */
               margin-bottom: 0.5em;
               text-indent: -1.5em; /* 负缩进使文本与符号对齐 */
@@ -922,11 +977,11 @@ export default {
               mso-style-unhide: no;
               mso-style-qformat: yes;
               mso-style-parent: "";
-						}
-						p{
-							margin:0;
-							padding:0
-						}
+			      }
+			      p{
+			      	margin:0;
+			      	padding:0
+			      }
           </style>
       </head>
       <body>
@@ -997,7 +1052,7 @@ export default {
     // 审核
     examine() {
       if (!this.tid) return;
-       window.topU.postMessage(
+      window.topU.postMessage(
         {
           tools: "classroom_observation_ob_comment",
           type: this.tid
@@ -1229,15 +1284,56 @@ export default {
       }
       return formattedTime;
     },
-		getVideoAudioSuccess(file){
-			this.$refs.chatAreaRef.getVideoAudioSuccess(file)
-		},
-    batchBtn(){
+    getVideoAudioSuccess(file) {
+      this.$refs.chatAreaRef.getVideoAudioSuccess(file);
+    },
+    batchBtn() {
       this.$refs.batchCreationClassDialogRef.open();
     },
-    addNewCourseOption(newOption){
+    addNewCourseOption(newOption) {
       this.optionData.unshift(newOption);
     },
+    processHtml(html) {
+      // 1. 先把 li 里的 ol 结构替换掉
+      html = html.replace(
+        /<li>\s*<ol[^>]*>\s*<li>([\s\S]*?)<\/li>\s*<\/ol>\s*<\/li>/g,
+        (match, content) => {
+          return `<li>\n${content.trim()}\n</li>`;
+        }
+      );
+
+      // 2. 给 li 里的内容按行加 br
+      html = html.replace(/<li>([\s\S]*?)<\/li>/g, (match, content) => {
+        const lines = content
+          .trim()
+          .split(/(?:\r?\n)+/)
+          .map(line => line.trim())
+          .filter(line => line); // 过滤空行
+
+        if (lines.length <= 1) {
+          return `<li>\n${lines.join("")}\n</li>`;
+        } else {
+          return `<li>\n${lines.join("<br>\n")}\n</li>`;
+        }
+      });
+
+      // 3. 处理 pre 里的换行
+      html = html.replace(/<pre>([\s\S]*?)<\/pre>/g, (match, content) => {
+        const lines = content
+          .trim()
+          .split(/(?:\r?\n)+/)
+          .map(line => line.trim())
+          .filter(line => line); // 过滤空行
+
+        if (lines.length <= 1) {
+          return `<pre>${lines.join("")}</pre>`;
+        } else {
+          return `<pre>${lines.join("<br>\n")}</pre>`;
+        }
+      });
+
+      return html;
+    }
   },
   mounted() {
     this.getCourseList().then(_ => {
@@ -1437,12 +1533,11 @@ export default {
 }
 
 .co-h2-r-b-icon3 {
-  background: url("../../../assets/icon/classroomObservation/batch_icon.svg") no-repeat;
+  background: url("../../../assets/icon/classroomObservation/batch_icon.svg")
+    no-repeat;
   background-size: 100% 100%;
 }
 
-
-
 /* .co-h2-r-b-icon2 {
 	background: url("../../../assets/icon/classroomObservation/daoChu.png")
 		no-repeat;

+ 4 - 4
src/components/pages/classroomObservation/newComponents/batchClassCard.vue

@@ -68,7 +68,7 @@
                   src="../../../../assets/icon/classroomObservation/isDoStatus_icon.svg"
                   v-if="item.status=='2'"
                 />
-                <div>{{ item.text }}</div>
+                <div>{{ item.text }}<span v-if="item.num">({{ item.successNum }}/{{ item.num }})</span></div>
                 <span>
                   <span v-if="item.startTime">{{ item.startTime }}</span>
                   <!-- <span
@@ -112,7 +112,7 @@
                   src="../../../../assets/icon/classroomObservation/isDoStatus_icon.svg"
                   v-if="item.status=='2'"
                 />
-                <div>{{ item.text }}</div>
+                <div>{{ item.text }}<span v-if="item.num">({{ item.successNum }}/{{ item.num }})</span></div>
                 <span>
                   <span v-if="item.startTime">{{ item.startTime }}</span>
                   <!-- <span
@@ -431,7 +431,7 @@ export default {
 }
 
 .stepBox {
-  width: 315px;
+  width: 350px;
   height: auto;
   background-color: #fff;
   position: absolute;
@@ -475,7 +475,7 @@ export default {
   display: flex;
   align-items: center;
   justify-content: center;
-  width: 150px;
+  width: 260px;
   height: 100%;
   color: rgba(54, 129, 252, 1);
 }

+ 150 - 84
src/components/pages/classroomObservation/tools/mixin.js

@@ -245,7 +245,7 @@ ${arr.map(row => `<tr>
 
               console.log("需要上传的文件", audioFile)
               this.uploadFileMixin(audioFile).then(upload => {
-                console.log("upload=>",upload)
+                console.log("upload=>", upload)
                 resolve({ audioUrl: upload, fileObj: audioFile })
               })
             } catch (error) {
@@ -1250,95 +1250,159 @@ CH:${_CH}
         let transcriptionContent = "";
         let tableContent = "";
         let tableList = [];
+        let textList  = [];
         let _startTime = 0;
         let _endTime = 0;
 
         let timer = null;
 
-        timer = setTimeout(() => {//五分钟无响应就算报错
-          resolve({ data: 1, transcriptionContent: null, editorBarData: null, err: "转录超时" })
-        }, 180000)
 
-        // 转录中
-        iframeRef.contentWindow.onRecognizedResult = (e) => {
-          let privText = e.privText;
-          let privSpeakerId = e.privSpeakerId;
-          let privDuration = e.privDuration;
-          let privOffset = e.privOffset;
-
-          if (timer) {
-            clearTimeout(timer)
-            timer = setTimeout(() => {//五分钟无响应就算报错
-              resolve({ data: 1, transcriptionContent: null, editorBarData: null, err: "转录超时" })
-            }, 180000)
-          }
-          if (!privText || !privSpeakerId || privSpeakerId == "Unknown") {//不记录
-            return;
-          }
-
-          _endTime = (privOffset + privDuration) / 10000000;
-
-          tableList.push({
-            value: privText,
-            startTime: this.updateRecordedTimeMixin({ duration: _startTime }),
-            endTime: this.updateRecordedTimeMixin({ duration: _endTime }),
-            time: this.updateRecordedTimeMixin({ duration: _endTime - _startTime }),
-            role: privSpeakerId,
-            code: ""
-          });
-
-          _startTime = _endTime;
-          transcriptionContent += privText;
-        };
-
-        //转录结束
-        iframeRef.contentWindow.onSessionStopped = async (e) => {
-          if (timer) {
-            clearTimeout(timer)
-          }
-          tableContent = `<table
-	border="0"
-	width="100%"
-	cellpadding="0"
-	cellspacing="0"
-	style="text-align: center"
->
-	<tbody>
-		<tr>
-			<th>序号</th>
-			<th>开始时间</th>
-			<th>结束时间</th>
-			<th>发言内容</th>
-			<th>时长</th>
-			<th>说话人身份</th>
-			<th>行为编码</th>
-	</tr>`;
-          tableList.forEach((item, index) => {
-            tableContent += `<tr>
-							<td>${index + 1}</td>
-							<td>${item.startTime}</td>
-							<td>${item.endTime}</td>
-							<td>${item.value}</td>
-							<td>${item.time}</td>
-							<td>${item.role}</td>
-							<td>${item.code}</td>
-						</tr>`
-          })
-
-          // tableContent += `<tr><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr></tbody></table>`
-
-          var blob = new Blob([tableContent], { type: "text/plain;charset=utf-8" });
-          blob.lastModifiedDate = new Date();
-          blob.name = `classroomObservation.txt`;
-          this.uploadFileMixin(blob).then(upload => {
-            resolve({ transcriptionContent: transcriptionContent, editorBarData: { type: "0", url: upload.Location, content: tableContent, tableList: tableList } })
+        iframeRef.contentWindow.window
+          .doConversationTranscriber({ files: [file] })
+          .then(res => {
+            console.log("转录内容", res);
+
+            let _data = res.phrases;
+
+            _data.forEach(i => {
+              let _privSpeakerId = `Guest-${i.speaker}`;
+              let _privText = i.text;
+              let privOffset = i.offsetMilliseconds;
+              let privDuration = i.durationMilliseconds;
+
+              _endTime = (privOffset + privDuration) / 1000;
+              textList.push({
+                value: _privText,
+                startTime: this.updateRecordedTimeMixin({ duration: _startTime }),
+                endTime: this.updateRecordedTimeMixin({ duration: _endTime }),
+                time: this.updateRecordedTimeMixin({
+                  duration: _endTime - _startTime
+                }),
+                role: _privSpeakerId,
+                code: ""
+              });
+              _startTime = _endTime;
+              transcriptionContent +=
+                _privSpeakerId + ":" + _privText + "\n";
+            });
+            let _result = `<table border="0" width="100%" cellpadding="0" cellspacing="0" style="text-align: center"><tbody><tr><th>序号</th><th>开始时间</th><th>结束时间</th><th>发言内容</th><th>时长</th><th>说话人身份</th><th>行为编码</th></tr>`;
+            textList.forEach((item, index) => {
+              _result += `<tr><td>${index + 1}</td><td>${item.startTime}</td><td>${item.endTime}</td><td>${item.value}</td><td>${item.time}</td><td>${item.role}</td><td>${item.code}</td></tr>`;
+            });
+            _result += `</tbody></table>`;
+            var blob = new Blob([_result], { type: "text/plain;charset=utf-8" });
+            blob.lastModifiedDate = new Date();
+            blob.name = `classroomObservation.txt`;
+            this.uploadFileMixin(blob).then(upload => {
+              console.log("上传成功并resolve",{transcriptionContent: transcriptionContent, editorBarData: { type: "0", url: upload.Location, content: _result, tableList: textList } })
+              resolve({transcriptionContent: transcriptionContent, editorBarData: { type: "0", url: upload.Location, content: _result, tableList: textList } })
+            })
+            // this.wavGetTextProgress = 100;
+            // if (this.wavFileGetTextLoading) this.$message.success("转译完成");
+            // // _this.editorBarData.content += privText;
+
+            // this.showGetTextLoading = false;
+            // this.wavGetTextLoading = false;
+            // this.uploadFileLoading = false;
+            // // this.uploadWavFile(audioFile);
+            // if (_timer) {
+            //   clearInterval(_timer);
+            // }
+            // this.saveEditorBar();
           })
-        };
+          .catch(err => {
+            console.log("转录error",err)
+            resolve({ data: 1, transcriptionContent: null, editorBarData: null, err: err })
+            //     console.log(err)
+            //     this.wavGetTextLoading = false;
+            // this.showGetTextLoading = false;
+          });
+        // timer = setTimeout(() => {//五分钟无响应就算报错
+        //   resolve({ data: 1, transcriptionContent: null, editorBarData: null, err: "转录超时" })
+        // }, 180000)
 
-        //开始转录
-        iframeRef.contentWindow.ConversationTranscriber({
-          files: [file]
-        });
+        // 转录中
+        //         iframeRef.contentWindow.onRecognizedResult = (e) => {
+        //           let privText = e.privText;
+        //           let privSpeakerId = e.privSpeakerId;
+        //           let copySpeakerId = e.copySpeakerId;
+        //           let privDuration = e.privDuration;
+        //           let privOffset = e.privOffset;
+
+        //           console.log("转录内容",e)
+        //           if (timer) {
+        //             clearTimeout(timer)
+        //             timer = setTimeout(() => {//五分钟无响应就算报错
+        //               resolve({ data: 1, transcriptionContent: null, editorBarData: null, err: "转录超时" })
+        //             }, 180000)
+        //           }
+        //           if (!privText || !privSpeakerId || privSpeakerId == "Unknown") {//不记录
+        //             return;
+        //           }
+
+        //           _endTime = (privOffset + privDuration) / 10000000;
+
+        //           tableList.push({
+        //             value: privText,
+        //             startTime: this.updateRecordedTimeMixin({ duration: _startTime }),
+        //             endTime: this.updateRecordedTimeMixin({ duration: _endTime }),
+        //             time: this.updateRecordedTimeMixin({ duration: _endTime - _startTime }),
+        //             role: privSpeakerId,
+        //             code: ""
+        //           });
+
+        //           _startTime = _endTime;
+        //           transcriptionContent += copySpeakerId + ":" + privText + "\n";
+        //         };
+
+        //         //转录结束
+        //         iframeRef.contentWindow.onSessionStopped = async (e) => {
+        //           if (timer) {
+        //             clearTimeout(timer)
+        //           }
+        //           tableContent = `<table
+        // 	border="0"
+        // 	width="100%"
+        // 	cellpadding="0"
+        // 	cellspacing="0"
+        // 	style="text-align: center"
+        // >
+        // 	<tbody>
+        // 		<tr>
+        // 			<th>序号</th>
+        // 			<th>开始时间</th>
+        // 			<th>结束时间</th>
+        // 			<th>发言内容</th>
+        // 			<th>时长</th>
+        // 			<th>说话人身份</th>
+        // 			<th>行为编码</th>
+        // 	</tr>`;
+        //           tableList.forEach((item, index) => {
+        //             tableContent += `<tr>
+        // 							<td>${index + 1}</td>
+        // 							<td>${item.startTime}</td>
+        // 							<td>${item.endTime}</td>
+        // 							<td>${item.value}</td>
+        // 							<td>${item.time}</td>
+        // 							<td>${item.role}</td>
+        // 							<td>${item.code}</td>
+        // 						</tr>`
+        //           })
+
+        //           // tableContent += `<tr><td></td><td></td><td></td><td></td><td></td><td></td><td></td></tr></tbody></table>`
+
+        //           var blob = new Blob([tableContent], { type: "text/plain;charset=utf-8" });
+        //           blob.lastModifiedDate = new Date();
+        //           blob.name = `classroomObservation.txt`;
+        //           this.uploadFileMixin(blob).then(upload => {
+        //             resolve({ transcriptionContent: transcriptionContent, editorBarData: { type: "0", url: upload.Location, content: tableContent, tableList: tableList } })
+        //           })
+        //         };
+
+        //         //开始转录
+        //         iframeRef.contentWindow.ConversationTranscriber({
+        //           files: [file]
+        //         });
       })
 
     },
@@ -2004,6 +2068,7 @@ CH:${_CH}
 
           let analysisHtml = ``;
 
+
           // console.log("开始处理文件")
           for (let c = 0; c < tagList.length; c++) {
             // console.log(tagList[c],"tagList[c]")
@@ -2014,9 +2079,9 @@ CH:${_CH}
               i.dataList = i.dataList.filter(i2 => i2.tIndex != 2);
             }
             i.dataList.sort((a, b) => a.tIndex - b.tIndex);
-            tagHtml += `<h1 style="font-size:16pt;margin-bottom:-1in">${this.tag[i.value]
+            tagHtml += `<h1 style="font-size:16pt;margin-bottom:-1in">${this.tag[c]
               }、${i.name}</h1>`;
-            dire += `<p style="font-size:14pt;margin-bottom:-0.8in">${this.tag[i.value]
+            dire += `<p style="font-size:14pt;margin-bottom:-0.8in">${this.tag[c]
               }、${i.name}</p>`;
 
             for (let d = 0; d < i.dataList.length; d++) {
@@ -2097,6 +2162,7 @@ CH:${_CH}
 			      	</div>
 			      </div>
 			      ${directoryHtml}
+            <p><br style="page-break-before:always;"></p>
 
 			      <div>
 			      	${analysisHtml}

+ 59 - 5
src/components/pages/course.vue

@@ -283,6 +283,14 @@
                 " @click="goToCourse6(item.courseId)">
 									<img src="../../assets/icon/course/edit.svg">
 								</div>
+
+                <div class="t_b_Item" v-if="((item.userid == userid) ||
+                (item.course_teacher &&
+                  item.course_teacher.indexOf(userid) !== -1) || role == '1') &&
+                (item.state == 7)
+                " @click="goToPptEasy(item.courseId)">
+									<img src="../../assets/icon/course/edit.svg">
+								</div>
     					</el-tooltip>
 
 							<el-tooltip effect="dark" content="lang.Delete" placement="top" v-if="item.isCourseType == 1 || role == '1'">
@@ -438,7 +446,7 @@ export default {
   mixins: [ myMixin ],
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       itemCount: 1,
       courseTitle: "",
       courseText: "",
@@ -490,7 +498,10 @@ export default {
       dialogVisibleTemplate: false,
       dialogVisibleTemplate2: false,
       orgArray:[],
-      oidArray:[]
+      oidArray:[],
+      pptArrayOrg:[],
+      pptArrayOid:[],
+
     };
   },
   watch: {
@@ -505,16 +516,30 @@ export default {
         .then((res) => {
           let oid = res.data[0];
           let org = res.data[1];
+          let pptOid = res.data[2];
+          let pptOrg = res.data[3];
           let oidArray = []
           let orgArray = []
+          let pptOidArray = []
+          let pptOrgArray = []
           for(var i = 0; i < oid.length; i++){
             oidArray.push(oid[i].oid)
           }
           for(var i = 0; i < org.length; i++){
             orgArray.push(org[i].oid)
           }
+
+          for(var i = 0; i < pptOid.length; i++){
+            pptOidArray.push(pptOid[i].oid)
+          }
+          for(var i = 0; i < pptOrg.length; i++){
+            pptOrgArray.push(pptOrg[i].oid)
+          }
+
           this.orgArray = orgArray
           this.oidArray = oidArray
+          this.pptArrayOid = pptOidArray
+          this.pptArrayOrg = pptOrgArray
         })
         .catch((err) => {
           console.error(err);
@@ -667,7 +692,7 @@ export default {
           "&role=" +
           this.role +
           "&templateid=" +
-          tid 
+          tid
         );
       this.addOp3('1', "", { type: "course_aiStageMode_createClick" }, "success")
     },
@@ -742,7 +767,7 @@ export default {
           "&role=" +
           this.role +
           "&templateid=" +
-          tid 
+          tid
         );
     },
     goToCourseTemplate2E(tid){
@@ -917,7 +942,7 @@ export default {
         _str = "course_aiEasyMode_open"
       }
       this.addOp3('1', "", { courseid: item.courseId, type: _str }, "success")
-      
+
        window.topU.postMessage({ cid: item.courseId, screenType: "3" }, "*");
     },
     getNT(cid) {
@@ -1498,6 +1523,35 @@ export default {
           console.error(err);
         });
     },
+    goToPptEasy(courseId){
+      if (courseId) {
+        this.$router.push(
+          "/pptEasy?cid=" +
+          courseId +
+          "&userid=" +
+          this.userid +
+          "&oid=" +
+          this.oid +
+          "&org=" +
+          this.org +
+          "&role=" +
+          this.role
+        );
+        this.addOp3('1', "", { courseid: courseId ,type: "course_pptEasyMode_edit" }, "success")
+      } else {
+        this.$router.push(
+          "/pptEasy?userid="+
+          this.userid +
+          "&oid=" +
+          this.oid +
+          "&org=" +
+          this.org +
+          "&role=" +
+          this.role
+        );
+        this.addOp3('1', "", { type: "course_pptEasyMode_createClick" }, "success")
+      }
+    },
   },
   created() {
     if (this.role == "1") {

+ 36 - 1
src/components/pages/data.vue

@@ -509,7 +509,7 @@ export default {
           }, 0);
         }, 0);
     },
-    setOpenId(openid) {
+    addOpenid(openid) {
       this.ajax.post(this.$store.state.api + "UpdateOpenId", [
         { userid: this.userid, openid: openid },
       ]).then((res) => {
@@ -519,7 +519,42 @@ export default {
       }).catch((err) => {
         this.$message.error("绑定失败请重新扫码");
         console.error(err);
+        	setTimeout(() => {
+						this.wechatDialogVisible = true;
+						this.wechatLogin();
+					}, 1000);
       })
+		},
+    setOpenId(openid) {
+      this.ajax
+      .post(this.$store.state.api + "selectliyuanOpenid", [
+        { pid: openid },
+      ])
+      .then((res) => {
+					if (!res.data[0].length) {
+						this.addOpenid(openid);
+					} else {
+						let uname = res.data[0].map(item => item.username).join(',');
+						console.log('uname',uname);
+						
+						this.$message.error("该微信已绑定" + uname + "账号");
+						this.wechatDialogVisible = false;
+					}
+				})
+				.catch((err) => {
+					console.log("err", err);
+				});
+
+      // this.ajax.post(this.$store.state.api + "UpdateOpenId", [
+      //   { userid: this.userid, openid: openid },
+      // ]).then((res) => {
+      //   this.$message.success("绑定成功");
+      //   this.wechatDialogVisible = false;
+      //   this.getDetail();
+      // }).catch((err) => {
+      //   this.$message.error("绑定失败请重新扫码");
+      //   console.error(err);
+      // })
     }
   },
   mounted() {

+ 216 - 0
src/components/pages/dialog/selectHtmlPageDialog.vue

@@ -0,0 +1,216 @@
+<template>
+	<div>
+		<el-dialog
+			:center="true"
+			:visible.sync="show"
+			:modal="true"
+			width="auto"
+			height="auto"
+      top="10vh"
+			:append-to-body="true"
+			class="dialog"
+		>
+			<div class="box">
+				<div class="b_head">
+					<span>选择主页面</span>
+					<svg
+						@click="close()"
+						t="1748587270371"
+						class="icon"
+						viewBox="0 0 1024 1024"
+						version="1.1"
+						xmlns="http://www.w3.org/2000/svg"
+						p-id="5023"
+						width="200"
+						height="200"
+					>
+						<path
+							d="M0 0h1024v1024H0z"
+							fill="#FF0033"
+							fill-opacity="0"
+							p-id="5024"
+						></path>
+						<path
+							d="M240.448 168l2.346667 2.154667 289.92 289.941333 279.253333-279.253333a42.666667 42.666667 0 0 1 62.506667 58.026666l-2.133334 2.346667-279.296 279.210667 279.274667 279.253333a42.666667 42.666667 0 0 1-58.005333 62.528l-2.346667-2.176-279.253333-279.253333-289.92 289.962666a42.666667 42.666667 0 0 1-62.506667-58.005333l2.154667-2.346667 289.941333-289.962666-289.92-289.92a42.666667 42.666667 0 0 1 57.984-62.506667z"
+							fill="#fff"
+							p-id="5025"
+						></path>
+					</svg>
+				</div>
+				<div class="b_main" v-loading="loading" v-if="data">
+          <el-table
+            :data="tableData"
+            style="width: 100%;"
+            border
+          >
+            <el-table-column label="文件名称" align="center" prop="fileName" />
+            <el-table-column label="操作" width="200" align="center">
+              <template slot-scope="scope">
+                <el-button type="primary" v-if="scope.row.isSelect!='1'" size="small" @click="select(scope.row)">选择</el-button>
+                <el-button v-if="scope.row.isSelect=='1'" size="small" @click="close()">已选</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+				</div>
+			</div>
+		</el-dialog>
+	</div>
+</template>
+
+<script>
+export default {
+	data() {
+		return {
+			loading: false,
+			show: false,
+			data: null,
+      tableData:[],
+		};
+	},
+	methods: {
+		open(data) {
+			this.data = JSON.parse(JSON.stringify(data));
+      let _levelOne = JSON.parse(JSON.stringify(this.data.filter(i=>i.fileName)));
+			// 筛选url为html文件的项
+			this.tableData = _levelOne.filter(item => {
+				return item.url && (item.url.endsWith('.html') || item.url.endsWith('.htm'));
+			});
+
+      if(this.tableData.length<=0){
+        this.$message.error("一级文件夹下未查询到页面文件")
+        return this.close()
+      }
+
+
+			this.loading = false;
+			this.show = true;
+		},
+		close() {
+			this.show = false;
+			this.init();
+		},
+		init() {
+			this.data = null;
+			this.loading = false;
+      this.tableData = [];
+		},
+    submit(){
+      this.$message.info("选择确定")
+    },
+    select(row){
+      this.data.forEach(i=>{if(i.isSelect)delete i.isSelect})
+      this.data.find(i=>i.url===row.url).isSelect = "1";
+      console.log("选择data",this.data)
+      this.$emit("success",this.data)
+    },
+	},
+};
+</script>
+
+<style scoped>
+.dialog >>> .el-dialog {
+	width: 600px !important;
+	border-radius: 8px;
+	padding: 0;
+	background-color: #fff;
+	overflow: hidden;
+}
+
+.dialog >>> .el-dialog__body {
+	width: 600px !important;
+  height: 500px;
+	height: auto;
+	flex-shrink: 0;
+	padding: 0;
+	box-sizing: border-box;
+	overflow: auto;
+}
+
+.dialog >>> .el-dialog__header {
+	display: none !important;
+}
+
+.box {
+	width: 600px;
+	height: 500px;
+	background: #fff;
+	border-radius: 15px;
+	box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05),
+		0px 16px 24px 2px rgba(0, 0, 0, 0.04), 0px 8px 10px -5px rgba(0, 0, 0, 0.08);
+
+}
+
+.b_head {
+	width: 100%;
+	height: 50px;
+	/* border-radius: 15px 15px 0 0; */
+	background: #1A1A1A;
+	display: flex;
+	align-items: center;
+	justify-content: space-between;
+	box-sizing: border-box;
+	padding: 0 20px;
+  color: #fff;
+}
+
+.b_head > span {
+	font-size: 18px;
+	font-weight: bold;
+	color: #fff;
+}
+
+.b_head > img {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_head > svg {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_main {
+	width: 100%;
+	height: calc(100% - 50px);
+	background: #fff;
+	padding: 20px 20px 20px 20px;
+	box-sizing: border-box;
+  overflow: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+}
+
+.b_bottom {
+	width: 100%;
+	height: 70px;
+	display: flex;
+	align-items: center;
+	justify-content: flex-end;
+	box-sizing: border-box;
+	padding: 0 20px;
+}
+
+.b_bottom>div{
+  padding: 10px 25px;
+  background: #fff;
+  color: #000;
+  border-radius: 4px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  border: solid 1px #EEEEEE;
+  margin-left: 15px;
+  cursor: pointer;
+  font-size: 16px;
+}
+
+.b_bottom>.b_b_submit{
+  background: #1A1A1A;
+  color: #D4D4D4;
+  border-color: #1A1A1A;
+}
+
+</style>

+ 360 - 35
src/components/pages/easy/addCourse.vue

@@ -66,6 +66,7 @@
                               class="binfo_input"
                               v-model="courseName"
                               style="border: 1.5px solid rgb(202, 209, 220);margin: 0px 10px 0px 0px;border-radius: 5px;font-weight: 600;padding: 12px 14px 12px 71px;"
+                              @change="saveCourse"
                             />
                             <!-- background: #f6f6f6; -->
                             <el-switch
@@ -516,6 +517,12 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                 </div>
                                 <div class="chapter_upload_n">
                                   <input
@@ -628,6 +635,23 @@
                                     readonly="true"
                                     @click="openUpdateSource(0, index1)"
                                   />
+
+                                  <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(0, index1)"
+                                  />
                                 </div>
                                 <div class="chapter_upload_ic">
                                   <div
@@ -703,6 +727,14 @@
                                   >
                                     <div></div>
                                   </div>
+
+                                  <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(0, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                   <div
                                     class="chapter_upload_ic_edit"
                                     v-if="item1.type == 14"
@@ -786,6 +818,12 @@
                               <input type="file" accept="*" style="display: none" v-if="inputShow" @change="beforeUpload2($event, unitIndex, 12, itemTaskIndex)
                                 " />
                             </button> -->
+                            <button
+                            class="c_pub_button_add pub_btn_add_img"
+                                @click="uploadZIPFile(0)"
+                          >
+                            代码上传
+                          </button>
                         </div>
                         <div
                           v-if="
@@ -1381,7 +1419,47 @@
                                     />
                                   </div>
                                 </div>
+
+                                <!--start ppt工具-->
+                                <!--<div
+                                  class="tool"
+                                  :class="{
+                                    isToolChoose: itemTool.tool.indexOf(73) != -1
+                                  }"
+                                  @click="addTools(73, itemTaskIndex, toolIndex)"
+                                  v-if="userid == '6c56ec0e-2c74-11ef-bee5-005056b86db5'"
+                                >
+                                  <div
+                                    class="whiteBIcon"
+                                    @click.stop="
+                                      openTools(itemTaskIndex, 73, toolIndex)
+                                    "
+                                  >
+                                    <img
+                                      src="../../../assets/icon/secondToolList/ppt.png"
+                                      alt
+                                    />
+                                    <div style="margin: 5px 0">PPT</div>
+                                  </div>
+                                  <div class="noCTool">
+                                    <img
+                                      src="../../../assets/icon/new/isToolC.png"
+                                      alt=""
+                                    />
+                                  </div>
+                                  <div
+                                    class="isCTool"
+                                    v-if="itemTool.tool.indexOf(73) != -1"
+                                  >
+                                    <img
+                                      src="../../../assets/icon/new/isToolC.png"
+                                      alt=""
+                                    />
+                                  </div>
+                                </div>-->
+                                <!--end PPT工具-->
                               </div>
+
                               <div
                                 class="toolSort"
                                 v-if="itemTool.toolType == 1"
@@ -3879,6 +3957,12 @@
                                   class="chapter_upload_l_i8"
                                   style="margin-left: 1px"
                                 ></div>
+
+                                <div
+                                  v-if="item1.type == 17"
+                                  class="chapter_upload_l_i8"
+                                  style="margin-left: 1px"
+                                ></div>
                               </div>
                               <div
                                 class="chapter_upload_ic"
@@ -8191,6 +8275,7 @@
     ></EnglishVoice>
     <appDialog ref="appDialog" @success="selectAppSuccess"></appDialog>
     <CodeEditor ref="CodeEditorRef" @success="addHtmlSuccess"></CodeEditor>
+    <selectHtmlPageDialog ref="selectHtmlPageDialogRef" @success="selectHtmlPageSuccess"/>
   </div>
 </template>
 
@@ -8211,15 +8296,18 @@ import englishRight from "./commpont/englishRight.vue";
 import EnglishVoice from "../EnglishVoice/index.vue";
 import appDialog from "../components/appDialog.vue";
 import { myMixin } from "@/mixins/mixin.js"
+import { uploadFileMixin } from "../../tools/uploadFileMixin.js";
 import CodeEditor from "../components/CodeEditor";
 var OpenCC = require("opencc-js");
 let converter = OpenCC.Converter({
   from: "hk",
   to: "cn"
 });
+import JSZip from 'jszip'
+import selectHtmlPageDialog from '../dialog/selectHtmlPageDialog.vue'
 
 export default {
-  mixins: [ myMixin ],
+  mixins: [ myMixin,uploadFileMixin],
   components: {
     CodeEditor,
     EditorBar,
@@ -8232,11 +8320,12 @@ export default {
     interVideo,
     englishRight,
     EnglishVoice,
-    appDialog
+    appDialog,
+    selectHtmlPageDialog
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       checkAll: false,
       chooseType: 1,
       checkedCities: [],
@@ -8492,7 +8581,8 @@ export default {
         "X",
         "Y",
         "Z"
-      ]
+      ],
+      changeId:""
     };
   },
   directives: {
@@ -10506,7 +10596,7 @@ export default {
         this.$forceUpdate();
       }
     },
-    addWork() {
+    addWork(gotype) {
       let cPan = 1;
       for (var i = 0; i < this.unitJson.length; i++) {
         for (
@@ -10587,21 +10677,27 @@ export default {
         .then(res => {
           console.log(this.steps);
           // if (this.steps != 1 && this.steps != 2 && this.steps != 3) {
-          this.$message({
-            message: "新增成功",
-            type: "success"
-          });
+          if(gotype !== 2){
+            this.$message({
+              message: "新增成功",
+              type: "success"
+            });
+          }
           // }
           this.number = res.data.ordernumber;
           this.courseId = res.data.courseId;
           this.cid = res.data.courseId;
           this.courseUserid = this.userid;
           this.islogin = true;
-          this.steps = 4;
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
+          if(gotype !== 2){
+            this.steps = 4;
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
+          }
         })
         .catch(err => {
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          if(gotype !== 2){
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          }
           this.$message.error("网络不佳");
           console.error(err);
         });
@@ -10609,7 +10705,7 @@ export default {
     goCourse() {
       window.topU.postMessage({ cid: this.courseId, type: "1" }, "*");
     },
-    updateWork2() {
+    updateWork2(gotype) {
       let _unitIndex = this.unitIndex;
       let cPan = 1;
       for (
@@ -10646,20 +10742,24 @@ export default {
       this.ajax
         .post(this.$store.state.api + "updateWorkNew4", params)
         .then(res => {
-          this.$message({
-            message: "修改成功",
-            type: "success"
-          });
-          this.courseId = this.cid;
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
+          if(gotype !== 2){
+            this.$message({
+              message: "修改成功",
+              type: "success"
+            });
+            this.courseId = this.cid;
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
+          }
         })
         .catch(err => {
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          if(gotype !== 2){
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          }
           this.$message.error("网络不佳");
           console.error(err);
         });
     },
-    updateWork() {
+    updateWork(gotype) {
       let cPan = 1;
       for (var i = 0; i < this.unitJson.length; i++) {
         for (
@@ -10739,25 +10839,32 @@ export default {
         .post(this.$store.state.api + "updateWorkNew2", params)
         .then(res => {
           // if (this.steps != 1 && this.steps != 2 && this.steps != 3) {
-          if (this.cidType == 1) {
-            this.$message({
-              message: "修改成功",
-              type: "success"
-            });
-          } else {
-            this.$message({
-              message: "新增成功",
-              type: "success"
-            });
+          if (gotype !== 2) {
+            if (this.cidType == 1) {
+              this.$message({
+                message: "修改成功",
+                type: "success"
+              });
+            } else {
+              this.$message({
+                message: "新增成功",
+                type: "success"
+              });
+            }
           }
           // }
           this.number = this.nbOrder;
           this.courseId = this.cid;
-          this.steps = 4;
+          if(gotype !== 2){
+            this.steps = 4;
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
+          }
           this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, "success")
         })
         .catch(err => {
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          if(gotype !== 2){
+            this.addOp3('1', "", { courseid: this.courseId ,type: "course_easyMode_clickUpload" }, err)
+          }
           this.$message.error("网络不佳");
           console.error(err);
         });
@@ -11504,6 +11611,24 @@ export default {
           toolIndex
         );
       }
+      // else if (i == 73){
+      //   if (!this.cid) {
+      //     this.$message.error(
+      //       "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+      //     );
+      //     return;
+      //   }
+      //   window.topU.postMessage(
+      //     {
+      //       tools: "73y",
+      //       cid: this.cid,
+      //       stage: this.unitIndex,
+      //       task: itemTaskIndex,
+      //       tool: toolIndex
+      //     },
+      //     "*"
+      //   );
+      // }
 
       if (
         this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
@@ -13781,6 +13906,17 @@ export default {
         this.isPasteTask = true;
       }
     },
+    saveCourse(){
+      if (this.cid == "" || this.cid == undefined) {
+        this.addWork(2);
+      } else {
+        if (this.userid != this.courseUserid && this.role != "1") {
+          this.updateWork2(2);
+        } else {
+          this.updateWork(2);
+        }
+      }
+    },
     searchImage() {
       var _this = this;
       _this.imageList = [];
@@ -13977,7 +14113,7 @@ export default {
       console.log('addHtmlSuccess',name,url,'type:',type,'unitIndex',unitIndex,'itemTaskIndex',itemTaskIndex,'index1',index1);
       if (type == 1) {
         this.unitJson[unitIndex].chapterInfo[0].taskJson[
-          itemTaskIndex 
+          itemTaskIndex
         ].chapterData.splice(index1,1,{
           name: Tname,
           url: url,
@@ -13985,7 +14121,7 @@ export default {
         })
       }else{
         this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
-          itemTaskIndex 
+          itemTaskIndex
         ].chapterData.push({
           name: Tname,
           url: url,
@@ -14039,6 +14175,195 @@ export default {
       }
       this.imgChange1(null, null, 8, this.lineCount);
       this.dialogVisible7 = false;
+    },
+    // zip压缩文件上传
+    uploadZIPFile(i){
+
+      this.lineCount = i;
+      // 只支持上传zip文件
+      let input = document.createElement('input');
+      input.type = 'file';
+      input.accept = '.zip';
+      input.style.display = 'none';
+      // 只允许上传一个文件
+      input.multiple = false;
+      input.onchange = async (e) => {
+        let file = e.target.files[0];
+        if (!file) return;
+        if (file.type !== 'application/zip' && !file.name.endsWith('.zip')) {
+          this.$message.error('只支持上传zip文件');
+          return;
+        }
+        try{
+          const zip = new JSZip();
+          const content = await zip.loadAsync(file);
+          let _fileStructure = this.buildFileStructure(file,content);
+          let _time = new Date().getTime();
+          let _resultList = await this.uploadZipFileFn(_fileStructure.files,`${_time}_${_fileStructure.folderName}`);
+          this.changeId = "";
+          this.$refs.selectHtmlPageDialogRef.open(_resultList);
+
+        }catch(e){
+          console.log(e)
+          this.$message.error("解析zip文件失败")
+        }
+
+      };
+      document.body.appendChild(input);
+      input.click();
+      setTimeout(() => {
+        document.body.removeChild(input);
+      }, 1000);
+    },
+    // 构建文件结构树
+    buildFileStructure(file,zip) {
+      const root = {
+        folderName: file.name.replace(/\.[^/.]+$/, ""), // 移除扩展名
+        files: []
+      };
+
+      // 遍历ZIP文件中的所有文件/文件夹
+      zip.forEach((relativePath, file) => {
+        if (file.dir) return; // 跳过目录
+
+        const parts = relativePath.split('/');
+        let currentLevel = root.files;
+
+        for (let i = 0; i < parts.length; i++) {
+          const part = parts[i];
+          const isLast = i === parts.length - 1;
+
+          if (isLast) {
+            // 添加文件
+            currentLevel.push({fileName:part,file:file});
+          } else {
+            // 查找或创建文件夹
+            let folder = currentLevel.find(item =>
+              typeof item === 'object' && item.folderName === part
+            );
+
+            if (!folder) {
+              folder = {
+                folderName: part,
+                files: []
+              };
+              currentLevel.push(folder);
+            }
+
+            currentLevel = folder.files;
+          }
+        }
+      });
+
+      return root;
+    },
+    //按路径上传文件
+    async uploadZipFileFn(fileList,path){
+      return new Promise(async (resolve)=>{
+        let _copyFileList = fileList;
+
+        let promise = [];
+        for(let i = 0; i < _copyFileList.length; i++){
+          if(_copyFileList[i].folderName){
+            let _path = `${path}/${_copyFileList[i].folderName}`;
+            promise.push(this.uploadZipFileFn(_copyFileList[i].files,_path).then(res=>{
+              _copyFileList[i].files = res;
+            }))
+          }else if(_copyFileList[i].fileName){
+            // 将 ZIP 条目转换为文件对象
+            const blob = await _copyFileList[i].file.async('blob');
+            // 根据文件名设置type
+            let type = 'text/html';
+            if (_copyFileList[i].fileName.endsWith('.js')) {
+              type = 'application/javascript';
+            } else if (_copyFileList[i].fileName.endsWith('.css')) {
+              type = 'text/css';
+            } else if (_copyFileList[i].fileName.endsWith('.json')) {
+              type = 'application/json';
+            } else if (_copyFileList[i].fileName.endsWith('.png')) {
+              type = 'image/png';
+            } else if (_copyFileList[i].fileName.endsWith('.jpg') || _copyFileList[i].fileName.endsWith('.jpeg')) {
+              type = 'image/jpeg';
+            } else if (_copyFileList[i].fileName.endsWith('.gif')) {
+              type = 'image/gif';
+            } else if (_copyFileList[i].fileName.endsWith('.svg')) {
+              type = 'image/svg+xml';
+            } else if (_copyFileList[i].fileName.endsWith('.html') || _copyFileList[i].fileName.endsWith('.htm')) {
+              type = 'text/html';
+            } else if (_copyFileList[i].fileName.endsWith('.txt')) {
+              type = 'text/plain';
+            } else if (_copyFileList[i].fileName.endsWith('.pdf')) {
+              type = 'application/pdf';
+            } else if (_copyFileList[i].fileName.endsWith('.mp3')) {
+              type = 'audio/mpeg';
+            } else if (_copyFileList[i].fileName.endsWith('.mp4')) {
+              type = 'video/mp4';
+            } else if (_copyFileList[i].fileName.endsWith('.zip')) {
+              type = 'application/zip';
+            } else if (_copyFileList[i].fileName.endsWith('.xml')) {
+              type = 'application/xml';
+            } else if (_copyFileList[i].fileName.endsWith('.csv')) {
+              type = 'text/csv';
+            } else if (_copyFileList[i].fileName.endsWith('.md')) {
+              type = 'text/markdown';
+            }
+            let _file = new File([blob], _copyFileList[i].fileName, {type: type, lastModified: new Date().getTime()});
+            promise.push(this.awsupload({file:_file,path:`${path}/${_copyFileList[i].fileName}`}).then(res=>{
+              delete _copyFileList[i].file;
+              _copyFileList[i].url = decodeURIComponent(res.Location);
+            }))
+          }
+        }
+        Promise.all(promise).then(res=>{
+          resolve(_copyFileList);
+        })
+      })
+    },
+    selectHtmlPageSuccess(data){
+      let _selectFile = data.find(i=>i.isSelect==="1");
+      if(!_selectFile){
+        this.changeId = "";
+        return this.$message.info("未选择主页面")
+      }
+
+      console.log("_selectFile",_selectFile)
+      let _index = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        0
+      ].chapterData.findIndex(i => i.type == 17 && i.id == this.changeId);
+      if (_index != -1) {
+        console.log("_index",_index)
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          0
+        ].chapterData[_index] = {
+          name: _selectFile.fileName,
+          title: _selectFile.fileName,
+          id:this.changeId,
+          url: _selectFile.url,
+          fileList:data,
+          type: 17
+        };
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          0
+        ].chapterData.push({
+          name: _selectFile.fileName,
+          title: _selectFile.fileName,
+          id:new Date().getTime(),
+          url: _selectFile.url,
+          fileList:data,
+          type: 17
+        });
+      }
+      this.changeId = "";
+      this.$forceUpdate();
+      this.$refs.selectHtmlPageDialogRef.close();
+    },
+    changeHTmlPage(itemTaskIndex,i){
+      let _data = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i];
+      this.changeId = _data.id;
+      this.$refs.selectHtmlPageDialogRef.open(_data.fileList);
     }
   },
   beforeDestroy() {

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

@@ -565,7 +565,7 @@ export default {
   },
   data() {
     return {
-        gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       data: {
         isLoading: false,
         meta: {

+ 11 - 4
src/components/pages/inviteLoginST/inviteLogin.vue

@@ -13,12 +13,12 @@
 							<div class="c-b-r-m-title">欢迎登录!</div>
 							<div class="c-b-r-m-smallTitle">请选择登录角色</div>
 							<div class="c-b-r-m-identity">
-								<div class="c-b-r-m-i-item" @click.stop="clickIdentity(0)">
+								<!-- <div class="c-b-r-m-i-item" @click.stop="clickIdentity(0)">
 									<div class="c-b-r-m-i-itemSvg">
 										<svg width="48" height="48" viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path d="M20.2969 5.57812C26.3288 5.57812 31.2188 10.468 31.2188 16.5C31.2188 20.3947 29.1802 23.8133 26.1118 25.7469V25.7464C29.8475 27.3133 32.8847 30.2153 34.6266 33.8555L41.5929 23.8744C42.0671 23.1951 43.0021 23.0288 43.6815 23.5028C44.354 23.9722 44.5238 24.8934 44.067 25.571L44.053 25.5914L36.0582 37.046C35.9913 37.1419 35.9136 37.2297 35.8264 37.3075C36.0935 38.485 36.2344 39.7104 36.2344 40.9688C36.2344 41.7972 35.5628 42.4688 34.7344 42.4688C33.9142 42.4688 33.2478 41.8105 33.2346 40.9936L33.2344 40.9688C33.2344 33.5129 27.1902 27.4688 19.7344 27.4688C12.3531 27.4688 6.35541 33.3926 6.2362 40.7455L6.23438 40.9688C6.23438 41.7972 5.5628 42.4688 4.73438 42.4688C3.90595 42.4688 3.23438 41.7972 3.23438 40.9688C3.23438 33.8485 7.74441 27.7817 14.0636 25.4691L14.0634 25.4695C11.2296 23.4965 9.375 20.2148 9.375 16.5C9.375 10.468 14.2649 5.57812 20.2969 5.57812ZM20.2969 8.57812C15.9218 8.57812 12.375 12.1249 12.375 16.5C12.375 20.8751 15.9218 24.4219 20.2969 24.4219C24.672 24.4219 28.2188 20.8751 28.2188 16.5C28.2188 12.1249 24.672 8.57812 20.2969 8.57812ZM43.2188 13.1719C44.0472 13.1719 44.7188 13.8435 44.7188 14.6719C44.7188 15.492 44.0605 16.1584 43.2436 16.1717L43.2188 16.1719H37.5938C36.7653 16.1719 36.0938 15.5003 36.0938 14.6719C36.0938 13.8518 36.752 13.1853 37.5689 13.1721L37.5938 13.1719H43.2188ZM43.2188 6.5625C44.0472 6.5625 44.7188 7.23408 44.7188 8.0625C44.7188 8.88263 44.0605 9.54905 43.2436 9.56231L43.2188 9.5625H33.6562C32.8278 9.5625 32.1562 8.89092 32.1562 8.0625C32.1562 7.24238 32.8145 6.57595 33.6314 6.56269L33.6562 6.5625H43.2188Z"></path></svg>
 									</div>
 									<span>教师</span>
-								</div>
+								</div> -->
 
 								<div class="c-b-r-m-i-item" @click.stop="clickIdentity(1)">
 									<div class="c-b-r-m-i-itemSvg">
@@ -74,6 +74,12 @@ export default {
 			},
 		},
 		mounted() {
+      this.$router.push({
+				name:"inviteLoginSZ",
+        query:{
+          code:this.code,
+        }
+			})
 			setInterval(() => {
 				 window.topU.postMessage({
 					tools:"getLogin"
@@ -91,6 +97,7 @@ export default {
 					}
 				}
 			})
+
 		},
 }
 </script>
@@ -161,7 +168,7 @@ export default {
 	top: -45px;
 	border-radius: 50%;
 	background-color: #3681FC;
-	
+
 }
 
 .c-b-r-ca-btn{
@@ -226,4 +233,4 @@ export default {
 	font-size: 18px;
 }
 
-</style>
+</style>

+ 58 - 8
src/components/pages/inviteLoginSZ/inviteLogin.vue

@@ -1,5 +1,8 @@
 <template>
     <div class="container" v-loading="loading">
+      <div class="loginOut" v-show="showLoadingOut">
+					<span @click="loginOut">退出登录</span>
+				</div>
         <!-- <div class="i_box" v-if="steps == 1">
             <div class="i_box_top">
                 <div><span>请输入随机码进入项目课程</span></div>
@@ -51,7 +54,7 @@
 							</div>
 
 							<div :class="['c-b-r-m-btn',btnActive?'c-b-r-m-btnActive':'']" @click.stop="nextSteps">下一步</div>
-						
+
 						</div>
 						<div class="c-b-r-main" v-if="steps == 2">
 							<div class="c-b-r-m-title">请选择您的姓名</div>
@@ -60,6 +63,7 @@
 								<div v-if="!classJuri.length" class="c-b-r-m-cna-none">此班级暂无学生</div>
 								<div v-for="item in classJuri" :class="['c-b-r-m-cna-item',chooseData.userid==item.userid?'c-b-r-m-cna-itemActive':'']" @click="choose(item.userid,(item.name ? item.name : item.username))" :key="item.userid">{{ item.name ? item.name :item.username }}</div>
 							</div>
+							<!--  -->
 							<el-button class="c-b-r-m-loginBtn" type="primary" v-if="classJuri.length" @click.stop="login(chooseData.userid,chooseData.username)">确认登录</el-button>
 						</div>
 					</div>
@@ -82,7 +86,8 @@ export default {
             courseId:"",
 						showErrMsg:false,
 						errMsg:"",
-						chooseData:{}
+						chooseData:{},
+            showLoadingOut:false,
         }
     },
 		computed:{
@@ -179,8 +184,32 @@ export default {
 				setErrMsg(msg){
 					this.showErrMsg = true;
 					this.errMsg = msg;
-				}
+				},
+        loginOut(){
+				 window.topU.postMessage({
+					tools:"logout"
+				},"*")
+			},
     },
+    mounted(){
+      setInterval(() => {
+				 window.topU.postMessage({
+					tools:"getLogin"
+				},"*")
+				console.log("获取getLogin")
+			}, 2000);
+			window.addEventListener("message",(e)=>{
+				let data = e.data;
+				console.log("message",e)
+				if(data.tools && data.tools=='getLogin'){
+					if(data.type===2){
+						this.showLoadingOut = false;
+					}else if(data.type===1){
+						this.showLoadingOut = true;
+					}
+				}
+			})
+    }
 }
 </script>
 
@@ -222,6 +251,7 @@ export default {
 	align-items: center;
 	background-color: white;
 	position: relative;
+  overflow-x:hidden ;
 }
 
 .c-b-r-closeArea{
@@ -232,7 +262,7 @@ export default {
 	top: -45px;
 	border-radius: 50%;
 	background-color: #3681FC;
-	
+
 }
 
 .c-b-r-ca-btn{
@@ -247,6 +277,7 @@ export default {
 .c-b-r-main{
 	width: 80%;
 	height: 80%;
+	overflow: auto;;
 }
 
 .c-b-r-m-title{
@@ -317,12 +348,13 @@ export default {
 
 .c-b-r-m-chooseNameArea{
 	width: 100%;
+	max-height: 70%;
 	height: auto;
-	max-height: 300px;
+	/* max-height: 300px; */
 	margin-top: 20px;
 	display: flex;
 	flex-wrap: wrap;
-
+  overflow: auto;
 }
 
 .c-b-r-m-cna-none{
@@ -350,7 +382,7 @@ export default {
   background-color: #E0EAFB;
 	color:#3681FC;
 	border-color: #3681FC;
-	
+
 }
 
 
@@ -457,4 +489,22 @@ export default {
     justify-content: center !important;
     margin: 0 !important;
 } */
-</style>
+
+.loginOut{
+	position: absolute;
+	right: 30px;
+	top: 30px;
+	width: auto;
+	height: auto;
+	display: flex;
+	justify-content: center;
+	align-items: center;
+}
+
+.loginOut>span{
+	font-size: 24px;
+	color: #fff;
+	font-weight: bold;
+	cursor: pointer;
+}
+</style>

+ 55 - 1
src/components/pages/library/fileBox.vue

@@ -49,6 +49,10 @@
                     <img :src="checkImg" alt="" v-if="checkArray.indexOf(item.id) == -1">
                     <img :src="checkIsImg" alt="" v-else>
                 </div>
+
+                <div class="copy_file_url" @click.stop="copyFileUrl(item.file)">
+                  <svg t="1755826807777" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="5640" width="200" height="200"><path d="M949.992727 74.472727l-4.096-4.096a241.850182 241.850182 0 0 0-340.992 0L387.537455 287.650909a241.943273 241.943273 0 0 0 0 341.085091l4.002909 4.002909c7.819636 7.726545 16.197818 14.801455 24.669091 21.410909l79.499636-79.592727c-9.309091-5.399273-18.059636-12.101818-25.972364-20.014546l-4.002909-3.909818a130.792727 130.792727 0 0 1 0-184.785454l217.460364-217.367273a130.606545 130.606545 0 0 1 184.599273 0l4.002909 4.002909a130.699636 130.699636 0 0 1 0 184.692364L773.585455 435.665455c17.035636 42.263273 25.134545 87.133091 24.296727 131.909818l152.110545-152.017455a241.757091 241.757091 0 0 0 0-340.992z m-321.163636 313.157818a238.685091 238.685091 0 0 0-24.762182-21.410909l-79.499636 79.499637c9.309091 5.585455 18.152727 12.101818 26.065454 20.107636l4.096 4.002909a130.699636 130.699636 0 0 1 0 184.692364L337.361455 871.889455a130.885818 130.885818 0 0 1-184.785455 0l-4.002909-4.096a130.699636 130.699636 0 0 1 0-184.692364l98.304-98.210909a336.989091 336.989091 0 0 1-24.389818-131.909818L70.376727 604.811636a241.943273 241.943273 0 0 0 0 341.178182l4.002909 4.096a242.036364 242.036364 0 0 0 341.085091 0L632.832 732.625455a242.036364 242.036364 0 0 0 0-341.085091l-4.002909-4.002909z" fill="#000" p-id="5641"></path></svg>
+                </div>
             </div>
         </div>
         <div class="f_box_file_list" v-else-if="stype == '2' && fileArray.length" v-loading.body="isLoading">
@@ -805,6 +809,41 @@ export default {
             }
             this.$emit('addFile', file)
             this.checkArray = []
+        },
+        copyFileUrl(url){
+        // 复制文件链接到剪切板
+        if (!url) {
+            this.$message.error('无效的文件链接');
+            return;
+        }
+        // 兼容不同浏览器
+        if (navigator && navigator.clipboard && window.isSecureContext) {
+            navigator.clipboard.writeText(url).then(() => {
+                this.$message.success('文件链接已复制到剪切板');
+            }).catch(() => {
+                this.$message.error('复制失败,请手动复制');
+            });
+        } else {
+            // 创建临时textarea
+            let textarea = document.createElement('textarea');
+            textarea.value = url;
+            textarea.style.position = 'fixed';
+            textarea.style.top = '-9999px';
+            document.body.appendChild(textarea);
+            textarea.focus();
+            textarea.select();
+            try {
+                let successful = document.execCommand('copy');
+                if (successful) {
+                    this.$message.success('文件链接已复制到剪切板');
+                } else {
+                    this.$message.error('复制失败,请手动复制');
+                }
+            } catch (err) {
+                this.$message.error('复制失败,请手动复制');
+            }
+            document.body.removeChild(textarea);
+        }
         }
     },
     mounted() {
@@ -1323,4 +1362,19 @@ export default {
     white-space: nowrap;
     text-overflow: ellipsis;
 }
-</style>
+
+.copy_file_url{
+  width:15px;
+  height:15px;
+  position: absolute;
+  right: 10px;
+  top: 10px;
+  cursor: pointer;
+}
+
+.copy_file_url>svg{
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+}
+</style>

+ 397 - 2
src/components/pages/liyuan/CourseCon.vue

@@ -4,19 +4,110 @@
     <div class="cardBox">
       <card v-for="item in cardArray" :key="item.title" :title="item.title" :icon="item.icon" :to="item.to" :type="item.type"></card>
     </div>
+    <div class="courseList" v-loading="isLoading">
+      <div class="courseListTit">精品课程</div>
+      <div class="courseListSearch">
+        <div style="display: flex;gap: 25px;">
+            <el-select v-for="(i,index) in typeList" clearable :key="index" v-model="i.typeE" @change="search" :placeholder="i.name">
+              <el-option :value="false" label="全部"></el-option>
+              <el-option
+                v-for="item in i.child"
+                :key="item.id"
+                :label="item.name"
+                :value="item.id">
+              </el-option>
+            </el-select>
+
+            <el-select v-model="groupA" clearable @change="search" v-if="role == '1'" placeholder="所有者">
+              <el-option value="4" label="全部"></el-option>
+              <el-option value="2" label="我的课程"></el-option>
+              <el-option value="3" label="协同课程"></el-option>
+              <el-option value="1" label="他人课程"></el-option>
+            </el-select>
+            <el-select v-model="groupA" clearable @change="search" v-else placeholder="所有者">
+              <el-option value="0" label="全部"></el-option>
+              <el-option value="2" label="我的课程"></el-option>
+              <el-option value="3" label="协同课程"></el-option>
+            </el-select>
+          
+        </div>
+        <div class="serachCon">
+          <el-input
+            placeholder="请输入关键字"
+            suffix-icon="el-icon-search"
+            @change="search"
+            v-model="courseName">
+          </el-input>
+        </div>
+      </div>
+      <div class="courseDataL">
+        <div class="Conblock" v-for="(i,index) in courseList" :key="index">
+          <div class="ConblockTit">
+              {{ i.title }}
+          </div>
+          <div style="display: flex;gap: 10px;color: #969BA3;font-size: 14px;">
+              <!-- <span v-if="i.state == 1">阶段模式</span>
+              <span v-if="i.state == 2">任务模式</span>
+              <span v-if="i.state == 3">极简模式</span>
+              <span v-if="i.state == 4 || i.state == 5">ai模式</span>
+              <span v-if="i.state == 6">上课模式</span> -->
+              <span>{{ i.uname }}</span>
+              <span>@{{ i.school }}</span>
+
+            </div>
+           <img class="PimgL" :src="i.cover != null && i.cover != ''
+              ? JSON.parse(i.cover).length > 0
+                ? JSON.parse(i.cover)[0].url
+                : mr
+              : mr
+              " alt />
+          <div class="foot">
+            <img style="cursor: pointer;"
+            v-if="i.userid == userid" 
+            @click="goToCourse(i.courseId)" 
+            src="../../../assets/icon/liyuan/courseEditC.svg" alt="">
+            <div class="ent" @click="entCourse(i)">进入</div>
+          </div>
+        </div>
+      </div>
+      <div class="moreL" @click="lookMore">
+        <div>查看更多</div>
+        <img style="margin-top: 1px;" src="../../../assets/icon/liyuan/arrow-up.svg" alt="">
+      </div>
+
+    </div>
   </div>
 </template>
 
 <script>
 import topBar from './components/topBar'
 import card from './components/card.vue';
+import { myMixin } from "@/mixins/mixin.js"
+
 export default {
+  mixins: [ myMixin ],
   components: {
     topBar,
     card
   },
   data() {
     return {
+      betaL:'beta',
+      typeList:[],
+      CourseType:[],
+      CourseTypeJson:[],
+      total:0,
+      isLoading:false,
+      mr: require("../../../assets/icon/kc1.png"),
+      groupA:'', //所有者
+      courseName:'',
+      courseList:[],
+      org:this.$route.query["org"],
+      oid:this.$route.query["oid"],
+      userid:this.$route.query["userid"],
+      role:this.$route.query["role"],
+      page:1,
+      pageSize:8,
       cardArray: [
         { title: '课程管理', icon: require('../../../assets/icon/liyuan/niandukaohe.svg'), type: 1, to: "/course" },
         { title: '课程中心', icon: require('../../../assets/icon/liyuan/gerendangan.svg'), type: 4, to: `/pbl-student-table/dist/#/index?userid=${this.$route.query.userid}&oid=${this.$route.query.oid}&org=${this.$route.query.org}&tType=${this.$route.query.tType}&cid=&screenType=3&gotype=1` },
@@ -27,15 +118,214 @@ export default {
       ]
     }
   },
+  methods:{
+    search() {
+      console.log('6666');
+      this.isLoading = true;
+      
+      this.page = 1;
+      this.getCourse();
+    },
+    lookMore(){
+
+        try {
+          window.topU.gotype = this.$route.path
+        } catch (error) {
+          console.log(error);
+        }
+        console.log('betaL',this.betaL);
+        sessionStorage.setItem('gotype', this.$route.path);
+        let to = `/pbl-student-table/dist/#/index?userid=${this.$route.query.userid}&oid=${this.$route.query.oid}&org=${this.$route.query.org}&role=${this.$route.query.role}&tType=${this.$route.query.tType}&cid=&screenType=3`
+        let con = this.betaL =='beta'? 'https://beta.pbl.cocorobo.cn' : 'https://pbl.cocorobo.cn'
+        console.log( `${con}${to}`);
+        window.location.href = `${con}${to}`;
+    },
+    selectAllType() {
+      let params = {
+        org: this.org && this.org != "" ? this.org : "",
+        oid: this.oid && this.oid != "" ? this.oid : "",
+        stand: "cn"
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectAllTypeStand", params)
+        .then((res) => {
+          
+          if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
+            res.data[0] = [...res.data[0], ...res.data[4]]
+          }
+          this.CourseType = res.data;
+          this.typeList = res.data[0]
+
+          for (var cti = 0; cti < res.data[0].length; cti++) {
+            if (res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86db5" || res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86ac5") {
+              res.data[0][cti].name = "年级";
+            } else if (res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86db5" || res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86ac5") {
+              res.data[0][cti].name = "学科";
+            } else if (res.data[0][cti].id == "34629bcc-d02f-11ec-8c78-005056b86db5") {
+              res.data[0][cti].name = "主题";
+            }
+          }
+
+
+          for (var i = 0; i < res.data[0].length; i++) {
+            // if (!this.cid) {
+            //   this.courseTypeId[res.data[0][i].id] = [];
+            // }
+            if (!this.CourseTypeJson[res.data[0][i].id]) {
+              this.CourseTypeJson[res.data[0][i].id] = [];
+            }
+            if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
+              if (res.data[0][i].name == "栏目") {
+                this.CourseType[0][i].name = "主题";
+              }
+            }
+            if (res.data[2].length == 0 && res.data[3].length == 0) {
+              for (var j = 0; j < res.data[1].length; j++) {
+                if (res.data[0][i].id == res.data[1][j].pid) {
+                  this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); // 去除公共分类
+                }
+              }
+            } else {
+              if (res.data[2].length > 0) {
+                for (var j = 0; j < res.data[2].length; j++) {
+                  if (res.data[0][i].id == res.data[2][j].pid) {
+                    this.CourseTypeJson[res.data[0][i].id].push(res.data[2][j]); // 去除公共分类
+                  }
+                }
+              }
+              if (res.data[3].length > 0) {
+                for (var j = 0; j < res.data[3].length; j++) {
+                  if (res.data[0][i].id == res.data[3][j].pid) {
+                    this.CourseTypeJson[res.data[0][i].id].push(res.data[3][j]); // 去除公共分类
+                  }
+                }
+              }
+            }
+          }
+          this.typeList.forEach(e=>{
+              e.child = this.CourseTypeJson[e.id]
+              e.typeE = ''
+          })
+          
+          console.log('typeList',this.typeList);
+
+          this.getCourse()
+          // console.log('CourseTypeJson',this.CourseTypeJson['34629bcc-d02f-11ec-8c78-005056b86db5']);
+          // console.log('CourseType',this.CourseType);
+
+
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+
+    getCourse() {
+      this.isLoading = true;
+      let params = {
+        type: this.groupA ? this.groupA : 4,
+        uid: this.userid,
+        oid: this.oid,
+        org: this.org,
+        typea: this.typeList.filter(e=> e.id == "34628934-d02f-11ec-8c78-005056b86db5")[0].typeE ? this.typeList.filter(e=> e.id == "34628934-d02f-11ec-8c78-005056b86db5")[0].typeE : '',
+        typeb: this.typeList.filter(e=> e.id == "34629bcc-d02f-11ec-8c78-005056b86db5")[0].typeE ? this.typeList.filter(e=> e.id == "34629bcc-d02f-11ec-8c78-005056b86db5")[0].typeE : '',
+        typec: "",
+        typed: this.typeList.filter(e=> e.id == "34629907-d02f-11ec-8c78-005056b86db5")[0].typeE ? this.typeList.filter(e=> e.id == "34629907-d02f-11ec-8c78-005056b86db5")[0].typeE : '',
+        typeE: '',
+        cu: "",
+        cn: this.courseName,
+        page: this.page,
+        pageSize: this.pageSize,
+      };
+      console.log('params',params);
+      
+      this.ajax
+        .get(this.$store.state.api + "selectCourseNew2Liyuan", params)
+        .then((res) => {
+          // this.loading.close();
+          // this.loading = "";
+          this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
+          this.courseList = res.data[0];
+          this.isLoading = false;
+        })
+        .catch((err) => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+
+    entCourse(item) {
+      let _str = ""
+      if(item.state == 1){
+        _str = "course_stageMode_open"
+      }if(item.state == 2){
+        _str = "course_taskMode_open"
+      }if(item.state == 3){
+        _str = "course_easyMode_open"
+      }if(item.state == 5){
+        _str = "course_aiMode_open"
+      }if(item.state == 6){
+        _str = "course_aiEasyMode_open"
+      }
+      this.addOp3('1', "", { courseid: item.courseId, type: _str }, "success")
+      
+       window.topU.postMessage({ cid: item.courseId, screenType: "3" }, "*");
+    },
+    goToCourse(courseId) {
+        try {
+          window.topU.gotype = 'backCourseCon'
+        } catch (error) {
+          console.log(error);
+        }
+        // sessionStorage.setItem('gotype', 'backCourseCon');
+
+        this.goToCourse4(courseId)
+    },
+    goToCourse4(courseId) {
+      if (courseId) {
+        this.$router.push(
+          "/newAddCourse?cid=" +
+          courseId +
+          "&userid=" +
+          this.userid +
+          "&oid=" +
+          this.oid +
+          "&org=" +
+          this.org +
+          "&role=" +
+          this.role
+        );
+        this.addOp3('1', "", { courseid: courseId ,type: "course_stageMode_edit" }, "success")
+      } else {
+        this.$router.push(
+          "/newAddCourse?userid=" +
+          this.userid +
+          "&oid=" +
+          this.oid +
+          "&org=" +
+          this.org +
+          "&role=" +
+          this.role
+        );
+        this.addOp3('1', "", { type: "course_stageMode_createClick" }, "success")
+      }
+      // this.$router.push(path);
+    },
+  },
+  mounted(){
+    this.betaL = window.location.href.includes("beta") ? "beta" : "cloud"
+    this.selectAllType()
+  }
 }
 </script>
 
 <style scoped>
 .teacherDevelop{
+  display: flex;
+  flex-direction: column;
   width: 100%;
-  height: 100%;
+  min-height: 100%;
   padding: 40px 90px;
-
   box-sizing: border-box;
   background: #FAFAFA;
 
@@ -48,4 +338,109 @@ export default {
   width: 100%;
   margin-top: 20px;
 }
+.courseList{
+  flex: 1;
+  margin-top: 30px;
+  display: flex;
+  flex-direction: column;
+  gap: 30px;
+}
+.courseListTit{
+  font-family: PingFang SC;
+  font-weight: 600;
+  font-style: Semibold;
+  font-size: 20px;
+  line-height: 100%;
+  letter-spacing: 10%;
+}
+.courseListSearch{
+  display: flex;
+  justify-content: space-between;
+}
+.courseListSearch >>> .el-select .el-input__inner{
+  border-radius: 20px;
+  height: 40px;
+  width: 110px;
+  /* border: 1px solid #969BA3 !important; */
+  color: #606266;
+}
+.courseListSearch>>> .el-input__inner::-webkit-input-placeholder {
+  color: #606266 !important;
+}
+/* .courseListSearch >>> .el-input__placeholder{
+  color: #606266 !important;
+} */
+.courseListSearch >>> .el-input__icon{
+  line-height: 40px;
+}
+.serachCon >>> .el-input__inner{
+  height: 40px !important;
+  border-radius: 20px !important;
+  width: 300px !important;
+  border: none;
+  background: #E7E7E7;
+}
+.courseDataL{
+  display: grid;
+  grid-template-columns: repeat(4, 1fr);  
+  gap: 20px;
+}
+.Conblock{
+  display: flex;
+  flex-direction: column;
+  gap: 15px;
+  background: #fff;
+  border-radius: 12px;
+  padding: 14px 16px;
+  box-sizing: border-box;
+  box-shadow: 0px 4px 10px 0px #0000001A;
+
+}
+.PimgL{
+  width: 100%;
+  height: 126px;
+  border-radius: 10px;
+  object-fit: cover;
+}
+.ConblockTit{
+  font-size: 18px;
+  -webkit-line-clamp: 1;
+  display: -webkit-box;
+  -webkit-box-orient: vertical;
+  overflow: hidden;
+  text-overflow: ellipsis; 
+}
+.foot{
+  display: flex;
+  justify-content: flex-end;
+  align-items: center;
+  gap: 10px;
+}
+.foot > .ent{
+  border: 1px solid #bcbcbc;
+  color: #606266;
+  opacity: 1;
+  gap: 10px;
+  cursor: pointer;
+  border-radius: 20px;
+  padding-top: 4px;
+  padding-right: 20px;
+  padding-bottom: 4px;
+  padding-left: 20px;
+  border-width: 1px;
+}
+.ent:hover{
+    border: 1px solid #4080FF;
+    background: #4080FF;
+    color: #fff;
+}
+.moreL{
+  font-family: PingFang HK;
+  font-size: 16px;
+  cursor: pointer;
+  display: flex;
+  align-items: center;
+  color: #969BA3;
+  justify-content: flex-end;
+}
 </style>

+ 13 - 4
src/components/pages/liyuan/aiOffice.vue

@@ -2,7 +2,14 @@
   <div class="teacherDevelop">
     <topBar title="智能教务" detail="日常资料收集 · AI智能分析 · 会议智能转录 · 平台账号管理"></topBar>
     <div class="cardBox">
-      <card v-for="item in cardData(cardArray)" :key="item.title" :title="item.title" :icon="item.icon" :to="item.to" :type="item.type"></card>
+      <card v-for="item in cardData(cardArray)"
+      :key="item.title"
+      :title="item.title"
+      :icon="item.icon"
+      :to="item.to"
+      :sortId="item.sortId"
+      :type="item.type"
+      :cardData="item"></card>
     </div>
   </div>
 </template>
@@ -19,11 +26,13 @@ export default {
     return {
       role: this.$route.query.role,
       cardArray: [
-        { title: '资料收集', icon: require('../../../assets/icon/liyuan/zlsj.svg'), type: 1, to: "/teadTest",role:0 },
+        { title: '资料收集', icon: require('../../../assets/icon/liyuan/zlsj.svg'), type: 1, to: "/teadTest",role:0,sortId:'cd006687-8a00-11f0-9c7b-005056924926'},
         { title: '会议妙记', icon: require('../../../assets/icon/liyuan/hymj.svg'), type: 2, to: `/aigpt/#/cocoFlowConferenceTrick?userid=${this.$route.query.userid}&oid=${this.$route.query.oid}&role=${this.$route.query.role}&tType=${this.$route.query.tType}&org=${this.$route.query.org}&gotype=1`,role:0 },
         { title: '教师管理', icon: require('../../../assets/icon/liyuan/teamange.svg'), type: 1, to: "/teacher",role:1 },
         { title: '学生管理', icon: require('../../../assets/icon/liyuan/stumange.svg'), type: 1, to: "/Listudent",role:0 },
-        { title: '办公表单', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/test",role:1 },
+        { title: '办公表单', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/sassPlatform",role:1,sassPlatFormTypeId:"cd006687-8a00-11f0-9c7b-005056924926"},
+        { title: '教研室管理', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/teacherOffice",role:1 },
+        { title: '数据看板', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 5, to: `https://liyuan.cocorobo.cn/#/dataBoardNew?userid=${this.$route.query.userid}&oid=${this.$route.query.oid}&org=${this.$route.query.org}&role=${this.$route.query.role}&tType=${this.$route.query.tType}&gotype=aiOffice`,role:1 },
       ]
     }
   },
@@ -55,4 +64,4 @@ export default {
   width: 100%;
   margin-top: 20px;
 }
-</style>
+</style>

+ 18 - 6
src/components/pages/liyuan/components/backPage.vue

@@ -1,7 +1,9 @@
 <template>
-    <div class="pgb" @click="backO">
-        <img src="../../../../assets/icon/liyuan/backPage.svg" alt="">
-        <div>{{ tit }}</div>
+    <div class="pgb">
+        <div @click="backO" class="pgbL">
+            <img src="../../../../assets/icon/liyuan/backPage.svg" alt="">
+            <div>{{ tit }}</div>
+        </div>
     </div>
 </template>
 
@@ -21,8 +23,14 @@
         },
         methods:{
             backO(){
-                this.$router.push({ path: sessionStorage.getItem('gotype'), query: { userid: this.userid, oid: this.oid, org: this.org, role: this.role, gotype: 1,tType:this.tType } })
-                sessionStorage.removeItem('gotype');
+                // sessionStorage.removeItem('gotype');
+                try {
+                    this.$router.push({ path: (window.topU && window.topU.gotype) ?  window.topU.gotype : '', query: { userid: this.userid, oid: this.oid, org: this.org, role: this.role, gotype: 1,tType:this.tType } })
+                    window.topU.gotype = '' 
+                } catch (error) {
+                    this.$router.go(-1)
+                    console.log(error);
+                }
             }
         },
         mounted(){
@@ -38,9 +46,13 @@
     font-size: 20px;
     display: flex;align-items: center;
     gap: 10px;
-    cursor: pointer;
     padding:40px 90px 0;
     /* height: 23.8px; */
     margin-bottom: 15px;
 }
+.pgbL{
+    display: flex;align-items: center;
+    gap: 10px;
+    cursor: pointer;
+}
 </style>

+ 49 - 12
src/components/pages/liyuan/components/card.vue

@@ -22,6 +22,15 @@ export default {
         type: {
             type: Number,
         },
+        sortId: {
+            type: String,
+        },
+        cardData:{
+            type:Object,
+            default:()=>{
+                return {}
+            }
+        },
     },
     data() {
         return {
@@ -35,29 +44,57 @@ export default {
     },
     methods: {
         goTo() {
-            sessionStorage.setItem('gotype', this.$route.path);
+            try {
+                window.topU.gotype = this.$route.path
+                console.log('top',this.$route.path);
+            } catch (error) {
+                console.log(error);
+            }
+            // sessionStorage.setItem('gotype', this.$route.path);
+            console.log('betaL',this.betaL);
 
+            // teachaer 端
             if (this.type == 1) {
-                this.$router.push({ path: this.to, query: { userid: this.userid, oid: this.oid, org: this.org, role: this.role,tType: this.tType, gotype: 1 } })
-            }else if (this.type == 2) {
+              let query = {
+                userid: this.userid,
+                oid: this.oid,
+                org: this.org,
+                role: this.role,
+                tType: this.tType,
+                gotype: 1,
+                sortId: this.sortId,
+              }
+              if(this.cardData && this.cardData.sassPlatFormTypeId){
+                query.sassPlatFormTypeId = this.cardData.sassPlatFormTypeId
+              }
+                console.log('query',query);
+                console.log('cardData',this.cardData);
+                this.$router.push({ path: this.to, query: query })
+            }else if (this.type == 2) { 
                 let con = this.betaL =='beta'? 'https://beta.cloud.cocorobo.cn' : 'https://cloud.cocorobo.cn'
                 console.log( `${con}${this.to}`);
                 window.location.href = `${con}${this.to}`;
-                
-            }else if (this.type == 4) {
-                let con = this.betaL =='beta'? 'https://beta.pbl.cocorobo.cn' : 'https://pbl.cocorobo.cn'
-                console.log( `${con}${this.to}`);
-                 window.location.href = `${con}${this.to}`;
-            }else {
+            }else if (this.type == 3) {
+                // cocoFlow 页面
                 let con = this.betaL =='beta'? '//beta.app.cocorobo.cn/#/' : '//app.cocorobo.cn/#/'
-                console.log( `${con}${this.to}`);
+                window.location.href = `${con}${this.to}`;
+            }else if (this.type == 4) { 
+                //学生端
+                // 本地存储gotype
+                sessionStorage.setItem('gotype', this.$route.path);
 
+                let con = this.betaL =='beta'? 'https://beta.pbl.cocorobo.cn' : 'https://pbl.cocorobo.cn'
+                console.log( `${con}${this.to}`);
                 window.location.href = `${con}${this.to}`;
+            }else if (this.type == 5) {
+                // console.log( `${con}${this.to}`);
+                // 直接传的地址不用区分beta与正式
+                window.location.href = `${this.to}`;
             }
         }
     },
     mounted(){
-        // this.betaL = window.location.href.includes("beta") ? "beta" : "cloud"
+        this.betaL = window.location.href.includes("beta") ? "beta" : "cloud"
     }
 }
 </script>
@@ -92,4 +129,4 @@ export default {
     margin-bottom: -20px;
     margin-right: -20px;
 }
-</style>
+</style>

+ 87 - 28
src/components/pages/liyuan/page/examine/index.vue

@@ -61,6 +61,14 @@
           @click="Submit"
           >提交</el-button
         >
+
+        <el-button
+          v-if="allData.type != 2"
+          type="primary"
+          size="mini"
+          @click="saveBtn"
+          >保存</el-button
+        >
       </div>
     </div>
     <div style="flex: 1;overflow: hidden;" class="notes">
@@ -158,13 +166,13 @@
                         class="orgData"
                       >
                         <div @click="lookPrize(item2.courseId)">
-                          {{ item2.title }}:{{ item2.num }}份
+                          <!-- {{ item2.title }} -->
+                          查看:{{ item2.num }}份
                         </div>
                         <div
-                          style="color: black;"
                           @click="goFillIn(item2.courseId)"
                         >
-                          填写
+                          填写
                         </div>
                       </div>
                     </div>
@@ -181,7 +189,12 @@
           </div>
         </div>
       </div>
+      <div class="brief" v-if="brief">
+      <span v-html="brief" style="white-space: pre-wrap;word-break: break-all;"></span>
     </div>
+    </div>
+
+
 
     <!-- 点击数据来源 -->
     <el-dialog
@@ -224,7 +237,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       pType: 2,
       allData: {
         type: 1,
@@ -248,6 +261,7 @@ export default {
       timeA:"",
       timeB:"",
       testExamineBaseList:[],
+      brief:"",
     };
   },
   watch: {
@@ -262,16 +276,17 @@ export default {
     }
   },
   computed: {},
-  activated() {
-    // 当组件被激活时调用
-    this.getPageBase();
-    this.getPageBase2(1)
-    this.getPageBase2(2)
-  },
+  // activated() {
+  //   // 当组件被激活时调用
+  //   this.getPageBase();
+  //   this.getPageBase2(1)
+  //   this.getPageBase2(2)
+  // },
   mounted() {
-    this.getPageBase();
+    // this.getPageBase();
     this.getPageBase2(1)
     this.getPageBase2(2)
+
     // console.log(JSON.stringify(this.TeaTabJson));
   },
   methods: {
@@ -399,8 +414,6 @@ export default {
         .post(this.$store.state.api + "addTestExamineWorks2", params)
         .then(res => {
           console.log("addTestExamineWorks2", res);
-          // this.getData();
-          // this.handleData();
         })
         .catch(error => {
           console.log(error);
@@ -421,10 +434,12 @@ export default {
       this.ajax
         .get(this.$store.state.api + "getTestExamineByUserId2", params)
         .then(res => {
-          console.log("getTestExamineByUserId", res);
+          // console.log("getTestExamineByUserId", res);
 
           if (res.data[0].length > 0) {
+
             this.allData = res.data[0][0];
+
             let val = JSON.parse(res.data[0][0].json);
 
             this.PageBaseData.forEach(e => {
@@ -452,12 +467,6 @@ export default {
             this.handleData();
             this.tabLoad = false;
           }
-          // this.$forceUpdate();
-          //  else {
-          //   this.allData.type = 1;
-          //   this.getPageBase();
-          //   this.tabLoad = false;
-          // }
         })
         .catch(error => {
           console.log(error);
@@ -477,13 +486,13 @@ export default {
           // console.log("resresresres", res.data[0]);
           // this.allData = res.data[0][0];
           let testExamineBaseList = res.data[0];
+          console.log("res.data[0][0]", res.data[0][0]);
+          this.brief = res.data[0][0].brief;
           this.testExamineBaseList = testExamineBaseList;
           console.log("selectTestExamineBase", res.data[0][0]);
           this.PageBaseData = JSON.parse(res.data[0][0].json);
           // 先获取基础模板,然后再获取用户又没有填写过,填写过就开始循环赋值给基础模板,最后提交基础模板
           this.getData();
-
-          // this.handleData();
         })
         .catch(error => {
           console.log(error);
@@ -533,9 +542,19 @@ export default {
           testId: val.join(",")
         }
       ];
+
+      let _url = "selectExamineTestName"
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        params[0].startTime = timeValue[0];
+        params[0].endTime = timeValue[1];
+        _url = `selectExamineTestNameFilterTime`
+      }
+
+
       return new Promise(resolve => {
         this.ajax
-          .post(this.$store.state.api + "selectExamineTestName", params)
+          .post(this.$store.state.api + _url, params)
           .then(res => {
             resolve(res.data[0]);
           })
@@ -547,7 +566,12 @@ export default {
     // 查看数据来源
     lookPrize(val) {
       // return;
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}`;
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}&timeLimit=${timeValue}`;
+      }else{
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}`;
+      }
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -555,6 +579,41 @@ export default {
     handleClose(done) {
       this.getPageBase();
       done();
+    },
+    //保存按钮
+    saveBtn(){
+      this.$forceUpdate();
+      let PageBaseDataCopy = JSON.parse(JSON.stringify(this.PageBaseData));
+
+      for (const e of PageBaseDataCopy) {
+        for (const k of e.children) {
+          if (k.testid.test.length > 0) {
+            k.testid.test = k.testid.test.map(item => item.courseId);
+          }
+        }
+      }
+
+      let params = [
+        {
+          uid: this.userid,
+          oid: this.oid,
+          org: this.org,
+          type: this.pType,
+          json: JSON.stringify(PageBaseDataCopy),
+          ttype: 1,
+          tid:this.testExamineBaseList[0].id
+        }
+      ];
+      // return console.log(params);
+      this.ajax
+        .post(this.$store.state.api + "addTestExamineWorks2", params)
+        .then(res => {
+          console.log("addTestExamineWorks2", res);
+          this.$message.success("保存成功")
+        })
+        .catch(error => {
+          console.log(error);
+        });
     }
   }
 };
@@ -564,7 +623,7 @@ export default {
 .testPersonExamine {
   width: 100%;
   min-width: calc(100px * 10);
-  height: 100%;
+  height: calc(100%);
   /* overflow-x: scroll; */
   /* overflow: auto; */
   display: flex;
@@ -573,7 +632,7 @@ export default {
   box-sizing: border-box;
   background-color: #fff;
 	/* margin: 10px 0; */
-	border-radius: 5px;
+	/* border-radius: 5px; */
 }
 /* .tArea { */
   /* box-sizing: border-box; */
@@ -681,9 +740,9 @@ export default {
   width: 100%;
   min-width: 1300px;
   margin: 0 auto;
-  height: 100%;
+  height: auto;
   box-sizing: border-box;
-  padding-bottom: 60px;
+  padding-bottom: 10px;
   font-size: 14px;
 }
 

+ 1 - 1
src/components/pages/liyuan/page/portrait/index.vue

@@ -228,7 +228,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       teachingActivityNum: 0,
       teachingAndResearchActivitiesNum: 0,
       trainingActivityNum: 0,

+ 1 - 1
src/components/pages/liyuan/page/student.vue

@@ -229,7 +229,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       tableHeight: "500px",
       isLoading: false,
       formLabelWidth: "100px",

+ 127 - 74
src/components/pages/liyuan/page/teadTest.vue

@@ -1,20 +1,15 @@
 <template>
     <div class="i_body_box">
-        <backPage tit="资料搜集"></backPage>
+        <backPage tit="考核资料"></backPage>
         <div class="check_nav">
-            <!-- <div class="nav all" v-show="this.ExamineBase.length > 0" :class="{ active: type == '1' }" @click="checkType('1')">
-                年度考核
-            </div> -->
-            <div class="nav all" :class="{ active: checkTypeValue == typeListStr }" 
+            <div class="nav all" :class="{ active: checkTypeValue == typeListStr }"
             @click="changeShowType(typeListStr)">
                 全部
             </div>
-            <div class="nav" v-for="item in typeList" :key="item.id" :class="{ active: checkTypeValue == item.id,all:['8bfa67ce-e82a-11ef-b508-005056924926','9d3289d2-e82a-11ef-b508-005056924926','a824c728-e82a-11ef-b508-005056924926','8085418b-e82a-11ef-b508-005056924926'].includes(item.id)}" 
+            <div class="nav" v-for="item in typeList" :key="item.id" :class="{ active: checkTypeValue == item.id,all:['8bfa67ce-e82a-11ef-b508-005056924926','9d3289d2-e82a-11ef-b508-005056924926','a824c728-e82a-11ef-b508-005056924926','8085418b-e82a-11ef-b508-005056924926'].includes(item.id)}"
             @click="changeShowType(item.id,item)">{{ item.name }}</div>
-           
         </div>
         <div class="check_box" v-loading="loading">
-            <!-- <examine v-if="type==1"></examine> -->
             <div class="noneData"  v-if="!worksArray.length && type!=1" style="text-align: center; margin-top: 20px;">
                 暂无数据
             </div>
@@ -28,7 +23,10 @@
                             </el-tooltip>
                         </div>
                         <div class="state">
-                            <span :class="{ is: item.array.length > 0, no: !item.array.length }">{{ item.array.length > 0 ? "已完成" : "未完成" }}</span>
+                            <span :class="{ is: isOK(item.array) == '已完成', no: isOK(item.array) == '待办' }">
+                                {{ isOK(item.array) }}
+                                <!-- {{ item.array.length > 0 ? "已完成" : "未完成" }} -->
+                            </span>
                         </div>
                         <div class="time">
                             <span v-if="item.overtime" :class="{isDead: isDeadlinePassed(item.overtime)}">截止时间:{{ item.overtime }}</span>
@@ -53,37 +51,31 @@
                             v-if="item.array">
                             <div class="test" v-for="(test, index) in item.array" :key="test.id">
                                 <div class="time">
-                                    <span>提交记录{{item.array.length - index}}</span>
+                                    <span v-if="!test.editName && !test.name">提交记录{{item.array.length - index}}</span>
+                                    <span v-if="!test.editName && test.name">{{test.name}}</span>
+                                    <el-input :ref="`changeName_${test.id}`" v-if="test.editName" v-model="test.name"  @blur="changeNameUpdate(test.courseid,test.id)" @keyup.enter.native="changeNameUpdate(test.courseid,test.id)"></el-input>
+                                </div>
+                                <div class="testType">
+                                    <span :class="`typeStatus_${test.type}`">{{ typeStatusList[test.type] }}</span>
                                 </div>
-                                <!-- <img @click="deleteTest(test.id)" class="delete"
-                                    src="../../../../assets/icon/test/delete.png" alt="" /> -->
                                 <div class="utime">
                                     <span>{{ test.utime }}</span>
                                 </div>
                                 <div class="mask">
-                                    <div @click="doTest(test.courseid, test.id)">
+                                    <div @click="doTest(test.courseid, test.id)"  v-if="test.isReview != 1">
                                         <span>编辑</span>
                                     </div>
-                                    <div @click="deleteTest(test.id)" class="delete">
+                                    <div @click="deleteTest(test.id)" class="delete"  v-if="test.isReview != 1">
                                         <span>删除</span>
                                     </div>
-                                    <!-- <div @click="checkTest(test.courseid, test.id)">
-                                        <span></span><span>查看</span>
+                                    <div @click="changeName(test.courseid,test.id)" v-if="test.isReview != 1">
+                                        <span>重命名</span>
                                     </div>
-                                    <div @click="copyTest(test.id)">
-                                        <span></span><span>复制</span>
-                                    </div> -->
                                 </div>
                             </div>
                         </div>
                         <div class="test_add_box"
                             v-else-if="item.carray" v-loading="!item.carray.length">
-                            <!-- <div class="courseLength" v-for="(course, index) in item.carray" :key="index" @click="doTest3(item, course)">
-                                <span class="finish" :class="{is: course.array.length}"></span>
-                                <span>{{ index+1 }}、</span>
-                                <span>{{ course.title }}</span>
-                                <span>{{ course.username }}</span>
-                            </div> -->
                             <div class="test courseLength" v-for="(course, index) in item.carray" :key="index">
                                 <div class="time">
                                     <el-tooltip :content="course.title+'-'+course.username" placement="top" effect="dark">
@@ -109,7 +101,7 @@
                     </div>
                 </div>
             </template>
-            
+
         </div>
     </div>
 </template>
@@ -117,7 +109,7 @@
 <script>
 import backPage from '../components/backPage.vue'
 export default {
-    
+
     components:{
         backPage
     },
@@ -125,8 +117,8 @@ export default {
         return {
             userid: this.$route.query.userid,
             oid: this.$route.query.oid,
+            sortId: this.$route.query.sortId,
             type: "",
-            typeId:'e18d88b3-e828-11ef-b508-005056924926',
             typeList:[],
             ExamineBase: [],
             typeArray: [],
@@ -135,10 +127,30 @@ export default {
             org: this.$route.query.org,
             role: this.$route.query.role,
             loading: false,
-            checkTypeValue:""
+            checkTypeValue:"",
+            typeStatusList:["","未提交","已提交","","已退回"]
         };
     },
     computed: {
+        isOK(){
+            return function (array) {
+                // console.log('array',array);
+                let result = ''
+                if (array.length > 0) {
+                    let k = array.filter(e => e.type == 1 || e.type == 4)
+                   if (k.length) {
+                        result = '待办'
+                   }else{
+                        result = '已完成'
+                   }
+
+                }else{
+                    result = '待办'
+                }
+
+                return result;
+            };
+        },
         getNum() {
             return function (array) {
                 let _array = JSON.parse(array);
@@ -269,40 +281,36 @@ export default {
 
           if(this.typeList.length){
             _result = this.typeList.map(i=>i.id)
-            _result.push(this.typeId);
+            _result.push(this.sortId);
             _result = _result.join(',')
           }
 
           return _result;
         }
     },
-    watch:{
-      typeId(newValue){
-        this.changeShowType(newValue)
-      }
-    },
     methods: {
         getNavType() {
+            let _this = this
             let params = {
                 oid: "",//this.oid
             };
+            let inte = (['eefb7195-8ee7-11f0-9c7b-005056924926','cd006687-8a00-11f0-9c7b-005056924926'].includes(this.sortId)) ? 'selectTestType_liYuan' : 'selectTestType'
             this.ajax
-                .get(this.$store.state.api + "selectTestType", params)
+                .get(this.$store.state.api + inte, params)
                 .then(res => {
                     let _data = res.data[0];
                     console.log('_data',_data);
-                    // _data.fliter(e=>{
+                    console.log('_this.sortId',_this.sortId);
 
-                    // })
                     this.typeList = _data.filter(function(item, index) {
-                        return item.pid == 'e18d88b3-e828-11ef-b508-005056924926';
+                        return item.pid == _this.sortId;
                     });
+
                     this.changeShowType(this.typeListStr)
 
-                    //  = _data.fliter(e =>{ return e.pid == 'e18d88b3-e828-11ef-b508-005056924926'})
                     console.log('this.typeList',this.typeList);
 
-                    
+
                 })
                 .catch(err => {
                     console.log(err);
@@ -321,7 +329,6 @@ export default {
                 if(type == 1 && !res.data[0].length){
                     this.getPageBase(2)
                 }
-                // console.log("selectTestExamineBase", res.data);
                 })
                 .catch(error => {
                 console.log(error);
@@ -346,11 +353,6 @@ export default {
                     this.typeArray = res.data[0];
                     if(type == 1){
                         this.type = ''
-                        // if (this.typeArray.length) {
-                        //     this.type = this.typeArray[0].id;
-                        // } else {
-                        //     this.type = '0';
-                        // }
                     }
                     this.getWorks()
                 })
@@ -678,49 +680,67 @@ export default {
             return res.data[0]
         },
         changeShowType(value){
-            console.log('value',value);
-            
           this.checkTypeValue = value;
           this.getWorks();
+        },
+        changeName(courseId,testId){
+          let array = this.worksArray.find(i=>i.courseid == courseId);
+          if(array){
+            array = array.array;
+            array.find(i=>i.id==testId).editName = true;
+            this.$forceUpdate();
+            this.$nextTick(()=>{
+              console.log(this.$refs[`changeName_${testId}`])
+              this.$refs[`changeName_${testId}`][0].focus();
+            })
+          }
+        },
+        changeNameUpdate(courseId,testId){
+          let array = this.worksArray.find(i=>i.courseid == courseId);
+          if(array){
+            array = array.array;
+            array.find(i=>i.id==testId).editName = false;
+            this.$forceUpdate();
+            let data = array.find(i=>i.id==testId);
+            let params = [{
+              uid:this.userid,
+              testId:testId,
+              newName:data.name,
+            }]
+
+            this.ajax.post(this.$store.state.api+"update_testCourseWorksNameById",params).then(res=>{
+              if(res.data == 1){
+                this.$message.success("修改成功")
+              }else{
+                this.$message.error("修改失败")
+                array.find(i=>i.id==testId).name = "";
+              }
+            })
+          }
         }
     },
     mounted() {
-        // this.selectTestType(1);
-        // this.getPageBase()
         this.getNavType()
-        
-        console.log('this.typeListStr',this.typeListStr);
-        
-        // if(this.typeListStr){
-        //   this.changeShowType(this.typeListStr)
-          // this.checkTypeValue = this.typeId
-        // }
     },
-    // activated(){
-    //     // this.selectTestType(2);
-    //     if(this.typeListStr){
-    //       this.changeShowType(this.typeListStr)
-    //       // this.checkTypeValue = this.typeId
-    //     }
-    // },
 };
 </script>
 
 <style scoped>
 .i_body_box {
-    /* height: calc(100% - 10px); */
-    height: 100%;
+    height: calc(100% - 80px);
+    padding: 10px 0 0;
+    box-sizing: border-box;
 }
 
 .check_nav {
     display: flex;
     height: 50px;
     align-items: center;
+    padding: 0;
     box-sizing: border-box;
     width: 100%;
-    padding: 0 90px;
-    box-sizing: border-box;
     overflow: auto;
+    padding: 0 90px;
 }
 
 .check_nav>.nav {
@@ -734,7 +754,6 @@ export default {
     cursor: pointer;
     min-width: fit-content;
     margin-right: 10px;
-    
 }
 
 .check_nav>.active {
@@ -808,12 +827,12 @@ export default {
 
 
 .check_box {
-    height: calc(100% - 90px);
+    height: calc(100% - 50px);
     overflow: auto;
-    padding: 0 0px 20px;
-    margin: 0 90px;
+    padding: 0 0 20px;
     box-sizing: border-box;
     background: rgb(248, 250, 254);
+    margin: 0 90px;
 }
 
 .test_panel {
@@ -1104,7 +1123,7 @@ export default {
     font-size: 14px;
     width: 160px;
     min-width: 160px;
-    margin: 0 30px 0 auto;
+    margin: 0 30px 0 0;
 }
 .test_add_box>.test>.mask {
     display: flex;
@@ -1201,4 +1220,38 @@ export default {
 .isDead{
     color:#EE3E3E;
 }
+
+.testType{
+  width: 60px;
+  margin: 0 45px 0 auto;
+}
+
+.testType>span{
+  padding: 6px 10px;
+  border-radius: 4px;
+  border: solid 1px gray;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  font-size: 12px;
+}
+
+
+.testType>.typeStatus_2{
+  background:#F0F9F2;
+  border-color: #B5E3BF;
+  color:#5FC875;
+}
+
+.testType>.typeStatus_4{
+  background:#FEF5EC;
+  border-color: #FAD0A1;
+  color:#F7933B;
+}
+
+.testType>.typeStatus_1{
+  background:#EEF3FC;
+  border-color: #0F40F5;
+  color:#0F40F5;
+}
 </style>

+ 3 - 3
src/components/pages/liyuan/schoolSafe.vue

@@ -2,7 +2,7 @@
   <div class="teacherDevelop">
     <topBar title="平安校园" detail="日常巡查记录 · AI辅助分析"></topBar>
     <div class="cardBox">
-      <card v-for="item in cardArray" :key="item.title" :title="item.title" :icon="item.icon" :to="item.to" :type="item.type"></card>
+      <card v-for="item in cardArray" :key="item.title" :title="item.title" :icon="item.icon" :to="item.to" :type="item.type" :cardData="item"></card>
     </div>
   </div>
 </template>
@@ -19,7 +19,7 @@ export default {
     return {
       cardArray: [
         { title: '安全巡查', icon: require('../../../assets/icon/liyuan/mbll.svg'), type: 1, to: "/safeTest" },
-        { title: '安全表单', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/test" }
+        { title: '安全表单', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/sassPlatform",sassPlatFormTypeId:"c85c921d-8a01-11f0-9c7b-005056924926" }
       ]
     }
   },
@@ -44,4 +44,4 @@ export default {
   width: 100%;
   margin-top: 20px;
 }
-</style>
+</style>

+ 13 - 4
src/components/pages/liyuan/teacherDevelop.vue

@@ -2,7 +2,15 @@
   <div class="teacherDevelop">
     <topBar title="教师发展" detail="教师年度考核 · 教师成长画像 · AI课堂观察"></topBar>
     <div class="cardBox">
-      <card v-for="item in cardData(cardArray)" :key="item.title" :title="item.title" :icon="item.icon" :to="item.to" :type="item.type"></card>
+      <card v-for="item in cardData(cardArray)"
+      :key="item.title"
+      :title="item.title"
+      :icon="item.icon"
+      :to="item.to"
+      :type="item.type"
+      :sortId="item.sortId"
+      :cardData="item"
+      ></card>
     </div>
   </div>
 </template>
@@ -27,13 +35,14 @@ export default {
   data() {
     return {
       role: this.$route.query.role,
-
       cardArray: [
         { title: '年度考核', icon: require('../../../assets/icon/liyuan/niandukaohe.svg'), type: 1, to: "/examineL",role:0 },
         { title: '个人档案', icon: require('../../../assets/icon/liyuan/gerendangan.svg'), type: 1, to: "/userInfoL",role:0 },
         { title: '教师画像', icon: require('../../../assets/icon/liyuan/jiaoshihuaxiang.svg'), type: 1, to: "/portraitL",role:0 },
         { title: '课堂观察', icon: require('../../../assets/icon/liyuan/ketangguancha.svg'), type: 1, to: "/classroomObservation",role:0 },
-        { title: '智能表单', icon: require('../../../assets/icon/liyuan/zhinengbiaodan.svg'), type: 1, to: "/test",role:1 },
+        { title: '智能表单', icon: require('../../../assets/icon/liyuan/zhinengbiaodan.svg'), type: 1, to: "/sassPlatform",role:1,sassPlatFormTypeId:"eefb7195-8ee7-11f0-9c7b-005056924926" },
+        { title: '考核资料', icon: require('../../../assets/icon/liyuan/zlsj.svg'), type: 1, to: "/teadTest",role:0,sortId:'eefb7195-8ee7-11f0-9c7b-005056924926' },
+        { title: '考核审核', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/testReview",role:0 },
       ]
     }
   },
@@ -56,4 +65,4 @@ export default {
   width: 100%;
   margin-top: 20px;
 }
-</style>
+</style>

+ 82 - 0
src/components/pages/liyuan/topTalent.vue

@@ -0,0 +1,82 @@
+<template>
+  <div class="teacherDevelop">
+    <el-image
+        style="
+            width: 100%;
+            border-radius: 10px;
+            height: 320px;
+        "
+        class="imgCar"
+        src="https://img2.baidu.com/it/u=3227833308,1625526130&fm=253&fmt=auto&app=138&f=JPEG?w=800&h=328"
+    >
+    </el-image>
+    <topBar title="拔尖人才" detail="教师年度考核 · 教师成长画像 · AI课堂观察"></topBar>
+    <div class="cardBox">
+      <card v-for="item in cardData(cardArray)"
+      :key="item.title"
+      :title="item.title"
+      :icon="item.icon"
+      :to="item.to"
+      :type="item.type"
+      :sortId="item.sortId"
+      :cardData="item"
+      ></card>
+    </div>
+  </div>
+</template>
+
+<script>
+import topBar from './components/topBar'
+import card from './components/card.vue';
+export default {
+  components: {
+    topBar,
+    card
+  },
+  computed:{
+    // 进行权限判断一些只有管理员能看
+    cardData(){
+      return (val)=>{
+          let com = val.filter(e=> e.role==0 || (this.role == 1 && e.role == 1) )
+          return com
+      }
+    }
+  },
+  data() {
+    return {
+      role: this.$route.query.role,
+      cardArray: [
+        { title: '人才标准', icon: require('../../../assets/icon/liyuan/niandukaohe.svg'), type: 1, to: "/examineL",role:0 },
+        { title: '学生画像', icon: require('../../../assets/icon/liyuan/jiaoshihuaxiang.svg'), type: 1, to: `/testDataBoard?userid= +${this.$route.query.userid} +&oid= +${this.$route.query.oid} +&org= +${this.$route.query.org} +&role= +${this.$route.query.role} +&cid=`,role:0 },
+        { title: '人才数据库', icon: require('../../../assets/icon/liyuan/zhinengbiaodan.svg'), type: 1, to: "/sassPlatform",role:1,sassPlatFormTypeId:"eefb7195-8ee7-11f0-9c7b-005056924926" },
+        { title: '个人档案', icon: require('../../../assets/icon/liyuan/zlsj.svg'), type: 1, to: "/teadTest",role:0,sortId:'eefb7195-8ee7-11f0-9c7b-005056924926' },
+        { title: '人才评估', icon: require('../../../assets/icon/liyuan/workTest.svg'), type: 1, to: "/testReview",role:0 },
+      ]
+      
+    }
+  },
+}
+</script>
+
+<style scoped>
+.teacherDevelop{
+  width: 100%;
+  height: 100%;
+  padding: 40px 90px;
+  box-sizing: border-box;
+  background: #FAFAFA;
+}
+
+.cardBox{
+  display: grid;
+  grid-template-columns: repeat(5, 1fr);
+  gap: 20px;
+  width: 100%;
+  margin-top: 20px;
+}
+.imgCar >>> img{
+	/* height: 100%; */
+	width: 100%;
+	object-fit: cover;
+}
+</style>

+ 294 - 11
src/components/pages/newCourse/addCourse.vue

@@ -172,6 +172,7 @@
                                 font-weight: 600;
                                 padding: 12px 14px 12px 71px;
                               "
+                              @change="saveCourse"
                             />
                             <el-switch
                               v-model="highSetting"
@@ -1209,6 +1210,12 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                   </div>
                                   <div class="chapter_upload_n">
                                     <input
@@ -1294,6 +1301,24 @@
                                       readonly="true"
                                       @click="selectLine(itemTaskIndex, index1)"
                                     />
+
+                                    <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  />
+
                                     <input
                                       :placeholder="
                                         item1.title ? item1.title : '链接'
@@ -1411,6 +1436,13 @@
                                     >
                                       <div></div>
                                     </div>
+                                    <div
+                                    class="chapter_upload_ic_edit"
+                                    v-if="item1.type == 17"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  >
+                                    <div></div>
+                                  </div>
                                     <div
                                       class="chapter_upload_ic_edit"
                                       v-if="item1.type == 14"
@@ -1492,13 +1524,20 @@
                           >
                             智能应用
                           </button>
-                          
+
                            <button
                             class="c_pub_button_add pub_btn_add_img"
                                 @click="openCodeEditor(0,'',unitIndex,itemTaskIndex ,'')"
                           >
                             代码编辑器
                           </button>
+
+                          <button
+                            class="c_pub_button_add pub_btn_add_img"
+                                @click="uploadZIPFile(itemTaskIndex)"
+                          >
+                            代码上传
+                          </button>
                           </div>
                           <div
                             v-if="
@@ -1683,6 +1722,12 @@
                                     class="chapter_upload_l_i15"
                                     style="margin-left: 1px"
                                   ></div>
+
+                                  <div
+                                    v-if="item1.type == 17"
+                                    class="chapter_upload_l_i8"
+                                    style="margin-left: 1px"
+                                  ></div>
                                   </div>
                                   <div class="chapter_upload_n">
                                     <span
@@ -1760,6 +1805,23 @@
                                       @click="selectLine(itemTaskIndex, index1)"
                                     />
 
+                                    <input
+                                    :placeholder="
+                                      item1.title ? item1.title : '代码上传'
+                                    "
+                                    v-if="item1.type == 17"
+                                    style="
+                                  border: none;
+                                  outline: none;
+                                  width: 80%;
+                                  white-space: nowrap;
+                                  overflow: hidden;
+                                  text-overflow: ellipsis;
+                                "
+                                    readonly="true"
+                                    @click="changeHTmlPage(itemTaskIndex, index1)"
+                                  />
+
                                     <input
                                     :placeholder="
                                       item1.title ? item1.title : 'Ai应用'
@@ -7491,7 +7553,7 @@
     ></EnglishVoice>
     <appDialog ref="appDialog" @success="selectAppSuccess"></appDialog>
     <CodeEditor ref="CodeEditorRef" @success="addHtmlSuccess"></CodeEditor>
-
+    <selectHtmlPageDialog ref="selectHtmlPageDialogRef" @success="selectHtmlPageSuccess"/>
   </div>
 </template>
 
@@ -7515,6 +7577,7 @@ import EnglishVoice from "../EnglishVoice/index.vue";
 import appDialog from '../components/appDialog.vue'
 import { myMixin } from "@/mixins/mixin.js"
 import CodeEditor from "../components/CodeEditor";
+import { uploadFileMixin } from "../../tools/uploadFileMixin.js";
 
 var OpenCC = require("opencc-js");
 let converter = OpenCC.Converter({
@@ -7522,8 +7585,11 @@ let converter = OpenCC.Converter({
 		to:'cn'
 })
 
+import JSZip from 'jszip'
+import selectHtmlPageDialog from '../dialog/selectHtmlPageDialog.vue'
+
 export default {
-  mixins: [ myMixin ],
+  mixins: [ myMixin,uploadFileMixin ],
   components: {
     CodeEditor,
     EditorBar,
@@ -7538,10 +7604,11 @@ export default {
     evaBox,
     EnglishVoice,
     appDialog,
+    selectHtmlPageDialog,
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       checkAll: false,
       checkAll2: false,
       chooseType: 1,
@@ -7827,8 +7894,8 @@ export default {
       twoJson: [],
       oneJson: [],
       updateKey:1,
-      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
-
+      optionTypeList:['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'],
+      changeId:"",
     };
   },
   directives: {
@@ -8029,6 +8096,9 @@ export default {
       }
     },
     steps(newValue, old) {
+      if(newValue === 0){
+        this.steps = 1
+      }
       if (newValue == 4) {
         let cPan = 1;
         for (var i = 0; i < this.unitJson.length; i++) {
@@ -8357,7 +8427,19 @@ export default {
         })
         .catch((v) => {
           console.log(v);
-          if (v == "cancel") {
+          if (v == "cancel" && this.gotype == 'backCourseCon') {
+            this.goTo(
+              "/CourseCon?userid=" +
+                this.userid +
+                "&oid=" +
+                this.oid +
+                "&org=" +
+                this.org +
+                "&role=" +
+                this.role +
+                "&gotype=1"
+            );
+          }else if(v == "cancel"){
             this.goTo(
               "/course?userid=" +
                 this.userid +
@@ -10432,10 +10514,10 @@ export default {
           this.cid = res.data.courseId;
           this.courseUserid = this.userid;
           this.islogin = true;
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_stageMode_clickUpload" }, "success")
+          // this.addOp3('1', "", { courseid: this.courseId ,type: "course_stageMode_clickUpload" }, "success")
         })
         .catch((err) => {
-          this.addOp3('1', "", { courseid: this.courseId ,type: "course_stageMode_clickUpload" }, err)
+          // this.addOp3('1', "", { courseid: this.courseId ,type: "course_stageMode_clickUpload" }, err)
           this.$message.error("网络不佳");
           console.error(err);
         });
@@ -14144,6 +14226,17 @@ export default {
         this.isPasteTask = true;
       }
     },
+    saveCourse(){
+      if (this.cid == "" || this.cid == undefined) {
+        this.addWork();
+      } else {
+        if (this.userid != this.courseUserid && this.role != "1") {
+          this.updateWork2();
+        } else {
+          this.updateWork();
+        }
+      }
+    },
     searchImage() {
       var _this = this;
       _this.imageList = [];
@@ -14587,7 +14680,7 @@ export default {
       console.log('addHtmlSuccess',name,url,'type:',type,'unitIndex',unitIndex,'itemTaskIndex',itemTaskIndex,'index1',index1);
       if (type == 1) {
         this.unitJson[unitIndex].chapterInfo[0].taskJson[
-          itemTaskIndex 
+          itemTaskIndex
         ].chapterData.splice(index1,1,{
           name: Tname,
           url: url,
@@ -14595,7 +14688,7 @@ export default {
         })
       }else{
         this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
-          itemTaskIndex 
+          itemTaskIndex
         ].chapterData.push({
           name: Tname,
           url: url,
@@ -14649,6 +14742,196 @@ export default {
       }
       this.imgChange1(null, null, 8, this.lineCount);
       this.dialogVisible7 = false;
+    },
+    // zip压缩文件上传
+    uploadZIPFile(i){
+
+    this.lineCount = i;
+    // 只支持上传zip文件
+    let input = document.createElement('input');
+    input.type = 'file';
+    input.accept = '.zip';
+    input.style.display = 'none';
+    // 只允许上传一个文件
+    input.multiple = false;
+    input.onchange = async (e) => {
+      let file = e.target.files[0];
+      if (!file) return;
+      if (file.type !== 'application/zip' && !file.name.endsWith('.zip')) {
+        this.$message.error('只支持上传zip文件');
+        return;
+      }
+      try{
+        const zip = new JSZip();
+        const content = await zip.loadAsync(file);
+        let _fileStructure = this.buildFileStructure(file,content);
+        let _time = new Date().getTime();
+        let _resultList = await this.uploadZipFileFn(_fileStructure.files,`${_time}_${_fileStructure.folderName}`);
+        this.changeId = "";
+        this.$refs.selectHtmlPageDialogRef.open(_resultList);
+
+      }catch(e){
+        console.log(e)
+        this.$message.error("解析zip文件失败")
+      }
+
+    };
+    document.body.appendChild(input);
+    input.click();
+    setTimeout(() => {
+      document.body.removeChild(input);
+    }, 1000);
+    },
+    // 构建文件结构树
+    buildFileStructure(file,zip) {
+    const root = {
+      folderName: file.name.replace(/\.[^/.]+$/, ""), // 移除扩展名
+      files: []
+    };
+
+    // 遍历ZIP文件中的所有文件/文件夹
+    zip.forEach((relativePath, file) => {
+      if (file.dir) return; // 跳过目录
+
+      const parts = relativePath.split('/');
+      let currentLevel = root.files;
+
+      for (let i = 0; i < parts.length; i++) {
+        const part = parts[i];
+        const isLast = i === parts.length - 1;
+
+        if (isLast) {
+          // 添加文件
+          currentLevel.push({fileName:part,file:file});
+        } else {
+          // 查找或创建文件夹
+          let folder = currentLevel.find(item =>
+            typeof item === 'object' && item.folderName === part
+          );
+
+          if (!folder) {
+            folder = {
+              folderName: part,
+              files: []
+            };
+            currentLevel.push(folder);
+          }
+
+          currentLevel = folder.files;
+        }
+      }
+    });
+
+    return root;
+    },
+    //按路径上传文件
+    async uploadZipFileFn(fileList,path){
+    return new Promise(async (resolve)=>{
+      let _copyFileList = fileList;
+
+      let promise = [];
+      for(let i = 0; i < _copyFileList.length; i++){
+        if(_copyFileList[i].folderName){
+          let _path = `${path}/${_copyFileList[i].folderName}`;
+          promise.push(this.uploadZipFileFn(_copyFileList[i].files,_path).then(res=>{
+            _copyFileList[i].files = res;
+          }))
+        }else if(_copyFileList[i].fileName){
+          // 将 ZIP 条目转换为文件对象
+          const blob = await _copyFileList[i].file.async('blob');
+          // 根据文件名设置type
+          let type = 'text/html';
+          if (_copyFileList[i].fileName.endsWith('.js')) {
+            type = 'application/javascript';
+          } else if (_copyFileList[i].fileName.endsWith('.css')) {
+            type = 'text/css';
+          } else if (_copyFileList[i].fileName.endsWith('.json')) {
+            type = 'application/json';
+          } else if (_copyFileList[i].fileName.endsWith('.png')) {
+            type = 'image/png';
+          } else if (_copyFileList[i].fileName.endsWith('.jpg') || _copyFileList[i].fileName.endsWith('.jpeg')) {
+            type = 'image/jpeg';
+          } else if (_copyFileList[i].fileName.endsWith('.gif')) {
+            type = 'image/gif';
+          } else if (_copyFileList[i].fileName.endsWith('.svg')) {
+            type = 'image/svg+xml';
+          } else if (_copyFileList[i].fileName.endsWith('.html') || _copyFileList[i].fileName.endsWith('.htm')) {
+            type = 'text/html';
+          } else if (_copyFileList[i].fileName.endsWith('.txt')) {
+            type = 'text/plain';
+          } else if (_copyFileList[i].fileName.endsWith('.pdf')) {
+            type = 'application/pdf';
+          } else if (_copyFileList[i].fileName.endsWith('.mp3')) {
+            type = 'audio/mpeg';
+          } else if (_copyFileList[i].fileName.endsWith('.mp4')) {
+            type = 'video/mp4';
+          } else if (_copyFileList[i].fileName.endsWith('.zip')) {
+            type = 'application/zip';
+          } else if (_copyFileList[i].fileName.endsWith('.xml')) {
+            type = 'application/xml';
+          } else if (_copyFileList[i].fileName.endsWith('.csv')) {
+            type = 'text/csv';
+          } else if (_copyFileList[i].fileName.endsWith('.md')) {
+            type = 'text/markdown';
+          }
+          let _file = new File([blob], _copyFileList[i].fileName, {type: type, lastModified: new Date().getTime()});
+          promise.push(this.awsupload({file:_file,path:`${path}/${_copyFileList[i].fileName}`}).then(res=>{
+            delete _copyFileList[i].file;
+            _copyFileList[i].url = decodeURIComponent(res.Location);
+          }))
+        }
+      }
+      Promise.all(promise).then(res=>{
+        resolve(_copyFileList);
+      })
+    })
+    },
+    selectHtmlPageSuccess(data){
+    let _selectFile = data.find(i=>i.isSelect==="1");
+    if(!_selectFile){
+      this.changeId = "";
+      return this.$message.info("未选择主页面")
+    }
+
+    console.log("_selectFile",_selectFile)
+    let _index = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+    this.lineCount
+    ].chapterData.findIndex(i => i.type == 17 && i.id == this.changeId);
+    if (_index != -1) {
+      console.log("_index",_index)
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.lineCount
+      ].chapterData[_index] = {
+        name: _selectFile.fileName,
+        title: _selectFile.fileName,
+        id:this.changeId,
+        url: _selectFile.url,
+        fileList:data,
+        type: 17
+      };
+    } else {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      this.lineCount
+      ].chapterData.push({
+        name: _selectFile.fileName,
+        title: _selectFile.fileName,
+        id:new Date().getTime(),
+        url: _selectFile.url,
+        fileList:data,
+        type: 17
+      });
+    }
+    this.changeId = "";
+    this.$forceUpdate();
+    this.$refs.selectHtmlPageDialogRef.close();
+    },
+    changeHTmlPage(itemTaskIndex,i){
+      let _data = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i];
+      this.lineCount = itemTaskIndex;
+      this.changeId = _data.id;
+      this.$refs.selectHtmlPageDialogRef.open(_data.fileList);
     }
   },
   beforeDestroy() {

+ 274 - 0
src/components/pages/noticeCenter/component/received.vue

@@ -0,0 +1,274 @@
+<template>
+  <div class="received">
+    <div class="r_header">
+      <div class="r_h_title">已收通知</div>
+      <div class="r_h_right">
+        <div class="r_h_r_total">
+          共(
+          <div>{{ pageData.total }}</div>
+          )封
+        </div>
+        <el-input
+          style="width: 250px;"
+          placeholder="请输入关键词"
+          v-model="searchValue"
+          @keyup.enter.native="getData()"
+        >
+          <i slot="suffix" class="el-input__icon el-icon-search" style="cursor: pointer;font-size: 18px;color: #000;" @click="getData()"></i>
+        </el-input>
+      </div>
+    </div>
+    <div class="r_content" v-loading="tableLoading">
+      <el-table
+        :data="tableData"
+        :header-cell-style="{ background: '#f1f1f1', fontSize: '17px' }"
+        style="width: 100%"
+        @row-click="showNoticeDetail"
+        :row-style="{cursor:'pointer'}"
+        height="calc(100%)"
+      >
+        <el-table-column
+          fixed
+          prop="title"
+          label="通知标题"
+          width="auto"
+          min-width="200"
+        >
+          <template slot-scope="scope">
+            <span v-html="scope.row.title"></span>
+          </template>
+        </el-table-column>
+        <el-table-column label="状态 " width="150" align="center">
+          <template slot-scope="scope">
+            <span class="status" :class="`status_${scope.row.status}`">{{
+              status[scope.row.status]
+            }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="type" label="类型 " width="150" align="center">
+        </el-table-column>
+        <el-table-column
+          prop="create_at"
+          label="时间 "
+          width="250"
+          align="center"
+        >
+        </el-table-column>
+        <el-table-column
+          prop="publisherName"
+          label="发布者 "
+          width="300"
+          align="center"
+        >
+        </el-table-column>
+        <el-table-column
+          prop="source"
+          label="发布来源"
+          width="200"
+          align="center"
+        >
+        </el-table-column>
+      </el-table>
+    </div>
+    <div class="r_bottom">
+      <el-pagination
+        @size-change="handleSizeChange"
+        @current-change="handleCurrentChange"
+        :current-page="pageData.nowPage"
+        :page-sizes="[10, 20, 30, 40]"
+        :page-size="pageData.size"
+        layout="sizes, prev, pager, next"
+        :total="pageData.total"
+      >
+      </el-pagination>
+    </div>
+    <noticeDetailDialog ref="noticeDetailDialogRef"/>
+  </div>
+</template>
+
+<script>
+import noticeDetailDialog from '../dialog/noticeDetailDialog.vue';
+export default {
+  components: {
+    noticeDetailDialog
+  },
+  data() {
+    return {
+      userId: this.$route.query.userid,
+      org: this.$route.query.org,
+      oid: this.$route.query.oid,
+      tableLoading: false,
+      status: ["未读", "已读"],
+      searchValue: "",
+      tableData: [],
+      copyData: [],
+      pageData: {
+        nowPage: 1,
+        total: 0,
+        size: 20
+      }
+    };
+  },
+  methods: {
+    handleSizeChange(val) {
+      this.pageData.size = val;
+      this.getData();
+    },
+    handleCurrentChange(val) {
+      this.pageData.nowPage = val;
+      this.getData();
+    },
+    getData() {
+      if (this.tableLoading) return;
+      this.tableLoading = true;
+      let params = [
+        {
+          uid: this.userId,
+          status: "",
+          type: "",
+          source: "",
+          pUid: "",
+          searchValue: this.searchValue,
+          pageNum: this.pageData.nowPage,
+          pageSize: this.pageData.size
+        }
+      ];
+
+      this.ajax
+        .post(this.$store.state.api + "select_noticeCenter", params)
+        .then(res => {
+          let _resData = res.data[0];
+          if (_resData.length > 0) {
+            _resData.forEach(item => {
+              item.content = JSON.parse(item.content);
+            })
+            this.copyData = _resData;
+            this.tableData = _resData;
+            this.pageData.total = res.data[1][0].total;
+          } else {
+            this.copyData = [];
+            this.pageData.total = 0;
+            this.pageData.nowPage = 1;
+          }
+          this.tableLoading = false;
+          // this.tableData = res.data.list
+          // this.pageData.total = res.data.total
+        })
+        .catch(e => {
+          console.log(e);
+          this.$message.error("获取通知失败");
+          this.tableLoading = false;
+        });
+    },
+    showNoticeDetail(row){
+      this.$refs.noticeDetailDialogRef.open(row)
+      if(row.status!=1){
+        this.changeStatus(row.id,1)
+      }
+    },
+    changeStatus(id,newStatus){
+      let params = [{
+        uid:this.userId,
+        id:id,
+        status:newStatus
+      }]
+
+      this.ajax.post(this.$store.state.api+"update_noticeCenter_statusByid",params).then(res=>{
+        if(res.data==1){
+          this.tableData.find(i=>i.id===id).status = newStatus;
+          console.log("更新状态成功");
+        }
+      }).catch(err=>{
+        console.log("更新状态失败",err);
+      })
+    }
+  },
+  mounted() {
+    this.getData();
+  }
+};
+</script>
+
+<style scoped>
+.received {
+  width: calc(100%);
+  height: 100%;
+  padding: 20px 20px;
+  background: #fff;
+  border: solid 1px #dfdfe0;
+  border-radius: 4px;
+  box-sizing: border-box;
+}
+
+.r_header {
+  width: 100%;
+  height: 80px;
+  display: flex;
+  box-sizing: border-box;
+  align-items: center;
+  justify-content: space-between;
+}
+
+.r_h_right {
+  width: fit-content;
+  display: flex;
+  align-items: center;
+}
+
+.r_h_r_total {
+  width: fit-content;
+  margin-right: 20px;
+  display: flex;
+  align-items: center;
+}
+
+.r_h_r_total > div {
+  display: flex;
+  color: #5398e3;
+}
+
+.r_h_title {
+  font-size: 28px;
+  font-weight: bold;
+}
+
+.r_content {
+  width: 100%;
+  height: calc(100% - 80px - 40px);
+  overflow: auto;
+  box-sizing: border-box;
+  padding: 20px 0px;
+  border-top: solid 1px #dfdfe0;
+}
+
+.status {
+  padding: 0px 10px;
+  border-radius: 4px;
+  height: 30px;
+  width: fit-content;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin: 0 auto;
+}
+
+.status_0 {
+  background: #f3f4f6;
+  color: #4d5765;
+  border: solid 1px #d4d8dd;
+}
+
+.status_1 {
+  background: #ecfdf5;
+  color: #10664e;
+  border: solid 1px #abf4d3;
+}
+
+.r_bottom {
+  width: 100%;
+  height: 40px;
+  display: flex;
+  align-items: center;
+  justify-content: flex-end;
+}
+</style>

+ 250 - 0
src/components/pages/noticeCenter/dialog/noticeDetailDialog.vue

@@ -0,0 +1,250 @@
+<template>
+	<div>
+		<el-dialog
+			:center="true"
+			:visible.sync="show"
+			:close-on-click-modal="true"
+			:modal="true"
+			width="auto"
+			height="auto"
+      top="10vh"
+			:append-to-body="true"
+			class="dialog"
+		>
+			<div class="box">
+				<div class="b_head">
+					<span>消息详细</span>
+					<svg
+						@click="close()"
+						t="1748587270371"
+						class="icon"
+						viewBox="0 0 1024 1024"
+						version="1.1"
+						xmlns="http://www.w3.org/2000/svg"
+						p-id="5023"
+						width="200"
+						height="200"
+					>
+						<path
+							d="M0 0h1024v1024H0z"
+							fill="#FF0033"
+							fill-opacity="0"
+							p-id="5024"
+						></path>
+						<path
+							d="M240.448 168l2.346667 2.154667 289.92 289.941333 279.253333-279.253333a42.666667 42.666667 0 0 1 62.506667 58.026666l-2.133334 2.346667-279.296 279.210667 279.274667 279.253333a42.666667 42.666667 0 0 1-58.005333 62.528l-2.346667-2.176-279.253333-279.253333-289.92 289.962666a42.666667 42.666667 0 0 1-62.506667-58.005333l2.154667-2.346667 289.941333-289.962666-289.92-289.92a42.666667 42.666667 0 0 1 57.984-62.506667z"
+							fill="#fff"
+							p-id="5025"
+						></path>
+					</svg>
+				</div>
+				<div class="b_main" v-loading="loading" v-if="data">
+          <div class="b_m_top">
+            <div class="b_m_t_title" v-html=" data.title"></div>
+            <div>
+              <span>发布来源:{{data.source}}</span>
+              <span>发布者:{{data.publisherName}}</span>
+              <span>发布时间:{{data.create_at}}</span>
+            </div>
+          </div>
+          <div class="b_m_content" v-html="data.content.text">
+
+          </div>
+          <div class="b_m_bottom" v-if="false"></div>
+				</div>
+				<div class="b_bottom">
+          <div class="b_b_submit" @click="close()">确定</div>
+				</div>
+			</div>
+		</el-dialog>
+	</div>
+</template>
+
+<script>
+export default {
+	data() {
+		return {
+			loading: false,
+			show: false,
+			data: null,
+		};
+	},
+	methods: {
+		open(data) {
+			this.data = JSON.parse(JSON.stringify(data));
+			this.loading = false;
+			this.show = true;
+		},
+		close() {
+			this.show = false;
+			this.init();
+		},
+		init() {
+			this.data = null;
+			this.loading = false;
+		},
+    submit(){
+      this.close()
+    },
+	},
+};
+</script>
+
+<style scoped>
+.dialog >>> .el-dialog {
+	width: 80vw !important;
+	border-radius: 8px;
+	padding: 0;
+	background-color: #fff;
+	overflow: hidden;
+}
+
+.dialog >>> .el-dialog__body {
+	width: 80vw !important;
+  height: 80vh;
+	height: auto;
+	flex-shrink: 0;
+	padding: 0;
+	box-sizing: border-box;
+	overflow: auto;
+}
+
+.dialog >>> .el-dialog__header {
+	display: none !important;
+}
+
+.box {
+	width: 80vw;
+	height: 80vh;
+	background: #fff;
+	border-radius: 15px;
+	box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05),
+		0px 16px 24px 2px rgba(0, 0, 0, 0.04), 0px 8px 10px -5px rgba(0, 0, 0, 0.08);
+
+}
+
+.b_head {
+	width: 100%;
+	height: 50px;
+	/* border-radius: 15px 15px 0 0; */
+	background: #1A1A1A;
+	display: flex;
+	align-items: center;
+	justify-content: space-between;
+	box-sizing: border-box;
+	padding: 0 20px;
+  color: #fff;
+}
+
+.b_head > span {
+	font-size: 18px;
+	font-weight: bold;
+	color: #fff;
+}
+
+.b_head > img {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_head > svg {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_main {
+	width: 100%;
+	height: calc(100% - 70px - 40px - 15px);
+	background: #fff;
+	padding: 20px 20px 20px 20px;
+	box-sizing: border-box;
+  overflow: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+}
+
+.b_bottom {
+	width: 100%;
+	height: 70px;
+	display: flex;
+	align-items: center;
+	justify-content: flex-end;
+	box-sizing: border-box;
+	padding: 0 20px;
+}
+
+.b_bottom>div{
+  padding: 10px 25px;
+  background: #fff;
+  color: #000;
+  border-radius: 4px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  border: solid 1px #EEEEEE;
+  margin-left: 15px;
+  cursor: pointer;
+  font-size: 16px;
+}
+
+.b_bottom>.b_b_submit{
+  background: #1A1A1A;
+  color: #D4D4D4;
+  border-color: #1A1A1A;
+}
+
+
+.b_m_top{
+  width: 100%;
+  height: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  justify-content: center;
+  margin-top: 30px;
+  position: relative;
+}
+
+.b_m_top::after{
+  content: "";
+  width: 98%;
+  height: 1px;
+  background: #C1C1C1;
+  position: absolute;
+  bottom: -30px;
+  left: 1%;
+}
+
+.b_m_t_title{
+  font-size: 3em;
+  margin-bottom: 30px;
+  color: #000;
+}
+
+.b_m_top>div{
+  width: 100%;
+  height: auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.b_m_top>div>span{
+  margin: 0 40px;
+  font-size: 16px;
+}
+
+.b_m_content{
+  margin-top: 50px;
+  width: 100%;
+  height: auto;
+  font-size: 18px;
+  padding: 10px;
+  box-sizing: border-box;
+  white-space:pre-line;
+  color: #000;
+}
+</style>

+ 62 - 0
src/components/pages/noticeCenter/index.vue

@@ -0,0 +1,62 @@
+<template>
+  <div class="noticeCenter">
+    <div class="nc_main">
+      <div class="nc_m_left" v-show="false"></div>
+      <div class="nc_m_right">
+        <received v-show="showRight === 0" ref="receivedRef"/>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import received from './component/received.vue';
+export default {
+  components:{
+    received
+  },
+  data() {
+    return {
+      showRight:0,
+    };
+  },
+};
+</script>
+
+<style scoped>
+.noticeCenter {
+  width: 100%;
+  height: 100%;
+  background: #e8e9eb;
+  box-sizing: border-box;
+  padding: 10px;
+}
+
+.nc_main {
+  width: 100%;
+  height: 100%;
+  box-sizing: border-box;
+  padding: 20px;
+  border-radius: 4px;
+  box-sizing: border-box;
+  display: flex;
+  justify-content: space-between;
+}
+
+.nc_m_left {
+  width: 300px;
+  height: 100%;
+  box-sizing: border-box;
+  padding: 20px 10px;
+  background: #fff;
+  border: solid 1px #dfdfe0;
+  border-radius: 4px;
+  margin-right: 20px;
+}
+
+.nc_m_right {
+  /* width: calc(100% - 300px - 20px); */
+  width: calc(100%);
+  height: 100%;
+}
+</style>

+ 12414 - 0
src/components/pages/pptEasy/addCourse.vue

@@ -0,0 +1,12414 @@
+<template>
+  <div class="pb_content" style="background: #F0F2F5;" v-loading="uploadWorkLoading">
+    <div class="pb_content_body" style="position: relative; margin: 0">
+      <div class="right">
+        <!-- <div style="display: flex; margin-top: 20px; position: relative"> -->
+        <div style="width: 100%; height: 100%; overflow: auto" ref="stepBox">
+          <div class="courseTop">
+            <div class="stepsNav" v-if="!gotype">
+              <el-breadcrumb separator-class="el-icon-arrow-right">
+                <el-breadcrumb-item
+                  :to="{
+                    path:
+                      '/course?userid=' +
+                      userid +
+                      '&oid=' +
+                      oid +
+                      '&org=' +
+                      org +
+                      '&role=' +
+                      role
+                  }"
+                  >课程管理</el-breadcrumb-item
+                >
+                <el-breadcrumb-item>
+                  <span style="color: rgb(15, 126, 255)">添加课程</span>
+                </el-breadcrumb-item>
+              </el-breadcrumb>
+            </div>
+            <div class="r_pub_button_retrun" @click="lastSteps()">返回</div>
+          </div>
+          <div
+            class="rightBox"
+            style="padding: 0;"
+            :style="{
+              height: !isBtnDisplay ? 'calc(100% - 50px)' : 'calc(100% - 120px)'
+            }"
+            v-if="this.steps == 1"
+            @mousewheel="scrollChange"
+          >
+            <div
+              class="updateMask"
+              :style="{
+                height: rightBoxHeight ? rightBoxHeight + 'px' : '100%'
+              }"
+              v-if="cid && userid != courseUserid && role != '1'"
+            ></div>
+            <div class="whiteBg" style="background:unset;padding: 0;">
+              <div>
+                <div class="basic_box" style="padding: 0;">
+                  <div class="big_box">
+                    <div class="left_first">
+                      <div
+                        :class="{
+                          updateTips:
+                            cid && userid != courseUserid && role != '1'
+                        }"
+                      >
+                        <div style="width: 100%;">
+                          <div class="course_input_box">
+                            <div class="bb_courseIcon">
+                              <img src="../../../assets/icon/new/course.png" />
+                            </div>
+                            <input
+                              type="text"
+                              placeholder="请输入课程名称"
+                              class="binfo_input"
+                              v-model="courseName"
+                              style="border: 1.5px solid rgb(202, 209, 220);margin: 0px 10px 0px 0px;border-radius: 5px;font-weight: 600;padding: 12px 14px 12px 71px;"
+                            />
+                            <!-- background: #f6f6f6; -->
+                            <el-switch
+                              v-model="isTeacherSee"
+                              active-text="是否公开此课程"
+                              style="justify-content: center;width: 200px;"
+                            ></el-switch>
+                          </div>
+                        </div>
+                      </div>
+                      <div
+                        class="pType_box all_choose"
+                        v-if="oid == '69893dca-1d47-11ed-8c78-005056b86db5'"
+                      >
+                        <span>类型</span>
+                        <!-- 学科+ 主题+  未来+ -->
+                        <el-radio-group
+                          @change="CourseType2Change"
+                          v-model="pTypeCheckName"
+                          style="display: flex; align-items: center"
+                        >
+                          <div
+                            class="all_choose"
+                            style="width: 100px"
+                            v-for="(item, index) in CourseType2"
+                            :key="index"
+                          >
+                            <el-radio :label="item.name">{{
+                              item.name
+                            }}</el-radio>
+                          </div>
+                        </el-radio-group>
+                      </div>
+                      <div class="both">
+                        <div
+                          class="choose"
+                          v-if="oid != '91796dfb-8791-11ef-9b30-005056b86db5'"
+                        >
+                          <div
+                            class="all_choose"
+                            v-for="(item, index) in CourseType[0]"
+                            :key="index"
+                          >
+                            <span
+                              v-if="
+                                CourseTypeJson[item.id].length > 0 &&
+                                  (oid == '69893dca-1d47-11ed-8c78-005056b86db5'
+                                    ? pTypeCheck.indexOf(item.id) != -1
+                                    : true)
+                              "
+                              >{{ item.name }}:</span
+                            >
+                            <el-checkbox-group
+                              v-model="courseTypeId"
+                              v-if="
+                                CourseTypeJson[item.id].length > 0 &&
+                                  (oid == '69893dca-1d47-11ed-8c78-005056b86db5'
+                                    ? pTypeCheck.indexOf(item.id) != -1
+                                    : true)
+                              "
+                            >
+                              <el-checkbox
+                                v-for="item1 in CourseTypeJson[item.id]"
+                                :key="item1.id"
+                                :label="item1.id"
+                                >{{ item1.name }}</el-checkbox
+                              >
+                            </el-checkbox-group>
+                            <!-- <div
+                              v-else
+                              style="font-size: 14px; margin-left: -8px"
+                            >
+                              暂无
+                            </div> -->
+                          </div>
+                        </div>
+                      </div>
+                    </div>
+                    <div class="right_first">
+                      <!-- <div class="ai_box">
+                      <div class="ai_content" @click="openAI"><img src="../../assets/icon/new/ai.png"/><span>AI共创</span></div>
+                    </div> -->
+                      <div
+                        class="c_info_title"
+                        style="padding: 0 0 15px;margin: 0 auto 0 0;"
+                      >
+                        上传封面
+                      </div>
+                      <div style="width: 100%;">
+                        <div
+                          class="uploadFm"
+                          @click="choosePicVisible = true"
+                          :class="{ uploadFm2: cover.length }"
+                        >
+                          <img
+                            src="../../../assets/icon/addPoster.png"
+                            alt=""
+                            v-if="cover.length == 0"
+                          />
+                          <img
+                            :src="cover[0].url"
+                            alt=""
+                            class="cover_p"
+                            v-else
+                          />
+                          <div v-if="cover.length == 0">点击添加封面</div>
+                          <div class="cover_mask">
+                            <img
+                              src="../../../assets/icon/new/cover_update.png"
+                            /><span style="margin-top:5px;">修改封面</span>
+                          </div>
+                        </div>
+                        <!-- <el-upload :class="{ disUoloadSty: noneBtnImg }" class="upCss" action="#" list-type="picture"
+                          v-loading="uploadLoading1" :http-request="beforeUpload1" ref="upload1"
+                          :on-preview="handlePictureCardPreview" :on-remove="handle_remove1" :show-file-list="true"
+                          :file-list="cover" accept="image/*" :limit="1" :on-exceed="onExceed" v-else>
+                          <i class="el-icon-plus"></i>
+                        </el-upload> -->
+                      </div>
+                    </div>
+                  </div>
+                </div>
+              </div>
+            </div>
+            <div class="whiteBg" style="margin-top: 10px">
+              <div class="wb_j_box">
+                <div class="wb_j_box_content">
+                  <!-- <button class="c_pub_button_add pub_btn_add_img" @click="
+                    (dialogVisibleClass = true),
+                    (classSearch = ''),
+                    (gradeId = ''),
+                    getClass()
+                    ">添加班级</button>
+                  <div v-if="checkboxList2.length" class="wb_j_box_p_box">
+                    <span :class="{ tcMember: getClassC(tc) }" v-for="(tc, tcIndex) in checkboxList2" :key="tcIndex">{{
+                      getClassC(tc) }}</span>
+                  </div> -->
+                  <div
+                    class="wb_j_box_btn"
+                    @click="
+                      (dialogVisibleClass = true),
+                        (classSearch = ''),
+                        (gradeId = ''),
+                        getClass()
+                    "
+                  >
+                    <div class="wb_j_box_title">授课班级</div>
+                    <div class="wb_j_box_btn_c">
+                      <el-tooltip
+                        effect="dark"
+                        :content="getListClassC(checkboxList2)"
+                        placement="top"
+                        v-if="checkboxList2.length"
+                        popper-class="text_tooltip2"
+                      >
+                        <div class="wb_j_box_span">
+                          {{ getListClassC(checkboxList2) }}
+                        </div>
+                      </el-tooltip>
+                      <div v-else class="wb_j_box_span">请选择授课班级</div>
+                      <div class="wb_j_box_arrow"></div>
+                    </div>
+                  </div>
+                </div>
+              </div>
+            </div>
+            <div class="pptIframeArea">
+              <iframe allow="camera *; microphone *;display-capture;midi;encrypted-media;clipboard-write;clipboard-read" webkitallowfullscreen="" mozallowfullscreen="" allowfullscreen="" frameborder="no" border="0" :src="`https://ppt.cocorobo.cn/?mode=editor&courseid=${cid}`" ref="pptIframeRef"></iframe>
+            </div>
+
+            <div class="pptToolsArea">
+              <div class="pta_header">
+                <span>学习内容</span>
+              </div>
+              <div class="pta_buttonArea">
+                <div class="pta_ba_item pta_ba_item1" @click.stop="openToolDialog()">
+                  <svg t="1755077553512" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6307" width="200" height="200"><path d="M512 56.888889C261.688889 56.888889 56.888889 261.688889 56.888889 512s204.8 455.111111 455.111111 455.111111 455.111111-204.8 455.111111-455.111111-204.8-455.111111-455.111111-455.111111m0 853.333333c-221.866667 0-398.222222-176.355556-398.222222-398.222222s176.355556-398.222222 398.222222-398.222222 398.222222 176.355556 398.222222 398.222222-176.355556 398.222222-398.222222 398.222222" fill="#2ED574" p-id="6308"></path><path d="M320.910222 465.806222l201.159111 201.159111-40.220444 40.220445-201.159111-201.159111z" fill="#2ED574" p-id="6309"></path><path d="M725.504 380.188444l40.220444 40.220445-281.6 281.6-40.220444-40.220445z" fill="#2ED574" p-id="6310"></path></svg>
+                  <span>+</span>
+                  <div>互动工具</div>
+                </div>
+
+                <div class="pta_ba_item pta_ba_item2" @click.stop="addTool(73)">
+                  <svg t="1755077646686" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7847" width="200" height="200"><path d="M232.727 139.636h558.546a93.09 93.09 0 0 1 93.09 93.091v372.364a93.09 93.09 0 0 1-93.09 93.09H232.727a93.09 93.09 0 0 1-93.09-93.09V232.727a93.09 93.09 0 0 1 93.09-93.09z m0 46.546a46.545 46.545 0 0 0-46.545 46.545v372.364a46.545 46.545 0 0 0 46.545 46.545h558.546a46.545 46.545 0 0 0 46.545-46.545V232.727a46.545 46.545 0 0 0-46.545-46.545H232.727z m256 512h46.546v139.636h-46.546V698.182zM279.273 837.818h465.454a23.273 23.273 0 0 1 0 46.546H279.273a23.273 23.273 0 0 1 0-46.546z" fill="#FF6347" p-id="7848"></path></svg>
+                  <span>+</span>
+                  <div>H5页面</div>
+                </div>
+
+                <div class="pta_ba_item pta_ba_item3" @click.stop="addTool(72)">
+                  <svg t="1755077789930" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="38464" width="200" height="200"><path d="M967.584 330.496l-156.8 156.608a83.36 83.36 0 0 1-117.696 0l-156.8-156.608a82.944 82.944 0 0 1 0-117.44l156.8-156.608a83.2 83.2 0 0 1 117.696 0l156.8 156.608a82.944 82.944 0 0 1 0 117.44zM928.32 252.192l-156.8-156.608a27.776 27.776 0 0 0-39.232 0l-156.8 156.608a27.648 27.648 0 0 0 0 39.168L732.16 448a27.776 27.776 0 0 0 39.232 0l156.928-156.8a27.648 27.648 0 0 0 0-39.008zM384.352 960H160a96 96 0 0 1-96-96v-223.648a96 96 0 0 1 96-96h224.256a96 96 0 0 1 96 96V864a96 96 0 0 1-95.904 96z m32-319.648a32 32 0 0 0-32-32H160a32 32 0 0 0-32 32V864a32 32 0 0 0 32 32h224.256a32 32 0 0 0 32-32v-223.648z m-32-159.84H160a96 96 0 0 1-96-96V160.864a96 96 0 0 1 96-96h224.256a96 96 0 0 1 96 96v223.744a96 96 0 0 1-95.904 95.904z m32-319.648a32 32 0 0 0-32-32H160a32 32 0 0 0-32 32v223.744a32 32 0 0 0 32 32h224.256a32 32 0 0 0 32-32V160.864z m224.256 383.584h224.256a96 96 0 0 1 96 96V864a96 96 0 0 1-96 96h-224.256a96 96 0 0 1-96-96v-223.648a96 96 0 0 1 96-95.904z m-32 319.648a32 32 0 0 0 32 32h224.256a32 32 0 0 0 32-32v-223.744a32 32 0 0 0-32-32h-224.256a32 32 0 0 0-32 32V864z" fill="#3742FA" p-id="38465"></path></svg>
+                  <span>+</span>
+                  <div>AI应用</div>
+                </div>
+              </div>
+
+
+              <div class="pta_tooListArea">
+                <div class="pta_tla_header">
+                  <span>已创建内容</span>
+                  <div>共<span>{{pptCourseJson.toolsList.length}}</span>项内容</div>
+                </div>
+
+                <!-- <div class="pta_tla_filterArea">
+                  <span @click="filterToolType=''" class="pta_tla_filterItem" :class="{filterActive:filterToolType==''}">全部</span>
+                  <span @click="filterToolType='45'" class="pta_tla_filterItem" :class="{filterActive:filterToolType=='45'}">选择题</span>
+                  <span @click="filterToolType='15'" class="pta_tla_filterItem" :class="{filterActive:filterToolType=='15'}">问答</span>
+                  <span @click="filterToolType='72'" class="pta_tla_filterItem" :class="{filterActive:filterToolType=='72'}">应用中心</span>
+                </div> -->
+                <div class="pta_tla_list" v-if="pptCourseJson.toolsList.length>0">
+                  <div class="pta_tla_l_item" v-for="item in pptCourseJson.toolsList" :key="item.id">
+                    <div class="pta_tla_l_i_left">
+                      <img
+                        src="../../../assets/icon/thirdToolList/choose.png"
+                        alt
+                        v-if="item.tool == 45"
+                      />
+                      <img
+                        src="../../../assets/icon/thirdToolList/answer.png"
+                        alt
+                        v-if="item.tool == 15"
+                      />
+                      <svg v-if="item.tool == 73" t="1755077646686" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7847" width="200" height="200"><path d="M232.727 139.636h558.546a93.09 93.09 0 0 1 93.09 93.091v372.364a93.09 93.09 0 0 1-93.09 93.09H232.727a93.09 93.09 0 0 1-93.09-93.09V232.727a93.09 93.09 0 0 1 93.09-93.09z m0 46.546a46.545 46.545 0 0 0-46.545 46.545v372.364a46.545 46.545 0 0 0 46.545 46.545h558.546a46.545 46.545 0 0 0 46.545-46.545V232.727a46.545 46.545 0 0 0-46.545-46.545H232.727z m256 512h46.546v139.636h-46.546V698.182zM279.273 837.818h465.454a23.273 23.273 0 0 1 0 46.546H279.273a23.273 23.273 0 0 1 0-46.546z" fill="#FF6347" p-id="7848"></path></svg>
+
+                      <img
+                        :src="item.icon"
+                        alt
+                        v-if="item.tool == 72"
+                      />
+                      <div>
+                        <div>{{item.title}}</div>
+                        <span>{{item.brief}}</span>
+                      </div>
+                    </div>
+                    <div class="pta_tla_l_i_right">
+                      <div class="pta_tla_l_i_r_button edit" @click="toolBtn(0,item.id)">
+                        <svg t="1755224440400" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4991" width="200" height="200"><path d="M388.1856 93.0944a46.5408 46.5408 0 1 1 0 93.0816H139.648a46.5408 46.5408 0 0 0-46.5408 46.5536V884.352a46.5408 46.5408 0 0 0 46.5408 46.5408h651.648a46.5408 46.5408 0 0 0 46.5408-46.5408V635.8144a46.5408 46.5408 0 1 1 93.0816 0V884.352C930.9056 961.4848 868.3904 1024 791.2704 1024H139.648C62.5152 1024 0 961.4848 0 884.352V232.7424c0-77.12 62.5152-139.648 139.648-139.648h248.5376zM824.192 13.632l186.1888 186.1888a46.5408 46.5408 0 0 1 0 65.8176L544.896 731.0976A46.5408 46.5408 0 0 1 512 744.7296H325.824a46.5408 46.5408 0 0 1-46.5536-46.5536V512c0-12.3392 4.9024-24.192 13.632-32.9088L758.3616 13.632a46.5408 46.5408 0 0 1 65.8176 0zM791.296 112.384L372.352 531.2768v120.3584h120.3584L911.616 232.7296l-120.3584-120.3584z" fill="#ffffff" p-id="4992"></path></svg>
+                        <span>编辑</span>
+                      </div>
+                      <div class="pta_tla_l_i_r_button copy" @click="toolBtn(1,item.id)">
+                        <svg t="1755224487282" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6922" width="200" height="200"><path d="M931.84 675.84c0 12.288-8.192 20.48-20.48 20.48s-20.48-8.192-20.48-20.48V419.84c0-34.816-26.624-61.44-61.44-61.44h-409.6c-34.816 0-61.44 26.624-61.44 61.44v409.6c0 34.816 26.624 61.44 61.44 61.44h409.6c34.816 0 61.44-26.624 61.44-61.44v-45.056c0-12.288 8.192-20.48 20.48-20.48s20.48 8.192 20.48 20.48v45.056c0 57.344-45.056 102.4-102.4 102.4h-409.6c-57.344 0-102.4-45.056-102.4-102.4v-409.6c0-57.344 45.056-102.4 102.4-102.4h409.6c57.344 0 102.4 45.056 102.4 102.4v256z m-225.28-454.656c0 12.288-8.192 20.48-20.48 20.48s-20.48-8.192-20.48-20.48V194.56c0-34.816-26.624-61.44-61.44-61.44h-409.6c-34.816 0-61.44 26.624-61.44 61.44v409.6c0 34.816 26.624 61.44 61.44 61.44h32.768c12.288 0 20.48 8.192 20.48 20.48s-8.192 20.48-20.48 20.48h-32.768c-57.344 0-102.4-45.056-102.4-102.4v-409.6c0-57.344 45.056-102.4 102.4-102.4h409.6c57.344 0 102.4 45.056 102.4 102.4v26.624z" fill="#32373B" p-id="6923"></path></svg>
+                        <span>复制</span>
+                      </div>
+                      <div class="pta_tla_l_i_r_button delete" @click="toolBtn(2,item.id)">
+                        <svg t="1755224641218" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="12953" width="200" height="200"><path d="M161.186909 205.591273h170.170182V126.277818C331.357091 74.519273 373.294545 32.581818 425.053091 32.581818h208.616727c51.758545 0 93.742545 41.937455 93.742546 93.696v79.313455h200.564363a30.254545 30.254545 0 1 1 0 60.509091h-30.021818v629.154909a93.742545 93.742545 0 0 1-93.742545 93.696H254.882909a93.742545 93.742545 0 0 1-93.696-93.696V266.100364h-41.146182a30.254545 30.254545 0 1 1 0-60.509091h41.146182z m676.305455 60.509091H221.649455v629.154909c0 18.338909 14.894545 33.186909 33.186909 33.186909h549.329454c18.385455 0 33.233455-14.894545 33.233455-33.186909V266.100364zM391.819636 204.148364h275.037091V126.277818A33.233455 33.233455 0 0 0 633.669818 93.090909H425.053091a33.233455 33.233455 0 0 0-33.186909 33.186909v77.870546z" fill="#32373B" p-id="12954"></path></svg>
+                        <span>删除</span>
+                      </div>
+                    </div>
+                  </div>
+
+                </div>
+                <div v-else style="width:100%;display:flex;justify-content:center;font-size:14px;color:#4A5568">暂无工具...</div>
+              </div>
+
+            </div>
+
+            <div class="info_btnBox3">
+              <button
+                class="c_pub_button_return pub_btn_return_img"
+                @click="lastSteps"
+              >
+                返回课程
+              </button>
+              <button
+                class="c_pub_button_confirm pub_btn_finish_img"
+                @click="nextSteps"
+              >
+                确认上传
+              </button>
+            </div>
+          </div>
+        </div>
+      </div>
+    </div>
+    <el-dialog
+      title="提示"
+      :visible.sync="dialogVisible"
+      :append-to-body="true"
+      width="25%"
+      :before-close="handleClose"
+      class="dialog_diy2 customWidth"
+    >
+      <div>请复制该链接邀请协同编辑</div>
+      <div>http://www.boomyon.com/index-zhang.com</div>
+      <span slot="footer" class="dialog-footer">
+        <el-button type="primary">复制链接分享</el-button>
+        <el-button @click="dialogVisible = false">取消</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      :title="updateBoolean2 ? '查看文档' : '添加文档'"
+      :visible.sync="dialogVisible1"
+      :append-to-body="true"
+      width="25%"
+      :before-close="handleClose"
+      class="dialog_diy2 customWidth"
+    >
+      <el-form>
+        <el-form-item label="文档标题">
+          <el-input
+            v-model="tTitle"
+            auto-complete="off"
+            placeholder="请输入文档标题名..."
+          ></el-input>
+        </el-form-item>
+        <div>文档简介</div>
+        <editor-bar v-model="tdetail" @change="change"></editor-bar>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible1 = false">取 消</el-button>
+        <el-button type="primary" @click="addWord" v-if="!updateBoolean2"
+          >添加</el-button
+        >
+        <el-button type="primary" @click="upWord" v-else>修 改</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加文档"
+      :visible.sync="dialogVisible2"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <el-form>
+        <el-form-item label="文档标题">
+          <el-input
+            v-model="templateC.title"
+            auto-complete="off"
+            placeholder="请输入文档标题名..."
+          ></el-input>
+        </el-form-item>
+        <div>文档内容</div>
+        <editor-bar v-model="cTemplate" @change="change"></editor-bar>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="clearChoose">取 消</el-button>
+        <el-button type="primary" @click="wordNext()">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加富文本"
+      :visible.sync="dialogVisible6"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <el-form>
+        <el-form-item label="文本标题">
+          <el-input
+            ref="fuInput"
+            v-model="AttText.title"
+            auto-complete="off"
+            @input="change2"
+            placeholder="请输入文本标题..."
+          ></el-input>
+        </el-form-item>
+        <!-- <div>富文本内容</div> -->
+        <editor-bar
+          v-model="AttText.text"
+          @change="change"
+          v-if="dialogVisible6"
+        ></editor-bar>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="clearAttText">取 消</el-button>
+        <el-button type="primary" @click="isAddOrUpdateAttText">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加H5页面"
+      :visible.sync="dialogVisible7"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy lineCss"
+    >
+      <el-form>
+        <el-form-item label="标题" :label-width="formLabelWidth">
+          <span>
+            <el-input
+              placeholder="请输入链接标题"
+              clearable
+              v-model="lineTitle"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+        <el-form-item label="链接" :label-width="formLabelWidth">
+          <span>
+            <el-input
+              placeholder="请输入链接"
+              clearable
+              v-model="line"
+              class="add_input"
+            ></el-input>
+          </span>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="clearLine">取 消</el-button>
+        <el-button type="primary" @click="isAddOrUpdateLine">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      :title="updateSourcePan ? '修改资源' : '添加资源'"
+      :visible.sync="dialogVisibleSource"
+      :append-to-body="true"
+      width="100%"
+      :before-close="handleClose"
+      class="dialog_diy source_diy"
+    >
+      <div>
+        <sourceDialog
+          :sourceData.sync="sourceData"
+          :updateSourcePan="updateSourcePan"
+        ></sourceDialog>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleSource = false">取 消</el-button>
+        <el-button type="primary" @click="addSource" v-if="!updateSourcePan"
+          >确定</el-button
+        >
+        <el-button type="primary" @click="updateSource" v-else>确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加课程成员"
+      :visible.sync="dialogVisible3"
+      :append-to-body="true"
+      width="25%"
+      height="80%"
+      :before-close="handleClose"
+      class="addNewPP customWidth"
+    >
+      <div class="people">
+        <div class="people_top">
+          <div class="people_nav">选择成员</div>
+          <div class="people_top_right">
+            <div class="people_search">
+              <el-input
+                style="height: 100%"
+                placeholder="搜索成员名称"
+                v-model="searchPeople"
+              ></el-input>
+              <div class="search_img" @click="searchStudent">
+                <img src="../../../assets/icon/search.png" alt />
+              </div>
+            </div>
+          </div>
+        </div>
+        <el-checkbox-group v-model="checkboxList" class="people_name">
+          <el-checkbox
+            v-for="item in studentJuri"
+            :key="item.userid"
+            :label="item.userid"
+            >{{ item.name ? item.name : "暂无学生可选" }}</el-checkbox
+          >
+        </el-checkbox-group>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible3 = false">取 消</el-button>
+        <el-button type="primary" @click="isAddPP">确定</el-button>
+      </span>
+    </el-dialog>
+    <!-- <el-dialog title="添加班级" :visible.sync="dialogVisibleClass" :append-to-body="true" width="400px" height="80%"
+      :before-close="handleClose" class="addNewPP">
+      <div class="people" style="height: 300px">
+        <div class="people_top">
+          <div class="people_top_right">
+            <div class="people_search">
+              <el-select v-model="gradeId" placeholder="请选择年级" class="student_input" clearable @change="getClass()">
+                <el-option label="全部" value=""></el-option>
+                <el-option v-for="(item, index) in gradeList" :key="index" :label="item.name"
+                  :value="item.id"></el-option>
+              </el-select>
+              <el-input placeholder="搜索班级名称" v-model="classSearch" @input="getClass()"></el-input>
+              <div class="search_img">
+                <img src="../../../assets/icon/search.png" alt />
+              </div>
+            </div>
+          </div>
+          <div class="people_nav">选择班级</div>
+        </div>
+        <el-checkbox-group v-model="checkboxList2" class="people_name people_name2" @change="InviteChange"
+          v-if="grade2.length">
+          <div v-for="item in grade2" :key="item.id" class="p_box">
+            <el-checkbox :label="item.id">
+              {{ item.name }}
+            </el-checkbox>
+          </div>
+        </el-checkbox-group>
+        <div v-if="!grade2.length" style="padding:20px 10px">暂无数据</div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleClass = false">取 消</el-button>
+        <el-button type="primary" @click="isAddClass">确定</el-button>
+      </span>
+    </el-dialog> -->
+    <el-dialog
+      title="选择授课班级"
+      :visible.sync="dialogVisibleClass"
+      :append-to-body="true"
+      width="600px"
+      height="80%"
+      :before-close="handleClose"
+      class="addNewPP2"
+    >
+      <div class="check_classBox">
+        <div class="check_class_right">
+          <div
+            class="check_class"
+            :class="{ activeX: gradeId == '' }"
+            @click="(gradeId = ''), getClass()"
+          >
+            全部
+          </div>
+          <el-tooltip
+            placement="top"
+            :content="item.name"
+            v-for="(item, index) in gradeList"
+            :key="index"
+          >
+            <div
+              class="check_class"
+              :class="{ activeX: gradeId == item.id }"
+              @click="(gradeId = item.id), getClass()"
+            >
+              {{ item.name }}
+            </div>
+          </el-tooltip>
+        </div>
+        <div class="check_class_left">
+          <div class="check_class_all_box">
+            <div class="check_class_left_title">选择班级</div>
+            <div style="display:flex;align-items:center;margin-left:auto;">
+              <el-checkbox
+                v-model="checkAll"
+                @change="handleCheckAllChange"
+                class="all_check"
+                >全选</el-checkbox
+              >
+            </div>
+          </div>
+          <!-- <div class="class_item" style="position:absolute; margin:0" v-if="grade2.length">
+            <el-checkbox v-model="checkAll" @change="handleCheckAllChange">全选</el-checkbox>
+          </div> -->
+          <el-checkbox-group
+            v-model="checkboxList2"
+            class="check_class_item"
+            @change="InviteChange"
+            v-if="grade2.length"
+          >
+            <div v-for="item in grade2" :key="item.id" class="class_item">
+              <el-checkbox :label="item.id">
+                {{ item.name }}
+              </el-checkbox>
+            </div>
+          </el-checkbox-group>
+          <div v-if="!grade2.length">暂无数据</div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleClass = false">取 消</el-button>
+        <el-button type="primary" @click="isAddClass">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加协同成员"
+      :visible.sync="dialogVisibleMember"
+      :append-to-body="true"
+      width="25%"
+      height="80%"
+      :before-close="handleClose"
+      class="addNewPP customWidth"
+    >
+      <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="getTeacher"
+              ></el-input>
+              <div class="search_img" @click="getTeacher">
+                <img src="../../../assets/icon/search.png" alt />
+              </div>
+            </div>
+          </div>
+          <div class="people_nav">选择成员</div>
+        </div>
+        <el-checkbox-group
+          v-model="checkboxList3"
+          class="people_name"
+          v-if="teacherJuri.length"
+        >
+          <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">
+                <span>{{ item.username }}</span>
+              </el-tooltip>
+              <el-tooltip placement="top" :content="item.school">
+                <span>{{ item.school }}</span>
+              </el-tooltip>
+            </div>
+          </el-checkbox>
+        </el-checkbox-group>
+        <div style="text-align: center; margin-top: 10px" v-else>暂无数据</div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleMember = false">取 消</el-button>
+        <el-button type="primary" @click="isAddPPTeacher">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="创建问卷"
+      :visible.sync="dialogVisible5"
+      :append-to-body="true"
+      width="800px"
+      :before-close="
+        done => {
+          closePan(4);
+        }
+      "
+      class="dialog_diy fullStyle"
+    >
+      <div style="height:100%">
+        <div
+          class="a_add_title"
+          style="
+            display: flex;
+            flex-direction: row;
+            align-items: center;
+            justify-content: center;
+          "
+        >
+          <!-- <div style="margin-right: 20px; font-size: 20px">标题:</div> -->
+          <el-input
+            v-model="askJson.askTitle"
+            placeholder="请输入标题"
+            style="width: 400px"
+          ></el-input>
+        </div>
+        <div class="a_addBox" style="height:calc(100% - 50px)">
+          <!-- <div style="font-size: 16px; color: #c7c7c7">请输入题目内容</div> -->
+          <div
+            class="a_add_box"
+            v-for="(item1, index1) in askJson.askCount"
+            :key="index1"
+          >
+            <div class="a_add_checkType">
+              <span
+                :class="{
+                  active:
+                    askJson.askJson[index1].type == '1' ||
+                    !askJson.askJson[index1].type
+                }"
+                @click="checkAskType('1', askJson.askJson[index1])"
+                >单选题</span
+              >
+              <span
+                :class="{ active: askJson.askJson[index1].type == '2' }"
+                @click="checkAskType('2', askJson.askJson[index1])"
+                >多选题</span
+              >
+            </div>
+            <div class="a_add_head">
+              <div
+                style="display: flex;align-items: center;width: 100%;margin-right: 20px;"
+              >
+                <span style="min-width:fit-content">{{
+                  index1 + 1 + "、"
+                }}</span>
+                <textarea
+                  class="a_add_head_input textarea_css"
+                  v-autoHeight="40"
+                  v-model="askJson.askJson[index1].askstitle"
+                  placeholder="请输入题目"
+                  @change="
+                    () => {
+                      $forceUpdate();
+                    }
+                  "
+                ></textarea>
+              </div>
+              <div
+                class="moveBtn moveBtn2"
+                style="margin: 0 20px 0 0px;"
+                v-if="askJson.askCount != 1"
+              >
+                <div
+                  class="chapter_upload_up"
+                  @click.stop="askMove(1, index1)"
+                ></div>
+                <div
+                  class="chapter_upload_down"
+                  @click.stop="askMove(2, index1)"
+                ></div>
+              </div>
+              <div class="a_add_head_div">
+                <el-button
+                  type="primary"
+                  size="small"
+                  @click="deleteAskList(index1)"
+                  v-if="askJson.askCount != 1"
+                  >删除
+                </el-button>
+                <el-button
+                  type="primary"
+                  size="small"
+                  @click="addAskList(index1)"
+                  >添加</el-button
+                >
+              </div>
+            </div>
+            <div class="a_add_body">
+              <div class="a_add_input" style="flex-direction: column;">
+                <div
+                  v-for="(item2, checkIndex) in askJson.askJson[index1].askItem"
+                  :key="checkIndex"
+                  style=" margin: 20px 10px 0 0;display: flex;align-items:center;position: relative;"
+                >
+                  <div style="margin-right: 10px">
+                    {{ optionTypeList[checkIndex] }}.
+                  </div>
+                  <textarea
+                    class="a_add_head_input textarea_css"
+                    v-autoHeight="40"
+                    v-model="askJson.askJson[index1].checkList[checkIndex]"
+                    placeholder="请输入选项"
+                    style="width: 300px"
+                    @change="
+                      () => {
+                        $forceUpdate();
+                      }
+                    "
+                  ></textarea>
+                  <div
+                    class="moveBtn moveBtn2"
+                    style="margin: 0 0px 0 20px"
+                    v-if="askJson.askJson[index1].askItem != 1"
+                  >
+                    <div
+                      class="chapter_upload_up"
+                      @click.stop="checkMove(1, index1, checkIndex)"
+                    ></div>
+                    <div
+                      class="chapter_upload_down"
+                      @click.stop="checkMove(2, index1, checkIndex)"
+                    ></div>
+                  </div>
+                  <div class="a_add_body_div">
+                    <el-button
+                      type="primary"
+                      size="small"
+                      @click="addcheckList(askJson.askJson[index1], checkIndex)"
+                      >添加</el-button
+                    >
+                    <el-button
+                      type="primary"
+                      size="small"
+                      @click="
+                        deletecheckList(askJson.askJson[index1], checkIndex)
+                      "
+                      v-if="askJson.askJson[index1].askItem != 1"
+                      >删除
+                    </el-button>
+                  </div>
+                </div>
+              </div>
+              <!-- <div class="a_add_body_div">
+                <el-button style="margin: 10px 0px 0 0" type="primary" size="small"
+                  @click="addcheckList(askJson.askJson[index1])">添加</el-button>
+                <el-button type="primary" size="small" style="margin: 10px 0 0 10px"
+                  @click="deletecheckList(askJson.askJson[index1])" v-if="askJson.askJson[index1].askItem != 1">删除
+                </el-button>
+              </div> -->
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="closePan(4)">取 消</el-button>
+        <el-button type="primary" @click="addAsk">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="创建选择题"
+      :visible.sync="dialogVisibleChoice"
+      :append-to-body="true"
+      width="800px"
+      :before-close="
+        done => {
+          closePan(45);
+        }
+      "
+      class="dialog_diy fullStyle"
+    >
+      <div style="height:100%">
+        <!-- <div class="a_add_title" style="
+            display: flex;
+            flex-direction: row;
+            align-items: center;
+            justify-content: center;
+          ">
+          <div style="margin-right: 20px; font-size: 20px">标题:</div>
+          <el-input v-model="testJson.testTitle" placeholder="请输入标题" style="width: 400px"></el-input>
+        </div> -->
+        <div class="a_addBox" style="height:100%">
+          <div
+            style="font-size: 16px; color: #c7c7c7;display: flex;align-items: center;"
+          >
+            <!-- 请输入题目内容 -->
+            <button
+              class="c_pub_button_add pub_btn_paste_img"
+              @click="pasteOption"
+              style="margin-left: 10px"
+              v-if="isPasteChoice"
+            >
+              智能粘贴
+            </button>
+          </div>
+          <div
+            class="a_add_box"
+            v-for="(item1, index1) in testJson.testCount"
+            :key="index1"
+          >
+            <div class="a_add_checkType">
+              <span
+                :class="{ active: testJson.testJson[index1].type == '1' }"
+                @click="checkTestType('1', testJson.testJson[index1])"
+                >单选题</span
+              >
+              <span
+                :class="{ active: testJson.testJson[index1].type == '2' }"
+                @click="checkTestType('2', testJson.testJson[index1])"
+                >多选题</span
+              >
+            </div>
+            <div class="a_add_head">
+              <div class="timuUpImg">
+                <div style="display: flex;align-items: center;">
+                  <span style="min-width:fit-content">{{
+                    index1 + 1 + "、"
+                  }}</span>
+                  <!-- <el-input class="a_add_head_input"  v-autoHeight="40" resize="none" v-model="testJson.testJson[index1].teststitle" type="textarea"
+                    placeholder="请输入题目">
+                  </el-input> -->
+                  <textarea
+                    class="a_add_head_input textarea_css"
+                    v-autoHeight="40"
+                    v-model="testJson.testJson[index1].teststitle"
+                    placeholder="请输入题目"
+                    @change="
+                      () => {
+                        $forceUpdate();
+                      }
+                    "
+                  ></textarea>
+                </div>
+                <div class="moveBtn moveBtn2" v-if="testJson.testCount != 1">
+                  <div
+                    class="chapter_upload_up"
+                    @click.stop="testMove(1, index1)"
+                  ></div>
+                  <div
+                    class="chapter_upload_down"
+                    @click.stop="testMove(2, index1)"
+                  ></div>
+                </div>
+                <div
+                  class="xzUpImg"
+                  @click.stop="addImg($event)"
+                  style="margin-right: 10px;"
+                >
+                  <img src="../../../assets/icon/xzUpImg.png" alt="" />
+                  <input
+                    type="file"
+                    accept="image/*"
+                    style="display: none"
+                    @change="beforeUploadTiMu($event, index1)"
+                  />
+                </div>
+              </div>
+              <div class="a_add_head_div">
+                <el-button
+                  type="primary"
+                  size="small"
+                  @click="deleteTestList(index1)"
+                  v-if="testJson.testCount != 1"
+                  >删除
+                </el-button>
+                <el-button
+                  type="primary"
+                  size="small"
+                  @click="addTestList(index1)"
+                  >添加</el-button
+                >
+              </div>
+            </div>
+            <div
+              class="timuImgBox"
+              v-if="
+                testJson.testJson[index1].timuList &&
+                  testJson.testJson[index1].timuList.length
+              "
+            >
+              <div
+                v-for="(timg, tIndex) in testJson.testJson[index1].timuList"
+                :key="tIndex"
+                class="timuImg"
+                @click.stop="previewImg(timg.src)"
+              >
+                <img :src="timg.src" alt="" />
+                <div class="deleteWord" @click.stop="deleteM(index1, tIndex)">
+                  <img src="../../../assets/icon/delete.png" alt="" />
+                </div>
+              </div>
+            </div>
+            <div class="a_add_body">
+              <div class="a_add_input a_add_input_choice">
+                <el-radio-group
+                  v-model="testJson.testJson[index1].answer"
+                  v-if="testJson.testJson[index1].type == 1"
+                  @change="
+                    () => {
+                      $forceUpdate();
+                    }
+                  "
+                >
+                  <div class="radioBox">
+                    <el-radio
+                      v-for="(item2, checkIndex) in testJson.testJson[index1]
+                        .testItem"
+                      :key="checkIndex"
+                      :label="checkIndex"
+                    >
+                      <div style="margin-right: 10px">
+                        {{ optionTypeList[checkIndex] }}.
+                      </div>
+                      <div
+                        style="margin-right: 10px; width: 300px"
+                        v-if="
+                          testJson.testJson[index1].checkList[checkIndex] &&
+                            testJson.testJson[index1].checkList[checkIndex]
+                              .imgType &&
+                            testJson.testJson[index1].checkList[checkIndex]
+                              .imgType == 1
+                        "
+                      >
+                        <div
+                          class="inImg"
+                          @click.stop="
+                            previewImg(
+                              testJson.testJson[index1].checkList[checkIndex]
+                                .src
+                            )
+                          "
+                        >
+                          <el-image
+                            :src="
+                              testJson.testJson[index1].checkList[checkIndex]
+                                .src
+                            "
+                            lazy
+                          />
+                          <!-- <img :src="
+                            testJson.testJson[index1].checkList[checkIndex]
+                              .src
+                          " alt="" /> -->
+                        </div>
+                      </div>
+                      <textarea
+                        class="a_add_head_input textarea_css"
+                        v-autoHeight="40"
+                        v-else
+                        v-model="
+                          testJson.testJson[index1].checkList[checkIndex]
+                        "
+                        placeholder="请输入选项"
+                        style="width: 300px; margin-right: 10px"
+                        @change="
+                          () => {
+                            $forceUpdate();
+                          }
+                        "
+                      ></textarea>
+                      <div
+                        class="moveBtn moveBtn2"
+                        v-if="testJson.testJson[index1].testItem != 1"
+                      >
+                        <div
+                          class="chapter_upload_up"
+                          @click.stop="tcheckMove(1, index1, checkIndex)"
+                        ></div>
+                        <div
+                          class="chapter_upload_down"
+                          @click.stop="tcheckMove(2, index1, checkIndex)"
+                        ></div>
+                      </div>
+                      <div class="xzUpImg" @click.stop="addImg($event)">
+                        <img src="../../../assets/icon/xzUpImg.png" alt="" />
+                        <input
+                          type="file"
+                          accept="image/*"
+                          style="display: none"
+                          @change="beforeUploadTi($event, index1, checkIndex)"
+                        />
+                      </div>
+                      <div class="a_add_body_div">
+                        <el-button
+                          type="primary"
+                          size="small"
+                          @click.stop="
+                            addTcheckList(testJson.testJson[index1], checkIndex)
+                          "
+                          >添加</el-button
+                        >
+                        <el-button
+                          type="primary"
+                          size="small"
+                          @click.stop="
+                            deleteTcheckList(
+                              testJson.testJson[index1],
+                              checkIndex
+                            )
+                          "
+                          v-if="testJson.testJson[index1].testItem != 1"
+                          >删除
+                        </el-button>
+                      </div>
+                    </el-radio>
+                  </div>
+                </el-radio-group>
+                <el-checkbox-group
+                  v-model="testJson.testJson[index1].answer"
+                  v-if="testJson.testJson[index1].type == '2'"
+                  @change="
+                    () => {
+                      $forceUpdate();
+                    }
+                  "
+                >
+                  <div class="radioBox">
+                    <el-checkbox
+                      v-for="(item2, checkIndex1) in testJson.testJson[index1]
+                        .testItem"
+                      :key="checkIndex1"
+                      :label="checkIndex1"
+                    >
+                      <div style="margin-right: 10px">
+                        {{ optionTypeList[checkIndex1] }}.
+                      </div>
+                      <div
+                        style="margin-right: 10px; width: 300px"
+                        v-if="
+                          testJson.testJson[index1].checkList[checkIndex1] &&
+                            testJson.testJson[index1].checkList[checkIndex1]
+                              .imgType &&
+                            testJson.testJson[index1].checkList[checkIndex1]
+                              .imgType == 1
+                        "
+                      >
+                        <div
+                          class="inImg"
+                          @click.stop="
+                            previewImg(
+                              testJson.testJson[index1].checkList[checkIndex1]
+                                .src
+                            )
+                          "
+                        >
+                          <el-image
+                            :src="
+                              testJson.testJson[index1].checkList[checkIndex1]
+                                .src
+                            "
+                            lazy
+                          />
+                          <!-- <img :src="
+                            testJson.testJson[index1].checkList[checkIndex1]
+                              .src
+                          " alt="" /> -->
+                        </div>
+                      </div>
+
+                      <textarea
+                        class="a_add_head_input textarea_css"
+                        v-autoHeight="40"
+                        v-else
+                        v-model="
+                          testJson.testJson[index1].checkList[checkIndex1]
+                        "
+                        placeholder="请输入选项"
+                        style="width: 300px; margin-right: 10px"
+                        @change="
+                          () => {
+                            $forceUpdate();
+                          }
+                        "
+                      ></textarea>
+                      <div
+                        class="moveBtn moveBtn2"
+                        v-if="testJson.testJson[index1].testItem != 1"
+                      >
+                        <div
+                          class="chapter_upload_up"
+                          @click.stop="tcheckMove(1, index1, checkIndex1)"
+                        ></div>
+                        <div
+                          class="chapter_upload_down"
+                          @click.stop="tcheckMove(2, index1, checkIndex1)"
+                        ></div>
+                      </div>
+                      <div class="xzUpImg" @click.stop="addImg($event)">
+                        <img src="../../../assets/icon/xzUpImg.png" alt="" />
+                        <input
+                          type="file"
+                          accept="image/*"
+                          style="display: none"
+                          @change="beforeUploadTi($event, index1, checkIndex1)"
+                        />
+                      </div>
+                      <div class="a_add_body_div">
+                        <el-button
+                          type="primary"
+                          size="small"
+                          @click.stop="
+                            addTcheckList(
+                              testJson.testJson[index1],
+                              checkIndex1
+                            )
+                          "
+                          >添加</el-button
+                        >
+                        <el-button
+                          type="primary"
+                          size="small"
+                          @click.stop="
+                            deleteTcheckList(
+                              testJson.testJson[index1],
+                              checkIndex1
+                            )
+                          "
+                          v-if="testJson.testJson[index1].testItem != 1"
+                          >删除
+                        </el-button>
+                      </div>
+                    </el-checkbox>
+                  </div>
+                </el-checkbox-group>
+              </div>
+              <!-- <div class="a_add_body_div">
+                <el-button type="primary" size="small" @click="addTcheckList(testJson.testJson[index1])">添加</el-button>
+                <el-button type="primary" size="small" @click="deleteTcheckList(testJson.testJson[index1])"
+                  v-if="testJson.testJson[index1].testItem != 1">删除
+                </el-button>
+              </div> -->
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="closePan(45)">取 消</el-button>
+        <el-button type="primary" @click="addTest">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加工具"
+      :visible.sync="dialogVisible4"
+      :append-to-body="true"
+      width="600px"
+      :before-close="handleClose"
+      class="dialog_diy addToolsDia"
+    >
+      <div class="toolChoose" style="padding: 0 0 0 30px">
+        <div class="tools">
+          <div
+            class="leftTools"
+            style="
+              width: 95%;
+              padding: 0 0 15px 0;
+              margin: 15px 0;
+            "
+            v-for="(itemTools, itemToolsIndex) in chapTools"
+            :key="itemToolsIndex"
+          >
+            <div
+              style="
+                display: flex;
+                flex-direction: row;
+                align-items: baseline;
+                flex-wrap: nowrap;
+                justify-content: flex-start;
+                position: relative;
+              "
+            >
+              <div class="chooseWho">
+                <div
+                  :class="chapToolsType == 0 ? 'isChooseActive' : ''"
+                  @click="chapToolsType = 0"
+                >
+                  互动类
+                </div>
+                <div
+                  :class="chapToolsType == 1 ? 'isChooseActive' : ''"
+                  @click="chapToolsType = 1"
+                >
+                  思维类
+                </div>
+                <div
+                  :class="chapToolsType == 2 ? 'isChooseActive' : ''"
+                  @click="chapToolsType = 2"
+                >
+                  评价类
+                </div>
+                <div
+                  :class="chapToolsType == 2 ? 'isChooseActive' : ''"
+                  @click="chapToolsType = 2"
+                >
+                  其他
+                </div>
+              </div>
+            </div>
+
+            <div style="min-height: 163px">
+              <div class="toolSort" v-if="chapToolsType == 0">
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(8)">
+                    <img
+                      src="../../../assets/icon/secondToolList/library.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">素材库</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(8)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(8) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+              </div>
+              <div class="toolSort" v-if="chapToolsType == 1">
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(7)">
+                    <img
+                      src="../../../assets/icon/secondToolList/mindNetwork.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">思维网格</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(7)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(7) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(1)">
+                    <img
+                      src="../../../assets/icon/secondToolList/whiteBoard.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">电子白板</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(1)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(1) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(2)">
+                    <img
+                      src="../../../assets/icon/secondToolList/note.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">便签</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(2)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(2) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(6)">
+                    <img
+                      src="../../../assets/icon/secondToolList/doc.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">协同文档</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(6)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(6) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(3)">
+                    <img
+                      src="../../../assets/icon/secondToolList/mindMapping.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">思维导图</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(3)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(3) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(31)">
+                    <img
+                      src="../../../assets/icon/secondToolList/networkPanel.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">数学画板</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(31)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(31) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+              </div>
+              <div class="toolSort" v-if="chapToolsType == 2">
+                <div class="tool">
+                  <div class="whiteBIcon" @click="chapAddTools(5)">
+                    <img
+                      src="../../../assets/icon/thirdToolList/score.png"
+                      alt
+                    />
+                    <div style="margin: 5px 0">量规评分</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(5)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(5) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+                <div class="tool">
+                  <div
+                    class="whiteBIcon"
+                    @click="openTools(chapCount, 4, null)"
+                  >
+                    <img src="../../../assets/icon/thirdToolList/ask.png" alt />
+                    <div style="margin: 5px 0">问卷调查</div>
+                  </div>
+                  <div class="check" @click="chapAddTools(4)">
+                    <img
+                      src="../../../assets/icon/checkNo.png"
+                      alt
+                      v-if="itemTools.tools.indexOf(4) == -1"
+                    />
+                    <div class="checkDiv" v-else>
+                      <img src="../../../assets/icon/checkedIs.png" alt /><span
+                        >已选择</span
+                      >
+                    </div>
+                  </div>
+                </div>
+              </div>
+            </div>
+            <div>
+              <input
+                type="text"
+                placeholder="添加工具描述"
+                class="binfo_input"
+                style="margin: 20px 0; width: 71.5% !important"
+                v-model="itemTools.toolDetail"
+              />
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisible4 = false">取 消</el-button>
+        <el-button type="primary" @click="addChaptersDataTools">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加问答"
+      :visible.sync="dialogVisible8"
+      :append-to-body="true"
+      width="500px"
+      :before-close="
+        done => {
+          closePan(15);
+        }
+      "
+      class="dialog_diy"
+    >
+      <div>
+        <div
+          class="a_add_title"
+          style="
+            display: flex;
+            flex-direction: column;
+            align-items: flex-start;
+            justify-content: center;
+          "
+        >
+          <div style="margin-bottom: 20px; font-size: 20px">问题:</div>
+          <!-- <el-input v-model="answerQ" placeholder="请输入您要问的问题"></el-input> -->
+          <textarea
+            rows="1"
+            v-autoHeight="40"
+            type="text"
+            placeholder="请输入您要问的问题"
+            class="binfo_input"
+            style="width: 100% !important;border:1px solid #DCDFE6"
+            v-model="answerQ"
+          ></textarea>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="closePan(15)">取 消</el-button>
+        <el-button type="primary" @click="addAnswer">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加问题"
+      :visible.sync="dialogVisibleMp3"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div>
+        <div
+          class="a_add_title"
+          style="
+            display: flex;
+            flex-direction: column;
+            align-items: flex-start;
+            justify-content: center;
+          "
+        >
+          <div style="margin-bottom: 20px; font-size: 20px">问题:</div>
+          <el-input
+            v-model="answerQ"
+            placeholder="请输入您想要回答的问题"
+          ></el-input>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleMp3 = false">取 消</el-button>
+        <el-button type="primary" @click="addMp3Answer">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="上传图片"
+      :visible.sync="choosePicVisible"
+      :append-to-body="true"
+      width="600px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div>
+        <div class="fileCss" style="padding-top: 20px">
+          <div>
+            <button class="info_btn" @click="addImg($event)">
+              选择本地文件
+              <input
+                type="file"
+                accept="image/*"
+                style="display: none"
+                @change="beforeUpload1"
+              />
+            </button>
+            <div class="spanName">选择本地文件</div>
+          </div>
+          <!-- <div>
+            <el-button @click="getAllBanner" v-if="isSysPic == false">选择系统文件</el-button>
+            <div class="isSysPic" v-if="isSysPic == true && cover.length > 0">
+              <img :src="cover[0].url" alt="" />
+              <div class="deletePic" @click="deleteSysPic">
+                <img src="../../../assets/icon/delete.png" alt="" />
+              </div>
+            </div>
+            <div class="spanName">选择系统文件</div>
+          </div> -->
+          <div>
+            <el-button
+              @click="(searchImageValue = courseName), resetImage()"
+              v-if="isSysPic2 == false"
+              >选择网络文件</el-button
+            >
+            <div class="isSysPic" v-if="isSysPic2 == true && cover.length > 0">
+              <img :src="cover[0].url" alt="" />
+              <div class="deletePic" @click="deleteSysPic">
+                <img src="../../../assets/icon/delete.png" alt="" />
+              </div>
+            </div>
+            <div class="spanName">选择网络文件</div>
+          </div>
+        </div>
+        <!-- <div class="fileCss">
+          <div>选择本地文件</div>
+          <div>选择系统文件</div>
+        </div> -->
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="choosePicVisible = false">取 消</el-button>
+        <el-button type="primary" @click="choosePicVisible = false"
+          >确 定</el-button
+        >
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="选择系统文件"
+      :visible.sync="sysPicVisible"
+      :append-to-body="true"
+      width="710px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div class="cru_selectBox" style="margin: 0">
+        <div
+          @click="getChoosePic(1)"
+          class="cru_select"
+          :class="chooseType == 1 ? 'cru_selected' : ''"
+        >
+          绘画
+        </div>
+        <div
+          @click="getChoosePic(2)"
+          class="cru_select"
+          :class="chooseType == 2 ? 'cru_selected' : ''"
+        >
+          科技
+        </div>
+        <div
+          @click="getChoosePic(3)"
+          class="cru_select"
+          :class="chooseType == 3 ? 'cru_selected' : ''"
+        >
+          人文
+        </div>
+        <div
+          @click="getChoosePic(4)"
+          class="cru_select"
+          :class="chooseType == 4 ? 'cru_selected' : ''"
+        >
+          艺术
+        </div>
+      </div>
+      <div class="sysPicBox">
+        <div v-for="(sys, sysIndex) in sysPic" :key="sysIndex" class="sysPic">
+          <img :src="sys.poster" alt="" @click="chooseSysPic(sys.poster)" />
+        </div>
+      </div>
+    </el-dialog>
+    <el-dialog
+      title="选择网络文件"
+      :visible.sync="sysPicVisible2"
+      :append-to-body="true"
+      width="710px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div>
+        <div
+          class="people_top_right"
+          style="display: flex;align-items: center;"
+        >
+          <div style="position: relative; width: 100%;">
+            <el-input
+              style="height: 100%"
+              placeholder="搜索图片关键字"
+              v-model="searchImageValue"
+              @keyup.enter.native="resetImage()"
+            ></el-input>
+            <div class="search_img" @click="resetImage" style="right: 10px;">
+              <img src="../../../assets/icon/search.png" alt />
+            </div>
+          </div>
+          <el-button
+            type="primary"
+            size="default"
+            style="margin-left: 10px;"
+            @click="changePicture"
+            >换一组</el-button
+          >
+        </div>
+        <div class="sysPicBox" v-loading="imageloading">
+          <div class="picNone" v-if="!imageList.length">
+            请输入关键词搜索图片
+          </div>
+          <div
+            v-for="(sys, sysIndex) in imageList"
+            :key="sysIndex"
+            class="sysPic"
+          >
+            <img :src="sys.url" alt="" @click="chooseSysPic2(sys.url)" />
+          </div>
+        </div>
+      </div>
+    </el-dialog>
+    <el-dialog
+      title="选择匹配"
+      :visible.sync="dialogVisibleSelect"
+      :append-to-body="true"
+      width="800px"
+      :before-close="
+        done => {
+          closePan(41);
+        }
+      "
+      class="dialog_diy dialog_diy3 fullStyle"
+    >
+      <div v-if="selectJson" style="height:100%">
+        <div class="select_box1" v-if="selectSteps == 1">
+          <div class="select_box1_img">
+            <div class="select_box1_title">
+              <span>上传题目图片</span
+              ><span>提示:请将所有题目上传为一张图片。</span>
+            </div>
+            <div class="select_box1_add_img">
+              <div
+                class="uploadFm"
+                @click="addImg($event)"
+                v-if="!selectJson.url"
+              >
+                <input
+                  type="file"
+                  accept="image/*"
+                  style="display: none"
+                  @change="beforeUploadSelect"
+                />
+                <img src="../../../assets/icon/addPoster.png" alt="" />
+              </div>
+              <div class="isSysPic" v-else>
+                <img
+                  :src="selectJson.url"
+                  alt=""
+                  @click="previewImg(selectJson.url)"
+                />
+                <div class="deletePic" @click="deleteSelectPic">
+                  <img src="../../../assets/icon/delete.png" alt="" />
+                </div>
+              </div>
+            </div>
+          </div>
+          <div class="select_box1_select">
+            <div class="select_box1_title">
+              <span>添加选项</span
+              ><span
+                >提示:请输入以上题目的选项内容,此选项为所有题目共享。</span
+              >
+            </div>
+            <div class="select_box1_select_box">
+              <el-input
+                v-for="(item2, checkIndex) in selectJson.select"
+                :key="checkIndex"
+                v-model="selectJson.select[checkIndex]"
+                placeholder="请输入选项"
+                style="width: 150px; margin: 10px 10px 0 0"
+              ></el-input>
+              <div class="select_box1_select_box_add">
+                <el-button
+                  style="margin: 10px 0px 0 0"
+                  type="primary"
+                  size="small"
+                  @click="addSelectList(selectJson)"
+                >
+                  添加</el-button
+                >
+                <el-button
+                  type="primary"
+                  size="small"
+                  style="margin: 10px 0 0 0"
+                  @click="deleteSelectList(selectJson)"
+                  v-if="selectJson.select && selectJson.select.length > 0"
+                  >删除</el-button
+                >
+              </div>
+            </div>
+          </div>
+        </div>
+        <div v-if="selectSteps == 2" style="height:100%">
+          <div class="select_box2">
+            <div class="select_box2_title">设置每道题目的正确选项</div>
+            <div class="select_box2_box">
+              <div class="select_box2_img">
+                <img
+                  :src="selectJson.url"
+                  alt=""
+                  @click="previewImg(selectJson.url)"
+                />
+              </div>
+              <div class="select_box2_answer">
+                <div class="select_answer_title">根据题目选择对应答案</div>
+                <div
+                  class="select_box2_answer_box"
+                  v-for="(item2, checkIndex) in selectJson.select"
+                  :key="checkIndex"
+                >
+                  <span>{{ checkIndex + 1 }}、</span>
+                  <el-select
+                    v-model="selectJson.answer[checkIndex]"
+                    placeholder="请选择正确答案"
+                  >
+                    <el-option
+                      v-for="(e, eIndex) in selectJson.select"
+                      :key="eIndex"
+                      :label="e"
+                      :value="eIndex"
+                    >
+                    </el-option>
+                  </el-select>
+                </div>
+              </div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button
+          type="primary"
+          @click="nextSelectSteps()"
+          v-if="selectSteps == 1"
+          >下一步</el-button
+        >
+        <el-button @click="selectSteps--" v-if="selectSteps == 2"
+          >上一步</el-button
+        >
+        <el-button
+          type="primary"
+          @click="addSelectAnswer"
+          v-if="selectSteps == 2"
+          >确 定</el-button
+        >
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加评价"
+      :visible.sync="dialogVisibleRate"
+      :append-to-body="true"
+      width="650px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div style="background: #fff; padding: 15px; box-sizing: border-box">
+        <div style="font-size: 18px; color: #a9a9a9">请输入个人评价指标:</div>
+        <div class="pjCss" style="width: 100%">
+          <div
+            v-if="rateJson.length"
+            class="elist_input"
+            style="height: 360px; overflow: auto"
+          >
+            <div
+              v-for="(eItem, eIndex) in rateJson"
+              :key="eIndex"
+              class="elist_input_box"
+            >
+              <span style="min-width: 100px; text-align: right"
+                >个人评价指标:</span
+              >
+              <input
+                type="input"
+                v-model="eItem.value"
+                placeholder="填写评价名称"
+              />
+              <div class="remove" @click="deletRateList(eIndex)"></div>
+              <div style="width: 100%; display: flex">
+                <span style="min-width: 100px; text-align: right"
+                  >评星等级:</span
+                >
+                <el-rate v-model="eItem.score" disabled></el-rate>
+              </div>
+              <div class="elist_inptu_text" style="align-items: flex-start">
+                <span style="min-width: 100px; text-align: right">描述:</span>
+                <textarea
+                  class="rate_textarea"
+                  :rows="3"
+                  v-model="eItem.detail"
+                  placeholder="填写评价描述"
+                ></textarea>
+              </div>
+            </div>
+          </div>
+          <div class="addToolFun" @click="addRateList()">
+            <div class="addToolImg">
+              <img src="../../../assets/icon/add.png" alt />
+            </div>
+            <div>添加</div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleRate = false">取 消</el-button>
+        <el-button type="primary" @click="addRateAnswer">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="排序设置"
+      :visible.sync="dialogVisibleSentence"
+      :append-to-body="true"
+      width="1000px"
+      :before-close="
+        done => {
+          closePan(47);
+        }
+      "
+      class="dialog_diy dialog_diy3 fullStyle"
+    >
+      <div style="height: 100%;">
+        <div class="sentenBox" style="height: 100%;">
+          <div class="addSen" @click="addSt">添加题目</div>
+          <div
+            v-for="(st, stIndex) in sentenceList"
+            :key="stIndex"
+            class="sentenContent"
+          >
+            <div class="sentenTopBox">
+              <div class="sentenTop" :index="stIndex + 1">
+                <div>题目设置</div>
+                <div>
+                  <el-input
+                    placeholder="请输入卡片内容"
+                    v-model="st.sentenceTitle"
+                    :maxlength="10"
+                  ></el-input>
+                </div>
+                <div @click="addSen(stIndex)">添加</div>
+                <div
+                  class="remove1"
+                  v-if="sentenceList.length > 1"
+                  @click="deleteSentence(stIndex)"
+                ></div>
+              </div>
+            </div>
+
+            <div class="cardList">
+              <div v-if="st.addSentence.length > 0" class="cardBox">
+                <div
+                  class="isCard"
+                  v-for="(s, sIndex) in st.addSentence"
+                  :key="sIndex"
+                  @click="setRightAnswer(s, stIndex, sIndex)"
+                >
+                  <el-tooltip
+                    class="item"
+                    effect="light"
+                    :content="s"
+                    placement="top"
+                  >
+                    <div>{{ s }}</div>
+                  </el-tooltip>
+                  <div
+                    class="deleteWord"
+                    @click.stop="deleteS(s, stIndex, sIndex)"
+                  >
+                    <img src="../../../assets/icon/delete.png" alt="" />
+                  </div>
+                </div>
+              </div>
+              <div class="card">
+                <img
+                  src="../../../assets/icon/conSentences/noTitle.png"
+                  alt=""
+                />
+              </div>
+            </div>
+            <div class="rightCardBox">
+              <div>正确顺序</div>
+              <div class="rightCardList">
+                <div v-if="st.rightAnswer.length > 0" class="cardBox">
+                  <div
+                    v-for="(r, rIndex) in st.rightAnswer"
+                    :key="rIndex"
+                    class="cardCss"
+                  >
+                    <div
+                      class="isCard1"
+                      @click="returnCard(r, stIndex, rIndex)"
+                    >
+                      <el-tooltip
+                        class="item"
+                        effect="light"
+                        :content="r"
+                        placement="top"
+                      >
+                        <div>{{ r }}</div>
+                      </el-tooltip>
+                    </div>
+                    <div>{{ rIndex + 1 }}</div>
+                  </div>
+                </div>
+                <div class="card" v-if="st.rightAnswer.length == 0">
+                  <img
+                    src="../../../assets/icon/conSentences/noAnswer.png"
+                    alt=""
+                  />
+                </div>
+                <div class="card" v-else>
+                  <img
+                    src="../../../assets/icon/conSentences/clickNo.png"
+                    alt=""
+                  />
+                </div>
+              </div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="closePan(47)">取 消</el-button>
+        <el-button type="primary" @click="addSentenceTool">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加表格"
+      :visible.sync="dialogVisibleTable"
+      :append-to-body="true"
+      width="95%"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <el-form>
+        <!-- <el-form-item label="文本标题">
+          <el-input v-model="AttText.title" auto-complete="off" @input="change2" placeholder="请输入文本标题..."></el-input>
+        </el-form-item> -->
+        <div>表格内容</div>
+        <Table v-model="tableJson.text" @change="change"></Table>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <!-- <el-button @click="dialogVisibleTable = false">取 消</el-button>
+        <el-button type="primary" @click="addTableJson">确定</el-button> -->
+        <el-button type="primary" @click="addTableJson">上传模板</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加文档"
+      :visible.sync="dialogVisibleWord"
+      :append-to-body="true"
+      width="95%"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <el-form>
+        <!-- <el-form-item label="文本标题">
+          <el-input v-model="AttText.title" auto-complete="off" @input="change2" placeholder="请输入文本标题..."></el-input>
+        </el-form-item> -->
+        <div>文档内容</div>
+        <editor-bar v-model="wordJson.text" class="text_panel"></editor-bar>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <!-- <el-button @click="dialogVisibleWord = false">取 消</el-button> -->
+        <el-button type="primary" @click="addWordJson">上传模板</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加班级"
+      :visible.sync="dialogVisibleMoreUpload"
+      :append-to-body="true"
+      width="30%"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div
+        style="
+          width: 100%;
+          display: flex;
+          flex-direction: row;
+          flex-wrap: nowrap;
+          align-items: center;
+          justify-content: center;
+        "
+      >
+        <div>班级:</div>
+        <el-select multiple v-model="uploadJson" placeholder="请选择">
+          <el-option
+            v-for="item in classJuri"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id"
+          >
+          </el-option>
+        </el-select>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleMoreUpload = false">取 消</el-button>
+        <el-button type="primary" @click="addMoreUpload">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="设置随机码"
+      :visible.sync="dialogVisibleInvite"
+      :append-to-body="true"
+      width="360px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div
+        style="
+          width: 100%;
+          display: flex;
+          flex-direction: row;
+          flex-wrap: nowrap;
+          align-items: center;
+          justify-content: center;
+        "
+      >
+        <div>随机码:</div>
+        <el-input
+          v-model="icode"
+          style="width: 240px"
+          placeholder="请输入随机码"
+        ></el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleInvite = false">取 消</el-button>
+        <el-button type="primary" @click="addInvite">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="添加预设时间"
+      :visible.sync="dialogVisiblePreTime"
+      :append-to-body="true"
+      width="450px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div>
+        <div style="margin-bottom: 20px;color: #999;">
+          提示:点击“+”或“-”修改倒计时时长。
+        </div>
+        <Time
+          :preTime="preTime"
+          @updateTimeNum="updateTime"
+          v-if="dialogVisiblePreTime"
+        ></Time>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisiblePreTime = false">取 消</el-button>
+        <el-button type="primary" @click="addPreTime">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="导入目标"
+      :visible.sync="dialogVisiblemb"
+      :append-to-body="true"
+      width="70%"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div>
+        <div
+          style="
+            width: 100%;
+            display: flex;
+            flex-direction: row;
+            flex-wrap: nowrap;
+            align-content: center;
+            align-items: center;
+            justify-content: space-between;
+          "
+        >
+          <div
+            style="
+              display: flex;
+              flex-flow: row nowrap;
+              align-items: flex-start;
+              width: 100%;
+              flex-direction: column;
+              flex-wrap: nowrap;
+              position: relative;
+            "
+          >
+            <div class="e_box">
+              <div class="e_card" v-for="(item, index) in evaJuri" :key="index">
+                <div class="e_card_picture">
+                  <img src="../../../assets/e_picture.png" />
+                </div>
+                <div class="e_card_name">
+                  <span>{{ item.title }}</span>
+                </div>
+                <div class="e_card_btn">
+                  <span @click="checkEva(item.id, 2)">导入</span>
+                </div>
+              </div>
+              <div class="addEva" @click="openT">
+                <img src="../../../assets/icon/addEva.png" alt="" />
+              </div>
+              <div
+                v-if="evaJuri.length === 0"
+                style="margin: 0 auto; color: #6e6e6e"
+              >
+                暂无数据
+              </div>
+            </div>
+          </div>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisiblemb = false">取 消</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="分组设置"
+      :visible.sync="dialogVisibleGroup"
+      :append-to-body="true"
+      width="650px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div class="groupBox">
+        <div v-if="groupJson.group" class="groupContent">
+          <div class="groupTitle">请设置小组数量及名称</div>
+          <div
+            v-for="(item, index) in groupJson.group"
+            :key="index"
+            class="groupName"
+          >
+            <span class="groupn">第{{ index + 1 }}组名称:</span>
+            <el-input
+              v-model="item.name"
+              placeholder="请输入名称..."
+              style="width: 250px"
+            ></el-input>
+            <div class="groupBtn">
+              <el-button
+                type="primary"
+                size="small"
+                @click="addGroup(index)"
+                v-if="groupJson.group.length - 1 == index"
+              >
+                添加</el-button
+              >
+              <el-button
+                type="primary"
+                size="small"
+                @click="deleteGroup(index)"
+                v-if="groupJson.group && groupJson.group.length > 1"
+                >删除</el-button
+              >
+            </div>
+          </div>
+        </div>
+        <div class="groupContent">
+          <div class="groupTitle">请设置每组人数</div>
+          <!-- <el-input v-model="groupJson.number" placeholder="2-10人以内"
+            style="width: 150px; margin: 10px 10px 0 0"></el-input> -->
+          <el-input
+            v-model="groupJson.number"
+            style="width:150px"
+            placeholder="请输入2-10的数字"
+            @change="numberPan"
+          ></el-input>
+        </div>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleGroup = false">取 消</el-button>
+        <el-button type="primary" @click="addGroupJson">确定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="修改名称"
+      :visible.sync="dialogVisibleupdataVideoT"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <div
+        style="
+          width: 100%;
+          display: flex;
+          flex-direction: row;
+          flex-wrap: nowrap;
+          align-items: center;
+          justify-content: center;
+        "
+      >
+        <div style="min-width: fit-content;">文件名称:</div>
+        <el-input v-model="line" placeholder="请输入要修改的名称"></el-input>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleupdataVideoT = false">取 消</el-button>
+        <el-button type="primary" @click="updataVideoC">确 定</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog
+      title="创建作文题目"
+      :visible.sync="englishDialogVisible"
+      :append-to-body="true"
+      width="800px"
+      :before-close="
+        done => {
+          closePan(69);
+        }
+      "
+      class="dialog_diy fullStyle fullStyle1"
+    >
+      <englishRight
+        :englishList="englishList"
+        :oid="oid"
+        ref="engJson"
+      ></englishRight>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="englishDialogVisible = false">取 消</el-button>
+        <el-button type="primary" @click="addEnglish">确 定</el-button>
+      </span>
+    </el-dialog>
+    <interVideo
+      :dialogVisibleVideo.sync="dialogVisibleVideo"
+      :videoJson="videoJson"
+      @add="addVideoJson"
+    ></interVideo>
+    <EnglishVoice
+      :oid="oid"
+      :org="org"
+      :EnglishVoiceDialog.sync="EnglishVoiceDialog"
+      :englishVoiceJson="englishVoiceJson"
+      @setEnglishVoiceJson="setEnglishVoiceJson"
+    ></EnglishVoice>
+    <appDialog ref="appDialog" @success="selectAppSuccess"></appDialog>
+    <CodeEditor ref="CodeEditorRef" @success="addHtmlSuccess"></CodeEditor>
+    <InteractiveToolDialog ref="InteractiveToolDialogRef" @addTool="addTool"/>
+  </div>
+</template>
+
+<script>
+import "../../../common/aws-sdk-2.235.1.min.js";
+import { tools as toolsData } from "../../../common/tools.js";
+import $ from "jquery";
+import EditorBar from "../../../components/tools/wangEnduit";
+import Table from "../../../components/tools/table";
+import Mind from "../../tools/jsmind2";
+import Time from "../../tools/time.vue";
+import Sunburst from "../../tools/sunburst";
+import SeeBoard from "../../tools/seeBoard";
+import weilaiData from "../components/weilai.js";
+import sourceDialog from "../teacherSource/dialog.vue";
+import interVideo from "../interVideo/index.vue";
+import englishRight from "./commpont/englishRight.vue";
+import EnglishVoice from "../EnglishVoice/index.vue";
+import appDialog from "../components/appDialog.vue";
+import { myMixin } from "@/mixins/mixin.js";
+import { uploadFileMixin } from "../../tools/uploadFileMixin.js";
+import CodeEditor from "../components/CodeEditor";
+import InteractiveToolDialog from "./dialog/InteractiveToolDialog.vue";
+import axios from 'axios'
+var OpenCC = require("opencc-js");
+let converter = OpenCC.Converter({
+  from: "hk",
+  to: "cn"
+});
+
+
+export default {
+  mixins: [myMixin, uploadFileMixin],
+  components: {
+    CodeEditor,
+    EditorBar,
+    Mind,
+    Time,
+    Sunburst,
+    SeeBoard,
+    Table,
+    sourceDialog,
+    interVideo,
+    englishRight,
+    EnglishVoice,
+    appDialog,
+    InteractiveToolDialog
+  },
+  data() {
+    return {
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
+      checkAll: false,
+      chooseType: 1,
+      checkedCities: [],
+      isIndeterminate: true,
+      isSysPic: false,
+      isSysPic2: false,
+      steps: 1,
+      nbOrder: 0,
+      courseId: "",
+      chapToolsType: 0,
+      chapTools: [
+        {
+          tools: [],
+          toolDetail: ""
+        }
+      ],
+      line: "",
+      lineTitle: "",
+      sysPic: [],
+      sentenceList: [{ sentenceTitle: "", addSentence: [], rightAnswer: [] }],
+      sentenceList2: [],
+      isPushTitleList: [],
+      lineCount: 0,
+      lineType: 0,
+      chapCount: 0,
+      courseName: "",
+      isTeacherSee: false,
+      courseText: "",
+      preTime: 0,
+      formLabelWidth: "100px",
+      choosePicVisible: false,
+      sysPicVisible: false,
+      uploadLoading1: false,
+      noneBtnImg: false,
+      updateBoolean2: false,
+      unitIndex: 0,
+      taskCount: 0,
+      dialogVisible: false,
+      dialogVisible1: false,
+      dialogVisible2: false,
+      dialogVisible3: false,
+      dialogVisible4: false,
+      dialogVisible5: false,
+      dialogVisible6: false,
+      dialogVisible7: false,
+      dialogVisible8: false,
+      dialogVisible9: false,
+      dialogVisibleClass: false,
+      dialogVisibleMember: false,
+      dialogVisibleMp3: false,
+      dialogVisibleSelect: false,
+      dialogVisibleSentence: false,
+      dialogVisibleRate: false,
+      dialogVisibleChoice: false,
+      dialogVisiblemb: false,
+      dialogVisibleInvite: false,
+      dialogVisibleSource: false,
+      dialogVisibleVideo: false,
+      dialogVisibleupdataVideoT: false,
+      isClickColor: 1,
+      toolIndexType: "",
+      publicTool: 0,
+      searchPeople: "",
+      searchTN: "",
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      role: this.$route.query.role,
+      cid: this.$route.query.cid != undefined ? this.$route.query.cid : "",
+      dialogVisibleTable: false,
+      dialogVisibleWord: false,
+      tableJson: { text: "" },
+      wordJson: { text: "" },
+      dialogVisibleMoreUpload: false,
+      dialogVisiblePreTime: false,
+      englishDialogVisible: false,
+      uploadJson: [],
+      classJuri: [],
+      gradeList: [],
+      cover: [], //课程封面
+      myWord: [],
+      evaJuri: [],
+      evalua: "",
+      targetArray: [],
+      eTitle: "",
+      eJson: {},
+      fid: "", //一级
+      sid: "", //二级
+      tid: "", //二级
+      typeMode: 1,
+      eJSONNum: 0,
+      data: {
+        meta: {
+          name: "example",
+          author: "dd@163.com",
+          version: "0.2"
+        },
+        format: "node_array",
+        data: [{ id: "root", isroot: true, topic: "" }]
+      },
+      askJson: {
+        askCount: 1,
+        askTitle: "",
+        askJson: [{ askstitle: "", askItem: 1, checkList: [] }]
+      },
+      askJson2: {},
+      testJson: {},
+      testJson2: {},
+      selectJson: {},
+      selectJson2: {},
+      englishList: {},
+      rateJson: [],
+      unitJson2: [],
+      unitJson: [
+        {
+          dyName: "", //单元标题
+          chapterInfo: [
+            {
+              isread: false,
+              chapterid: this.guid(),
+              title: "",
+              courseName: "",
+              taskJson: [
+                {
+                  task: "",
+                  taskDetail: "",
+                  chapterData: [],
+                  toolChoose: [
+                    {
+                      tool: [],
+                      toolDetail: "",
+                      toolType: 0,
+                      askCount: 1,
+                      askTitle: "",
+                      askJson: [{ askstitle: "", askItem: 1, checkList: [] }]
+                    }
+                  ],
+                  toolText: "",
+                  isShowTools: false,
+                  askCount: 1,
+                  isFold: 1,
+                  askTitle: "",
+                  askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+                  checkJson: [{ checkCount: [], checkPerent: [] }],
+                  homeworkList: []
+                }
+              ],
+              itemCount: 1,
+              fileList1: [],
+              video: [],
+              testData: [],
+              pData: [],
+              templateArray: []
+            }
+          ]
+        }
+      ],
+      templateArray: [],
+      studentJuri: [],
+      teacherJuri: [],
+      checkboxList: [],
+      checkboxList2: [],
+      checkboxList3: [],
+      classSearch: "",
+      gradeId: "",
+      number: "",
+      tTitle: "",
+      tdetail: "",
+      templateC: {},
+      AttText: {},
+      AttTextType: 0,
+      AttTextIndex: 0,
+      cTemplate: "",
+      CourseType: [],
+      CourseType2: [],
+      CourseTypeJson: {},
+      courseTypeId: [],
+      courseTypeSon: [],
+      clearArray: [],
+      pTypeCheck: [],
+      pTypeCheckName: [],
+      loading: false,
+      toolType: 0,
+      inputShow: true,
+      inputShow2: true,
+      toolIndex: 0,
+      cidType: 0,
+      answerQ: "",
+      answerQ2: "",
+      grade: [],
+      grade2: [],
+      courseUserid: "",
+      timer: null,
+      timer2: null,
+      pasteTimer: null,
+      checkId: "",
+      isDelete: 1,
+      addindex: 0,
+      selectSteps: 1,
+      groupJson: {},
+      dialogVisibleGroup: false,
+      rightBoxHeight: 0,
+      ManAarray: [],
+      checkBoolean: false,
+      inviteCode: [],
+      inviteId: "",
+      icode: "",
+      easyArray: [2, 4],
+      sourceData: {},
+      updateSourcePan: false,
+      videoJson: {},
+      isBtnDisplay: false,
+      isPasteTask: false,
+      isPasteChoice: false,
+      sysPicVisible2: false,
+      imageloading: false,
+      searchImageValue: "",
+      ppage: 1,
+      imageList: [],
+      heightPx: "100%",
+      toolsData: JSON.parse(converter(JSON.stringify(toolsData))),
+      oldIndex: 0,
+      oldData: null,
+      newIndex: "",
+      typeIndex: "",
+      isdrag: "",
+      EnglishVoiceDialog: false,
+      englishVoiceJson: {},
+      optionTypeList: [
+        "A",
+        "B",
+        "C",
+        "D",
+        "E",
+        "F",
+        "G",
+        "H",
+        "I",
+        "J",
+        "K",
+        "L",
+        "M",
+        "N",
+        "O",
+        "P",
+        "Q",
+        "R",
+        "S",
+        "T",
+        "U",
+        "V",
+        "W",
+        "X",
+        "Y",
+        "Z"
+      ],
+      pptCourseJson:{
+        pptData:"",
+        toolsList:[],
+      },
+      filterToolType:"",
+      testJsonName:"",
+      testJsonBrief:"",
+      editId:"",
+      iframeIsLoad:false,
+      uploadWorkLoading:false,
+    };
+  },
+  directives: {
+    autoHeight: {
+      update(el, binding) {
+        const { value } = binding;
+        if (value && typeof value === "number") {
+          el.style.height = `${value}px`;
+        } else {
+          el.style.height = "auto";
+        }
+      },
+      componentUpdated(el) {
+        el.style.height = `${el.scrollHeight + 5}px`;
+      }
+    }
+  },
+  computed: {
+
+    offsetLetfPx: function() {
+      //addnum可以直接在模板语法里面用,相当于data内的值
+      return (
+        $(".cru_select")[this.unitIndex] &&
+        $(".cru_select")[this.unitIndex].offsetLeft
+      );
+    },
+    getMan2() {
+      return function(people) {
+        let _people = people;
+        let _people2 = "";
+        if (this.ManAarray.length) {
+          for (var i = 0; i < this.ManAarray.length; i++) {
+            if (this.ManAarray[i].userid == people) {
+              _people2 = this.ManAarray[i].name;
+              break;
+            }
+          }
+        }
+        if (people == this.courseUserid) {
+          return "";
+        }
+        return this.ManAarray.length ? _people2 : "";
+      };
+    },
+    isInvite() {
+      return function(cid) {
+        let array = [];
+        for (var i = 0; i < this.inviteCode.length; i++) {
+          array.push(this.inviteCode[i].cid);
+        }
+        return array.indexOf(cid) != -1;
+      };
+    },
+    getInviteCodeC() {
+      return function(cid) {
+        let array = [];
+        for (var i = 0; i < this.inviteCode.length; i++) {
+          array.push(this.inviteCode[i].cid);
+        }
+        return this.inviteCode[array.indexOf(cid)].ic;
+      };
+    },
+    getClassC() {
+      return function(c) {
+        let _c2 = "";
+        if (this.grade.length) {
+          for (var i = 0; i < this.grade.length; i++) {
+            if (this.grade[i].id == c) {
+              _c2 = this.grade[i].name;
+              break;
+            }
+          }
+        }
+        return this.grade.length ? _c2 : "";
+      };
+    },
+    getListClassC() {
+      return function(list) {
+        let _c2 = [];
+
+        if (this.grade.length) {
+          for (var j = 0; j < list.length; j++) {
+            let c = list[j];
+            for (var i = 0; i < this.grade.length; i++) {
+              if (this.grade[i].id == c) {
+                _c2.push(this.grade[i].name);
+                break;
+              }
+            }
+          }
+        }
+        return this.grade.length ? _c2.join("、") : "";
+      };
+    }
+  },
+  watch: {
+    steps(newValue) {
+      if (newValue == 4) {
+        if (this.org == "16ace517-b5c7-4168-a9bb-a9e0035df840") {
+          window.topU.U.UF.F.closeWindow(window.topU.$("#openCourseUpdate"));
+        }
+        this.goTo(
+          "/course?userid=" +
+            this.userid +
+            "&oid=" +
+            this.oid +
+            "&org=" +
+            this.org +
+            "&role=" +
+            this.role
+        );
+      }
+    }
+  },
+  methods: {
+    openAI() {
+      window.topU.postMessage({ tools: "64" }, "*");
+    },
+    setMan() {
+      // let teacherJuri = this.teacherJuri2;
+      this.ManAarray = [];
+      let _user = JSON.parse(JSON.stringify(this.checkboxList3));
+      if (_user.indexOf(this.userid) == -1) {
+        _user.push(this.userid);
+      }
+      if (_user.indexOf(this.courseUserid) == -1) {
+        _user.push(this.courseUserid);
+      }
+      let params = [
+        {
+          uid: _user.join(",")
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "getAllUserByIdP", params)
+        .then(res => {
+          let teacherJuri = res.data[0];
+          this.ManAarray = teacherJuri;
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    previewImg(url) {
+      this.$hevueImgPreview(url);
+    },
+    btnDisplay(bool) {
+      this.isBtnDisplay = bool;
+    },
+    scrollChange() {
+
+    },
+    addHw(e) {
+      var el = e.currentTarget;
+      el.getElementsByTagName("input")[0].click();
+    },
+    change(val) {
+      if (this.dialogVisible1) {
+        this.tdetail = val;
+      } else if (this.dialogVisible6) {
+        this.AttText.text = val;
+      } else if (this.dialogVisible2) {
+        this.cTemplate = val;
+      } else if (this.dialogVisibleTable) {
+        this.tableJson.text = val;
+      }
+      this.$forceUpdate();
+      console.log(val);
+    },
+    change2(val) {
+      console.log(val);
+      this.$forceUpdate();
+    },
+    handleClose(done) {
+      done();
+    },
+    closePan(tool) {
+      if (tool == 15) {
+        if (JSON.stringify(this.answerQ) == JSON.stringify(this.answerQ2)) {
+          this.dialogVisible8 = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      } else if (tool == 4) {
+        if (JSON.stringify(this.askJson) == JSON.stringify(this.askJson2)) {
+          this.dialogVisible5 = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      } else if (tool == 45) {
+        if (JSON.stringify(this.testJson) == JSON.stringify(this.testJson2)) {
+          this.dialogVisibleChoice = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      } else if (tool == 41) {
+        if (
+          JSON.stringify(this.selectJson) == JSON.stringify(this.selectJson2)
+        ) {
+          this.dialogVisibleSelect = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      } else if (tool == 47) {
+        if (
+          JSON.stringify(this.sentenceList) ==
+          JSON.stringify(this.sentenceList2)
+        ) {
+          this.dialogVisibleSentence = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      } else if (tool == 69) {
+        if (
+          JSON.stringify(this.englishList) == JSON.stringify(this.englishList)
+        ) {
+          this.englishDialogVisible = false;
+        } else {
+          this.closeConfirm(tool);
+        }
+      }
+    },
+    closeConfirm(tool) {
+      this.$confirm("是否保存已编辑内容?", "提示", {
+        confirmButtonText: "保存",
+        cancelButtonText: "不保存",
+        type: "warning"
+      })
+        .then(() => {
+          if (tool == 15) {
+            this.addAnswer();
+          } else if (tool == 4) {
+            this.addAsk();
+          } else if (tool == 45) {
+            this.addTest();
+          } else if (tool == 41) {
+            this.addSelectAnswer();
+          } else if (tool == 47) {
+            this.addSentenceTool();
+          } else if (tool == 69) {
+            this.addEnglish();
+          }
+        })
+        .catch(() => {
+          if (tool == 15) {
+            this.dialogVisible8 = false;
+            this.editId = null;
+          } else if (tool == 4) {
+            this.dialogVisible5 = false;
+          } else if (tool == 45) {
+            this.dialogVisibleChoice = false;
+            this.editId = null;
+          } else if (tool == 41) {
+            this.dialogVisibleSelect = false;
+          } else if (tool == 47) {
+            this.dialogVisibleSentence = false;
+          } else if (tool == 69) {
+            this.englishDialogVisible = false;
+          }
+        });
+    },
+    addEnglish() {
+      this.englishList.engTitle = this.$refs["engJson"].engList.engTitle;
+      this.englishList.englishText = this.$refs["engJson"].engList.englishText;
+      this.englishList.textJson = this.$refs["engJson"].engList.textJson;
+      if (
+        this.englishList.engTitle == "" ||
+        this.englishList.englishText == ""
+      ) {
+        this.$message.error("请将内容填写完整!");
+        return;
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].englishList = this.englishList;
+      this.englishList = {};
+      this.englishDialogVisible = false;
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 69
+      ) {
+        this.addTools(69, this.taskCount, this.toolIndex);
+      }
+    },
+    imgChange2(i, j) {
+      var _tmp = this.testJson.testJson[i].checkList[j];
+      this.noneBtnImg = _tmp.length >= 1;
+    },
+    imgChange3(i) {
+      var _tmp = this.testJson.testJson[i];
+      this.noneBtnImg = _tmp.length >= 1;
+    },
+    imgChange1(file, fileList, type, itemTaskIndex) {
+      if (type == 1) {
+        var _tmp = this.cover;
+      } else if (
+        type == 2 ||
+        type == 3 ||
+        type == 6 ||
+        type == 7 ||
+        type == 8
+      ) {
+        var _tmp = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].chapterData;
+      } else if (type == 4) {
+        var _tmp = this.unitJson[this.unitIndex].chapterInfo[0].fileList1;
+      } else {
+        var _tmp = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].homeworkList;
+      }
+      this.noneBtnImg = _tmp.length >= 1;
+    },
+    goTo(path) {
+      this.$router.push(path);
+    },
+    guid() {
+      var _num,
+        i,
+        _guid = "";
+      for (i = 0; i < 32; i++) {
+        _guid += Math.floor(Math.random() * 16).toString(16); //随机0  - 16 的数字 转变为16进制的字符串
+        _num = Math.floor((i - 7) / 4); //计算 (i-7)除4
+        if (_num > -1 && _num < 4 && i == 7 + 4 * _num) {
+          //会使guid中间加 "-"   形式为xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
+          _guid += "-";
+        }
+      }
+      return _guid;
+    },
+    lastSteps() {
+      this.$confirm("是否保存已编辑内容?", "提示", {
+        confirmButtonText: "保存",
+        cancelButtonText: "不保存",
+        distinguishCancelAndClose: true,
+        type: "warning"
+      })
+        .then(() => {
+          console.log("保存已编辑内容");
+          if (this.cid == "" || this.cid == undefined) {
+            if (this.courseName == "") {
+              this.$message.error("请补充填写课程名称");
+              return;
+            } else {
+              this.addWork();
+            }
+          } else {
+            if (this.courseName == "") {
+              this.$message.error("请补充填写课程名称");
+              return;
+            } else {
+              // if (this.userid != this.courseUserid && this.role != "1") {
+              //   this.updateWork2();
+              // } else {
+                this.updateWork();
+              // }
+            }
+          }
+        })
+        .catch(v => {
+          console.log(v);
+          if (v == "cancel") {
+            this.goTo(
+              "/course?userid=" +
+                this.userid +
+                "&oid=" +
+                this.oid +
+                "&org=" +
+                this.org +
+                "&role=" +
+                this.role
+            );
+          }
+        });
+    },
+    nextSteps() {
+      if (this.cid == "" || this.cid == undefined) {
+        if (this.courseName == "") {
+          this.$message.error("请补充填写课程名称");
+          return;
+        } else {
+          this.addWork();
+        }
+      } else {
+        if (this.courseName == "") {
+          this.$message.error("请补充填写课程名称");
+          return;
+        } else {
+          console.log("修改课程");
+          // if (this.userid != this.courseUserid && this.role != "1") {
+          //   this.updateWork2();
+          // } else {
+          this.updateWork();
+          // }
+        }
+      }
+      this.$refs.stepBox.scrollTop = 0;
+    },
+    unitSet(i) {
+      this.unitIndex = i;
+      // this.$refs.rightboxR.scrollTop = 0;
+    },
+    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;
+        }
+      }
+    },
+    deleteUnit(i) {
+      var _this = this;
+      if (_this.time()) {
+        _this
+          .$confirm("确定删除此单元吗?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          })
+          .then(() => {
+            _this.isDelete = 2;
+            // _this.unitIndex = _this.unitIndex - 1;
+            _this.deleteWork(_this.unitJson[i].chapterInfo[0].chapterid);
+            // _this.$message.success("删除成功");
+          })
+          .catch(() => {
+            return;
+          });
+      }
+    },
+    deleteWork(chapid) {
+      let params = [
+        {
+          cid: this.cid,
+          chapters: JSON.stringify(this.unitJson),
+          uid: this.userid,
+          chapid: chapid
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "deleteWork", params)
+        .then(res => {
+          this.$message({
+            message: "删除成功",
+            type: "success"
+          });
+          this.unitJson.splice(this.unitIndex, 1);
+          this.unitIndex = this.unitIndex - 1;
+        })
+        .catch(err => {
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    deleteTool(itemTaskIndex, i) {
+      var _this = this;
+      if (_this.time()) {
+        _this
+          .$confirm("确定删除此工具吗?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          })
+          .then(() => {
+            _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].toolChoose.splice(i, 1);
+            _this.$message.success("删除成功");
+          })
+          .catch(() => {
+            return;
+          });
+      }
+    },
+    deleteSentence(i) {
+      var _this = this;
+      _this
+        .$confirm("确定删除此题目吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.sentenceList.splice(i, 1);
+          _this.$message.success("删除成功");
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    deleteS(s, i, j) {
+      this.sentenceList[i].addSentence.splice(j, 1);
+      if (this.sentenceList[i].rightAnswer.indexOf(s) != -1) {
+        var a = this.sentenceList[i].rightAnswer.indexOf(s);
+        this.sentenceList[i].rightAnswer.splice(a, 1);
+      }
+    },
+    openT() {
+      window.topU.postMessage({ tools: "25" }, "*");
+    },
+    deleteTask(i) {
+      var _this = this;
+      //((_this.unitJson[_this.unitIndex].chapterInfo[0].taskJson.length - 1) == i) ? "确定删除此任务吗?" : "切换任务顺序将删除所有工具的提交成果,是否继续此操作?"
+      _this
+        .$confirm("确定删除此任务吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          if (i == 0) {
+            _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+              i + 1
+            ].chapterData = JSON.parse(
+              JSON.stringify(
+                _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[i]
+                  .chapterData
+              )
+            );
+          }
+          _this.$forceUpdate();
+          _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson.splice(i, 1);
+          _this.$message.success("删除成功");
+
+          // this.$nextTick(() => {
+          //   $('.stepsBottom2')[0].style.transition = 'unset'
+          //   setTimeout(() => {
+          //     let stepsBottom2 = $(".stepsBottom2")[0].clientHeight
+          //     let client = $(".basic_box2")[0].clientHeight - stepsBottom2 - 100
+          //     let top = $('.stepsBottom2')[0].offsetTop - 20
+          //     if (top > client) {
+          //       $('.stepsBottom2')[0].style.top = client + 'px'
+          //     }
+          //     $('.stepsBottom2')[0].style.transition = 'all .5s'
+          //     this.$forceUpdate()
+          //   }, 500)
+          // })
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    handlePictureCardPreview(file) {
+      this.dialogImageUrl = file.url;
+    },
+    clean(i, c) {
+      this.unitJson[this.unitIndex].chapterInfo[i].fileList1.splice(c, 1);
+    },
+    handle_remove1(file, fileList, type) {
+      var _tmp = this.cover;
+      // for (var i = 0, len = _tmp.length; i < len; i++) {
+      //   if (_tmp[i].uid == file.uid) {
+      //     _tmp.splice(i, 1);
+      //     break;
+      //   }
+      //   this.cover = _tmp;
+      // }
+      this.cover = [];
+      this.noneBtnImg = this.cover.length >= 1;
+      this.isSysPic = false;
+      this.isSysPic2 = false;
+      this.$forceUpdate();
+    },
+    addImg(e) {
+      var el = e.currentTarget;
+      el.getElementsByTagName("input")[0].click();
+      e.target.value = "";
+    },
+    addChaptersTools(i) {
+      this.chapTools = [
+        {
+          tools: [],
+          toolDetail: ""
+        }
+      ];
+      this.chapCount = i;
+      this.dialogVisible4 = true;
+    },
+    isNoFinsh() {
+      this.$message.warning("功能正在开发中");
+    },
+    addAttText(i) {
+      this.AttText = {
+        title: "",
+        text: ""
+      };
+      this.taskCount = i;
+      this.AttTextType = 0;
+      this.$forceUpdate();
+      this.dialogVisible6 = true;
+      setTimeout(() => {
+        this.$refs["fuInput"].focus();
+      }, 100);
+    },
+    openLine(i) {
+      this.line = "";
+      this.lineCount = i;
+      this.lineType = 0;
+      this.$forceUpdate();
+      this.dialogVisible7 = true;
+    },
+    pasteLine(i) {
+      navigator.clipboard
+        .readText()
+        .then(v => {
+          console.log("获取剪贴板成功:", v);
+          const html = v;
+          const regex = /src="(.*?)"/g;
+          const match = regex.exec(html);
+          if (match && match[1]) {
+            console.log(match[1]);
+            this.$message.success("粘贴成功");
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              i
+            ].chapterData.push({
+              name: "链接",
+              title: "嵌入代码",
+              url: match[1],
+              type: 8
+            });
+          } else {
+            // console.log("未找到包含 src 属性的 iframe");
+            this.$message.error(
+              "系统没有找到粘贴对象,请首先复制可用于粘贴的链接。"
+            );
+          }
+        })
+        .catch(v => {
+          console.log("获取剪贴板失败: ", v);
+        });
+    },
+    openSource(i) {
+      this.lineCount = i;
+      this.sourceData = {};
+      this.dialogVisibleSource = true;
+      this.updateSourcePan = false;
+    },
+    addSource() {
+      if (!Object.keys(this.sourceData).length) {
+        this.$message.error("请选择要上传的资源");
+        return;
+      }
+      let keys = Object.keys(this.sourceData);
+      for (var i = 0; i < keys.length; i++) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.lineCount
+        ].chapterData.push({
+          name: "链接",
+          title: this.sourceData[keys[i]].name,
+          url: this.sourceData[keys[i]].url,
+          type: 14,
+          id: keys[i]
+        });
+      }
+      this.$forceUpdate();
+      this.dialogVisibleSource = false;
+    },
+    updateSource() {
+      if (!Object.keys(this.sourceData).length) {
+        this.$message.error("请选择要上传的资源");
+        return;
+      }
+      let keys = Object.keys(this.sourceData);
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].url = this.sourceData[keys[0]].url;
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].title = this.sourceData[keys[0]].name;
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].id = keys[0];
+      this.updateSourcePan = false;
+      this.$forceUpdate();
+      this.dialogVisibleSource = false;
+    },
+    deleteM(i, j) {
+      this.testJson.testJson[i].timuList.splice(j, 1);
+    },
+    beforeUploadTiMu(event, i) {
+      const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            loading.close();
+            if (err) {
+              _this.$message.error("上传失败");
+            } else {
+              if (_this.testJson.testJson[i].timuList) {
+                _this.testJson.testJson[i].timuList.push({
+                  src: data.Location
+                });
+              } else {
+                _this.testJson.testJson[i].timuList = [];
+                _this.testJson.testJson[i].timuList.push({
+                  src: data.Location
+                });
+              }
+              _this.imgChange3(i);
+              _this.$forceUpdate();
+            }
+          });
+      }
+    },
+    beforeUploadTi(event, i, j) {
+      const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            loading.close();
+            if (err) {
+              _this.$message.error("上传失败");
+            } else {
+              _this.testJson.testJson[i].checkList[j] = {};
+              _this.testJson.testJson[i].checkList[j].src = data.Location;
+              _this.testJson.testJson[i].checkList[j].imgType = 1;
+              _this.imgChange2(i, j);
+              _this.$forceUpdate();
+            }
+          });
+      }
+    },
+    beforeUpload1(event, type) {
+      // const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            // loading.close();
+            if (err) {
+              // var a = _this.$refs.upload1.uploadFiles;
+              // a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败");
+            } else {
+              _this.cover = [
+                {
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                }
+              ];
+              _this.imgChange1(null, null, 1, null);
+              _this.choosePicVisible = false;
+              console.log(data.Location);
+            }
+          });
+      }
+    },
+    beforeUploadSelect(event, type) {
+      // const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            // loading.close();
+            if (err) {
+              _this.$message.error("上传失败");
+            } else {
+              _this.selectJson.url = data.Location;
+              console.log(data.Location);
+            }
+          });
+      }
+    },
+    chooseSysPic(p) {
+      this.cover = [];
+      setTimeout(() => {
+        this.cover[0] = {
+          name: "系统图片.png",
+          url: p
+        };
+        this.imgChange1(null, null, 1, null);
+        this.$forceUpdate();
+      }, 0);
+      this.isSysPic = true;
+      this.isSysPic2 = false;
+      this.sysPicVisible = false;
+      this.$forceUpdate();
+    },
+    chooseSysPic2(p) {
+      this.cover = [];
+      setTimeout(() => {
+        this.cover[0] = {
+          name: "网络图片.png",
+          url: p
+        };
+        this.imgChange1(null, null, 1, null);
+        this.$forceUpdate();
+      }, 0);
+      this.isSysPic2 = true;
+      this.isSysPic = false;
+      this.sysPicVisible2 = false;
+      this.$forceUpdate();
+    },
+    beforeUpload(data) {
+      this.$refs.upload1.uploadFiles;
+      this.uploadLoading1 = true;
+      var file = data.file;
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            _this.uploadLoading1 = false;
+            if (err) {
+              // var a = _this.$refs.upload1.uploadFiles;
+              // a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败");
+            } else {
+              //上传成功处理
+              _this.unitJson[_this.unitIndex].chapterInfo[0].fileList1.push({
+                name: file.name,
+                url: data.Location,
+                uid: file.uid
+              });
+              _this.imgChange();
+              console.log(data.Location);
+            }
+          });
+      }
+    },
+    onExceed() {
+      this.$message.error("课程封面仅支持上传一张,请删除后再进行上传");
+    },
+    beforeUpload2(event, unitIndex, type, itemTaskIndex) {
+      // const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+      if (type == 3) {
+        var b = [
+          "DOC",
+          "DOCX",
+          "DOCM",
+          "DOTM",
+          "DOTX",
+          "PPTX",
+          "PPSX",
+          "PPT",
+          "PPS",
+          "PPTM",
+          "POTM",
+          "PPAM",
+          "POTX",
+          "PPSM",
+          "XLSX",
+          "XLS"
+        ];
+        if (
+          b.indexOf(
+            file.name
+              .split(".")
+              [file.name.split(".").length - 1].toLocaleUpperCase()
+          ) != -1
+        ) {
+          if (file.size / 1024 / 1024 > 80) {
+            this.$message.error("上传文件大于80兆,请重新选择文件!");
+            this.inputShow = true;
+            // var a = _this.$refs.upload1.uploadFiles;
+            // a.splice(a.length - 1, a.length);
+            // loading.close();
+            return;
+          }
+        } else if (
+          file.name
+            .split(".")
+            [file.name.split(".").length - 1].toLocaleUpperCase() != "PDF"
+        ) {
+          if (file.size / 1024 / 1024 > 80) {
+            this.$message.error("添加成上传文件大于80兆,请重新选择文件!");
+            this.inputShow = true;
+            // var a = _this.$refs.upload1.uploadFiles;
+            // a.splice(a.length - 1, a.length);
+            // loading.close();
+            return;
+          }
+        }
+      }
+      this.inputShow = false;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].progress = 0;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].proVisible = true;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].isFinishSize = 0;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].isAllSize = (file.size / 1024 / 1024).toFixed(2);
+      _this.$forceUpdate();
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].progress = parseInt((evt.loaded / evt.total) * 100);
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].isFinishSize = (evt.loaded / 1024 / 1024).toFixed(2);
+            _this.$forceUpdate();
+          })
+          .send(function(err, data) {
+            // loading.close();
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].progress = 100;
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].isFinishSize =
+              _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].isAllSize;
+            _this.$forceUpdate();
+            setTimeout(() => {
+              _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].proVisible = false;
+              _this.$forceUpdate();
+            }, 1000);
+            _this.inputShow = true;
+            if (err) {
+              // var a = _this.$refs.upload1.uploadFiles;
+              // a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败");
+            } else {
+              if (type == 13) {
+                let _type = 2;
+                var imgA = [
+                  "png",
+                  "jpg",
+                  "jpeg",
+                  "bmp",
+                  "gif",
+                  "webp",
+                  "psd",
+                  "svg",
+                  "tiff"
+                ];
+                var fileA = [
+                  "PDF",
+                  "DOC",
+                  "DOCX",
+                  "DOCM",
+                  "DOTM",
+                  "DOTX",
+                  "PPTX",
+                  "PPSX",
+                  "PPT",
+                  "PPS",
+                  "PPTM",
+                  "POTM",
+                  "PPAM",
+                  "POTX",
+                  "PPSM",
+                  "XLSX",
+                  "XLS"
+                ];
+                var videoA = [
+                  "AVI",
+                  "NAVI",
+                  "MPEG",
+                  "ASF",
+                  "MOV",
+                  "WMV",
+                  "3GP",
+                  "RM",
+                  "RMVB",
+                  "FLV",
+                  "F4V",
+                  "H.264",
+                  "H.265",
+                  "REAL VIDEO",
+                  "MKV",
+                  "WebM",
+                  "HDDVD",
+                  "MP4",
+                  "MPG",
+                  "M4V",
+                  "MGV",
+                  "OGV",
+                  "QTM",
+                  "STR",
+                  "AMC",
+                  "DVX",
+                  "EVO",
+                  "DAT",
+                  "OGG",
+                  "OGM"
+                ];
+                if (
+                  fileA.indexOf(
+                    data.Location.split(".")[
+                      data.Location.split(".").length - 1
+                    ].toLocaleUpperCase()
+                  ) != -1
+                ) {
+                  _type = 3;
+                } else if (
+                  videoA.indexOf(
+                    data.Location.split(".")[
+                      data.Location.split(".").length - 1
+                    ].toLocaleUpperCase()
+                  ) != -1
+                ) {
+                  _type = 2;
+                } else if (
+                  imgA.indexOf(
+                    data.Location.split(".")[
+                      data.Location.split(".").length - 1
+                    ].toLocaleLowerCase()
+                  ) != -1
+                ) {
+                  _type = 13;
+                } else {
+                  _type = 12;
+                }
+                _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].chapterData.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid,
+                  type: _type
+                });
+                _this.imgChange1(null, null, _type, itemTaskIndex);
+              } else if (type == 2 || type == 3 || type == 12) {
+                _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].chapterData.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid,
+                  type: type
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              } else if (type == 4) {
+                _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].fileList1.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              } else if (type == 5) {
+                _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].homeworkList.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              }
+              console.log(data.Location);
+            }
+          });
+      }
+    },
+    beforeUpload3(event, unitIndex, type, itemTaskIndex, string) {
+      // const loading = this.openLoading();
+      var file = event.target.files[0];
+      var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+      if (type == 3) {
+        var b = [
+          "DOC",
+          "DOCX",
+          "DOCM",
+          "DOTM",
+          "DOTX",
+          "PPTX",
+          "PPSX",
+          "PPT",
+          "PPS",
+          "PPTM",
+          "POTM",
+          "PPAM",
+          "POTX",
+          "PPSM"
+        ];
+        if (
+          b.indexOf(
+            file.name
+              .split(".")
+              [file.name.split(".").length - 1].toLocaleUpperCase()
+          ) != -1
+        ) {
+          if (file.size / 1024 / 1024 > 80) {
+            this.$message.error("上传文件大于80兆,请重新选择文件!");
+            this.inputShow = true;
+            // var a = _this.$refs.upload1.uploadFiles;
+            // a.splice(a.length - 1, a.length);
+            // loading.close();
+            return;
+          }
+        } else if (
+          file.name
+            .split(".")
+            [file.name.split(".").length - 1].toLocaleUpperCase() != "PDF"
+        ) {
+          if (file.size / 1024 / 1024 > 80) {
+            this.$message.error("添加成上传文件大于80兆,请重新选择文件!");
+            this.inputShow = true;
+            // var a = _this.$refs.upload1.uploadFiles;
+            // a.splice(a.length - 1, a.length);
+            // loading.close();
+            return;
+          }
+        }
+      }
+      this.inputShow = false;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].progress = 0;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].proVisible = true;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].isFinishSize = 0;
+      _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].isAllSize = (file.size / 1024 / 1024).toFixed(2);
+      _this.$forceUpdate();
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].progress = parseInt((evt.loaded / evt.total) * 100);
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].isFinishSize = (evt.loaded / 1024 / 1024).toFixed(2);
+            _this.$forceUpdate();
+          })
+          .send(function(err, data) {
+            // loading.close();
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].progress = 100;
+            _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].isFinishSize =
+              _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].isAllSize;
+            _this.$forceUpdate();
+            setTimeout(() => {
+              _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].proVisible = false;
+              _this.$forceUpdate();
+            }, 1000);
+            _this.inputShow = true;
+            if (err) {
+              // var a = _this.$refs.upload1.uploadFiles;
+              // a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败");
+            } else {
+              if (type == 2 || type == 3) {
+                _this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].chapterData.push({
+                  name: file.name,
+                  // name: string+''+(_this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                  //   itemTaskIndex
+                  // ].chapterData.length+1),
+                  url: data.Location,
+                  uid: file.uid,
+                  type: type,
+                  text: string
+                  // text: string + '' + (_this.unitJson[unitIndex].chapterInfo[0].taskJson[
+                  //   itemTaskIndex
+                  // ].chapterData.length + 1),
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              } else if (type == 4) {
+                _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].fileList1.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              } else if (type == 5) {
+                _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].homeworkList.push({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                });
+                _this.imgChange1(null, null, type, itemTaskIndex);
+              }
+              console.log(data.Location);
+            }
+          });
+      }
+    },
+    addunit() {
+      this.unitJson.push({
+        dyName: "", //单元标题
+        isUpdate: 1,
+        easy: this.unitJson[this.unitJson.length - 1].easy ? 1 : 0,
+        chapterInfo: [
+          {
+            isread: false,
+            chapterid: this.guid(),
+            title: "",
+            courseName: "",
+            taskJson: [
+              {
+                task: "",
+                taskDetail: "",
+                chapterData: [],
+                toolText: "",
+                toolChoose: [
+                  {
+                    tool: [],
+                    toolDetail: "",
+                    toolType: 0,
+                    askCount: 1,
+                    askTitle: "",
+                    askJson: [{ askstitle: "", askItem: 1, checkList: [] }]
+                  }
+                ],
+                isShowTools: false,
+                askCount: 1,
+                isFold: 1,
+                askTitle: "",
+                askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+                checkJson: [{ checkCount: [], checkPerent: [] }],
+                homeworkList: []
+              }
+            ],
+            itemCount: 1,
+            fileList1: [],
+            video: [],
+            testData: [],
+            pData: [],
+            templateArray: []
+          }
+        ]
+      });
+      this.addindex = this.unitJson.length - 1;
+
+      setTimeout(() => {
+        this.unitIndex = this.unitJson.length - 1;
+        this.unitSet(this.unitIndex);
+      }, 0);
+    },
+    addToolFun(itemTaskIndex) {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].toolChoose.push({
+        tool: [],
+        toolDetail: "",
+        toolType: 0,
+        askCount: 1,
+        askTitle: "",
+        askJson: [{ askstitle: "", askItem: 1, checkList: [] }]
+      });
+    },
+    addTaskBorder() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson.push({
+        task: "",
+        taskDetail: "",
+        chapterData: [],
+        toolChoose: [
+          {
+            tool: [],
+            toolDetail: "",
+            toolType: 0,
+            askCount: 1,
+            askTitle: "",
+            askJson: [{ askstitle: "", askItem: 1, checkList: [] }]
+          }
+        ],
+        toolText: "",
+        isShowTools: false,
+        askCount: 1,
+        isFold: 1,
+        askTitle: "",
+        askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+        checkJson: [{ checkCount: [], checkPerent: [] }],
+        homeworkList: []
+      });
+    },
+    add(e, i) {
+      var el = e.currentTarget;
+      el.getElementsByTagName("input")[0].click();
+    },
+    fold(i, e, type) {
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold == 0
+      ) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold = 1;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold = 0;
+      }
+      console.log(e);
+    },
+    fold2(i) {
+      if (this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold2) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].isFold2 = false;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold2 = true;
+      }
+      setTimeout(() => {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].taskDetail +=
+          "*0*%*";
+        setTimeout(() => {
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            i
+          ].taskDetail = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            i
+          ].taskDetail.replaceAll("*0*%*", "");
+        }, 0);
+      }, 0);
+      this.$forceUpdate();
+    },
+    foldC(i) {
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFoldchapter
+      ) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].isFoldchapter = false;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].isFoldchapter = true;
+      }
+      this.$forceUpdate();
+    },
+    fold3(i, ti) {
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolChoose[ti]
+          .isFold3
+      ) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolChoose[
+          ti
+        ].isFold3 = false;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolChoose[
+          ti
+        ].isFold3 = true;
+      }
+      this.$forceUpdate();
+    },
+    deleteHomeworkBox(unitIndex, index, i) {
+      this.unitJson[unitIndex].chapterInfo[index].taskJson[
+        this.taskCount
+      ].homeworkList.splice(i, 1);
+    },
+    getStudent() {
+      let params = {
+        oid: this.oid,
+        cu: "",
+        cn: this.searchPeople
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectStudentAdd", params)
+        .then(res => {
+          this.studentJuri = res.data[0];
+        })
+        .catch(err => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    getTeacher() {
+      let params = {
+        oid:
+          this.org && this.org != "undefined" && this.org != "null"
+            ? this.org
+            : this.oid,
+        cu: "",
+        cn: this.searchTN
+      };
+      this.ajax
+        .get(
+          this.$store.state.api +
+            (this.org && this.org != "undefined" && this.org != "null"
+              ? "selectTeacherAddOrg"
+              : "selectTeacherAdd"),
+          params
+        )
+        .then(res => {
+          let teacherJuri = res.data[0];
+          for (var i = 0; i < teacherJuri.length; i++) {
+            if (teacherJuri[i].userid == this.userid) {
+              teacherJuri.splice(i, 1);
+              break;
+            }
+          }
+          this.teacherJuri = teacherJuri;
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    searchStudent() {
+      this.getStudent();
+    },
+    selectGrage() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectGrageBySchool", params)
+        .then(res => {
+          this.gradeList = res.data[0];
+        })
+        .catch(err => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    //获取班级列表
+    getClass() {
+      let params = {
+        oid: this.oid,
+        gid: this.gradeId,
+        cn: this.classSearch
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectClassBySchoolSearch2", params)
+        .then(res => {
+          if (!this.grade.length) {
+            this.grade = res.data[0];
+          }
+          this.grade2 = res.data[0];
+          this.classJuri = res.data[0];
+          let _check = [];
+          let _check2 = [];
+          for (var i = 0; i < this.grade2.length; i++) {
+            var gid = this.grade2[i].id;
+            _check.push(gid);
+          }
+          for (var i = 0; i < this.checkboxList2.length; i++) {
+            var _id = this.checkboxList2[i];
+            if (_check.indexOf(_id) !== -1) {
+              _check2.push(_id);
+            }
+          }
+          this.checkAll = _check2.length === _check.length;
+        })
+        .catch(err => {
+          this.isLoading = false;
+          console.error(err);
+        });
+    },
+    CourseType2Change(val) {
+      this.pTypeCheck = [];
+      for (var i = 0; i < this.CourseType2.length; i++) {
+        let typeA = this.CourseType2[i];
+        if (val.indexOf(typeA.name) != -1) {
+          this.pTypeCheck.push(...typeA.id);
+        }
+      }
+    },
+    getChapterData(e, i, j, ic, type) {
+      e.stopPropagation();
+      this.updataC = true;
+      this.icc = ic;
+      if ((type == 2 || type == 3) && e.target.tagName !== "INPUT") {
+        console.log("还不能下载图片喔");
+      }
+    },
+    deleteChapterData(e, i, j, ic, taskI) {
+      e.stopPropagation();
+      let _this = this;
+      _this
+        .$confirm("确定删除此项?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.unitJson[i].chapterInfo[j].taskJson[taskI].chapterData.splice(
+            ic,
+            1
+          );
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    updataVideoT(e, i, j, ic) {
+      // e.stopPropagation();
+      // this.unitJson[i].chapterInfo[0].taskJson[0].chapterData[
+      //   ic
+      //   ].name = JSON.parse(JSON.stringify(e.target.value));
+      this.line = this.unitJson[i].chapterInfo[0].taskJson[0].chapterData[
+        ic
+      ].name;
+      this.taskCount = j;
+      this.lineCount = ic;
+      this.dialogVisibleupdataVideoT = true;
+      this.$forceUpdate();
+    },
+    updataVideoC() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].name = JSON.parse(
+        JSON.stringify(this.line)
+      );
+      this.dialogVisibleupdataVideoT = false;
+      this.$forceUpdate();
+    },
+    upCd(e, i, j, taskCount, ic) {
+      e.stopPropagation();
+      if (ic == 0) {
+        return;
+      }
+      var a = JSON.parse(
+        JSON.stringify(
+          this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[
+            ic - 1
+          ]
+        )
+      );
+      this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[
+        ic - 1
+      ] = JSON.parse(
+        JSON.stringify(
+          this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[ic]
+        )
+      );
+      this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[ic] = a;
+      this.$forceUpdate();
+    },
+    downCd(e, i, j, taskCount, ic) {
+      e.stopPropagation();
+      if (
+        ic ==
+        this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData.length -
+          1
+      ) {
+        return;
+      }
+      var a = JSON.parse(
+        JSON.stringify(
+          this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[
+            ic + 1
+          ]
+        )
+      );
+      this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[
+        ic + 1
+      ] = JSON.parse(
+        JSON.stringify(
+          this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[ic]
+        )
+      );
+      this.unitJson[i].chapterInfo[0].taskJson[taskCount].chapterData[ic] = a;
+      this.$forceUpdate();
+    },
+    async upTool(e, i, j, tooli) {
+      e.stopPropagation();
+      if (tooli == 0) {
+        return;
+      }
+      let count1 = await this.getWorksCount(3, i, j, tooli - 1);
+      let count2 = await this.getWorksCount(3, i, j, tooli);
+      if (count1 > 0 || count2 > 0) {
+        this.$confirm(
+          "切换工具顺序将删除此工具的提交成果,是否继续此操作?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        )
+          .then(() => {
+            var a = JSON.parse(
+              JSON.stringify(
+                this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+                  tooli - 1
+                ]
+              )
+            );
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+              tooli - 1
+            ] = JSON.parse(
+              JSON.stringify(
+                this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli]
+              )
+            );
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli] = a;
+            this.$forceUpdate();
+          })
+          .catch(() => {
+            return;
+          });
+      } else {
+        var a = JSON.parse(
+          JSON.stringify(
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli - 1]
+          )
+        );
+        this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+          tooli - 1
+        ] = JSON.parse(
+          JSON.stringify(
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli]
+          )
+        );
+        this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli] = a;
+        this.$forceUpdate();
+      }
+    },
+    async downTool(e, i, j, tooli) {
+      e.stopPropagation();
+      if (
+        tooli ==
+        this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose.length - 1
+      ) {
+        return;
+      }
+      let count1 = await this.getWorksCount(3, i, j, tooli + 1);
+      let count2 = await this.getWorksCount(3, i, j, tooli);
+      if (count1 > 0 || count2 > 0) {
+        this.$confirm(
+          "切换工具顺序将删除此工具的提交成果,是否继续此操作?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        )
+          .then(() => {
+            var a = JSON.parse(
+              JSON.stringify(
+                this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+                  tooli + 1
+                ]
+              )
+            );
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+              tooli + 1
+            ] = JSON.parse(
+              JSON.stringify(
+                this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli]
+              )
+            );
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli] = a;
+            this.$forceUpdate();
+          })
+          .catch(() => {
+            return;
+          });
+      } else {
+        var a = JSON.parse(
+          JSON.stringify(
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli + 1]
+          )
+        );
+        this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[
+          tooli + 1
+        ] = JSON.parse(
+          JSON.stringify(
+            this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli]
+          )
+        );
+        this.unitJson[i].chapterInfo[0].taskJson[j].toolChoose[tooli] = a;
+        this.$forceUpdate();
+      }
+    },
+    async addWork() {
+      if(this.$refs.pptIframeRef.contentWindow.window.pptLoading !== 2)return this.$message.info("ppt正在加载中,请稍等")
+      if(this.uploadWorkLoading)return;
+      this.uploadWorkLoading = true;
+      let _pptData = await this.getPPtJson();
+
+      // 用_pptData生成json文件,并生成File对象
+      const pptJsonStr = JSON.stringify(_pptData, null, 2);
+      const pptJsonFile = new File([pptJsonStr], "pptData.json", { type: "application/json" });
+      // 你可以根据需要将pptJsonFile上传或保存
+
+      let _url = await this.uploadFile(pptJsonFile);
+      console.log(_url)
+      this.pptCourseJson.pptData = _url;
+
+
+
+      this.inputShow = true;
+
+      for (var i = 0; i < this.unitJson.length; i++) {
+        delete this.unitJson[i].isUpdate;
+      }
+      let params = [
+        {
+          uid: this.userid,
+          title: this.courseName,
+          brief: this.courseText,
+          cover:
+            this.cover.length > 0
+              ? JSON.stringify(this.cover)
+              : JSON.stringify([
+                  {
+                    name: "noBanner.jpg",
+                    url:
+                      "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/wu1676621845022.png",
+                    uid: 1656409780264,
+                    status: "success"
+                  }
+                ]),
+          evaId: this.evalua,
+          astudent:
+            this.checkboxList2.length > 0 ? this.checkboxList2.join(",") : "",
+          see: this.isTeacherSee == true ? 1 : 0,
+          chapters: JSON.stringify(this.pptCourseJson),
+          template: this.cTemplate != "undefined" ? this.cTemplate : "",
+          courseType: JSON.stringify(this.courseTypeId),
+          ateacher:
+            this.checkboxList3.length > 0 ? this.checkboxList3.join(",") : "",
+          inviteCode: JSON.stringify(this.inviteCode)
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "insert_teacher_work_pptCourse", params)
+        .then(res => {
+          this.uploadWorkLoading = false;
+          console.log(this.steps);
+          // if (this.steps != 1 && this.steps != 2 && this.steps != 3) {
+          this.$message({
+            message: "新增成功",
+            type: "success"
+          });
+          // }
+          this.number = res.data.ordernumber;
+          this.courseId = res.data.courseId;
+          this.cid = res.data.courseId;
+          this.courseUserid = this.userid;
+          this.islogin = true;
+          this.steps = 4;
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            "success"
+          );
+        })
+        .catch(err => {
+          this.uploadWorkLoading = false;
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            err
+          );
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    goCourse() {
+      window.topU.postMessage({ cid: this.courseId, type: "1" }, "*");
+    },
+    updateWork2() {
+      let _unitIndex = this.unitIndex;
+      let cPan = 1;
+      for (
+        var j = 0;
+        j < this.unitJson[_unitIndex].chapterInfo[0].taskJson.length;
+        j++
+      ) {
+        this.unitJson[_unitIndex].chapterInfo[0].taskJson[j].proVisible = false;
+        this.unitJson[_unitIndex].chapterInfo[0].taskJson[
+          j
+        ].proVisible2 = false;
+        if (this.unitJson[_unitIndex].chapterInfo[0].taskJson[j].eList) {
+          this.unitJson[_unitIndex].chapterInfo[0].taskJson[
+            j
+          ].eList = this.unitJson[_unitIndex].chapterInfo[0].taskJson[
+            j
+          ].eList.filter(ele => {
+            return ele.value != "";
+          });
+        }
+      }
+      this.inputShow = true;
+      if (cPan == 2) {
+        return;
+      }
+      let params = [
+        {
+          cid: this.cid,
+          chapters: JSON.stringify(this.unitJson),
+          uid: this.userid,
+          unitIndex: _unitIndex
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "updateWorkNew4", params)
+        .then(res => {
+          this.$message({
+            message: "修改成功",
+            type: "success"
+          });
+          this.courseId = this.cid;
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            "success"
+          );
+        })
+        .catch(err => {
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            err
+          );
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    async updateWork() {
+      if(this.$refs.pptIframeRef.contentWindow.window.pptLoading !== 2)return this.$message.info("ppt正在加载中,请稍等")
+      if(this.uploadWorkLoading)return;
+      this.uploadWorkLoading = true;
+      let _pptData = await this.getPPtJson();
+
+      // 用_pptData生成json文件,并生成File对象
+      const pptJsonStr = JSON.stringify(_pptData, null, 2);
+      const pptJsonFile = new File([pptJsonStr], "pptData.json", { type: "application/json" });
+      // 你可以根据需要将pptJsonFile上传或保存
+      console.log(_url)
+      let _url = await this.uploadFile(pptJsonFile);
+
+      this.pptCourseJson.pptData = _url;
+
+      let params = [
+        {
+          cid: this.cid,
+          title: this.courseName,
+          brief: this.courseText,
+          cover:
+            this.cover.length > 0
+              ? JSON.stringify(this.cover)
+              : JSON.stringify([
+                  {
+                    name: "noBanner.jpg",
+                    url:
+                      "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/wu1676621845022.png",
+                    uid: 1656409780264,
+                    status: "success"
+                  }
+                ]),
+          evaId: this.evalua,
+          astudent:
+            this.checkboxList2.length > 0 ? this.checkboxList2.join(",") : "",
+          see: this.isTeacherSee == true ? 1 : 0,
+          chapters: JSON.stringify(this.pptCourseJson),
+          template: this.myWord != "undefined" ? this.myWord : [],
+          uid: this.userid,
+          courseType: JSON.stringify(this.courseTypeId),
+          ateacher:
+            this.checkboxList3.length > 0 ? this.checkboxList3.join(",") : "",
+          inviteCode: JSON.stringify(this.inviteCode)
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "updateWorkNew2", params)
+        .then(res => {
+          // if (this.steps != 1 && this.steps != 2 && this.steps != 3) {
+          this.uploadWorkLoading = false;
+          if (this.cidType == 1) {
+            this.$message({
+              message: "修改成功",
+              type: "success"
+            });
+          } else {
+            this.$message({
+              message: "新增成功",
+              type: "success"
+            });
+          }
+          // }
+          this.number = this.nbOrder;
+          this.courseId = this.cid;
+          this.steps = 4;
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            "success"
+          );
+        })
+        .catch(err => {
+          this.uploadWorkLoading = false;
+          this.addOp3(
+            "1",
+            "",
+            { courseid: this.courseId, type: "course_pptEasyMode_clickUpload" },
+            err
+          );
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    guid() {
+      var _num,
+        i,
+        _guid = "";
+      for (i = 0; i < 32; i++) {
+        _guid += Math.floor(Math.random() * 16).toString(16); //随机0  - 16 的数字 转变为16进制的字符串
+        _num = Math.floor((i - 7) / 4); //计算 (i-7)除4
+        if (_num > -1 && _num < 4 && i == 7 + 4 * _num) {
+          //会使guid中间加 "-"   形式为xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
+          _guid += "-";
+        }
+      }
+      return _guid;
+    },
+    insertWord() {
+      this.dialogVisible1 = true;
+      this.updateBoolean2 = false;
+      this.tTitle = "";
+      this.tdetail = "";
+    },
+    addWord() {
+      this.unitJson[this.unitIndex].chapterInfo[0].fileList1.push({
+        name: this.tTitle,
+        content: this.tdetail,
+        uid: this.guid()
+      });
+      this.dialogVisible1 = false;
+    },
+    upWord() {},
+    selectWord(uid, i, c) {
+      this.dialogVisible1 = true;
+      this.updateBoolean2 = true;
+      if (
+        uid == this.unitJson[this.unitIndex].chapterInfo[i].fileList1[c].uid
+      ) {
+        this.tTitle = this.unitJson[this.unitIndex].chapterInfo[i].fileList1[
+          c
+        ].name;
+        this.tdetail = this.unitJson[this.unitIndex].chapterInfo[i].fileList1[
+          c
+        ].content;
+      }
+    },
+    isAddPP() {
+      if (this.checkboxList.length > 0) {
+        this.$message({
+          message: "添加成功",
+          type: "success"
+        });
+        this.dialogVisible3 = false;
+      } else {
+        this.$message({
+          message: "请添加课程成员",
+          type: "error"
+        });
+      }
+    },
+    isAddClass() {
+      this.dialogVisibleClass = false;
+    },
+    isAddPPTeacher() {
+      this.dialogVisibleMember = false;
+      this.setMan();
+    },
+    getTemplate() {
+      this.ajax
+        .get(this.$store.state.api + "getCourseTemplateT", "")
+        .then(res => {
+          this.templateArray = res.data[0];
+          this.getTemplateOid();
+          this.$forceUpdate();
+        })
+        .catch(err => {});
+    },
+    getTemplateOid() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "getCourseTemplateTByOid", params)
+        .then(res => {
+          if (res.data[0].length) {
+            this.templateArray = [...res.data[0], ...this.templateArray];
+          }
+          this.getTemplateOrg();
+          this.$forceUpdate();
+        })
+        .catch(err => {});
+    },
+    getTemplateOrg() {
+      let params = {
+        oid: this.org
+      };
+      this.ajax
+        .get(this.$store.state.api + "getCourseTemplateTByOid", params)
+        .then(res => {
+          if (res.data[0].length) {
+            this.templateArray = [...res.data[0], ...this.templateArray];
+          }
+          this.$forceUpdate();
+        })
+        .catch(err => {});
+    },
+    clearChoose() {
+      this.clearArray.splice(this.templateC.id, 1);
+      this.dialogVisible2 = false;
+    },
+    clearAttText() {
+      this.AttText = {
+        title: "",
+        text: ""
+      };
+      this.dialogVisible6 = false;
+    },
+    clearLine() {
+      this.line = "";
+      this.dialogVisible7 = false;
+    },
+    checkTemplate(res) {
+      let _this = this;
+      _this
+        .$confirm("确定选择此模板吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.unitJson = JSON.parse(res.chapters);
+          _this.steps++;
+          setTimeout(() => {
+            this.checkEva(this.checkId);
+          }, 1000);
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    checkTemplate1(w) {
+      this.steps++;
+    },
+    checkTemplate2() {
+      let _this = this;
+      _this
+        .$confirm("确定选择空模板吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.unitIndex = 0;
+          _this.unitJson = [
+            {
+              dyName: "", //单元标题
+              chapterInfo: [
+                {
+                  isread: false,
+                  chapterid: this.guid(),
+                  title: "",
+                  courseName: "",
+                  taskJson: [
+                    {
+                      task: "",
+                      taskDetail: "",
+                      chapterData: [],
+                      toolText: "",
+                      toolChoose: [
+                        {
+                          tool: [],
+                          toolDetail: "",
+                          toolType: 0,
+                          askCount: 1,
+                          askTitle: "",
+                          askJson: [
+                            { askstitle: "", askItem: 1, checkList: [] }
+                          ]
+                        }
+                      ],
+                      isShowTools: false,
+                      askCount: 1,
+                      isFold: 1,
+                      askTitle: "",
+                      askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+                      checkJson: [{ checkCount: [], checkPerent: [] }],
+                      homeworkList: []
+                    }
+                  ],
+                  itemCount: 1,
+                  fileList1: [],
+                  video: [],
+                  testData: [],
+                  pData: [],
+                  templateArray: []
+                }
+              ]
+            }
+          ];
+          this.steps++;
+          this.updateWork();
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    checkTemplate3() {
+      let _this = this;
+      _this
+        .$confirm("确定选择简易模式吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.unitIndex = 0;
+          _this.unitJson = [
+            {
+              dyName: "", //单元标题
+              easy: 1,
+              chapterInfo: [
+                {
+                  isread: false,
+                  chapterid: this.guid(),
+                  title: "",
+                  courseName: "",
+                  taskJson: [
+                    {
+                      task: "",
+                      taskDetail: "",
+                      chapterData: [],
+                      toolText: "",
+                      toolChoose: [
+                        {
+                          tool: [],
+                          toolDetail: "",
+                          toolType: 0,
+                          askCount: 1,
+                          askTitle: "",
+                          askJson: [
+                            { askstitle: "", askItem: 1, checkList: [] }
+                          ]
+                        }
+                      ],
+                      isShowTools: false,
+                      askCount: 1,
+                      isFold: 1,
+                      askTitle: "",
+                      askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
+                      checkJson: [{ checkCount: [], checkPerent: [] }],
+                      homeworkList: []
+                    }
+                  ],
+                  itemCount: 1,
+                  fileList1: [],
+                  video: [],
+                  testData: [],
+                  pData: [],
+                  templateArray: []
+                }
+              ]
+            }
+          ];
+          this.steps++;
+          this.updateWork();
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    checkTemplate4() {
+      let _this = this;
+      _this
+        .$confirm("确定选择未来小学课程设计吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.unitIndex = 0;
+          _this.unitJson = JSON.parse(JSON.stringify(weilaiData));
+          this.steps++;
+          this.updateWork();
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    wordNext() {
+      this.dialogVisible2 = false;
+    },
+    isAddOrUpdateAttText() {
+      if (this.AttTextType == 0) {
+        this.addAttTextMessage();
+      } else {
+        this.updateAttText();
+      }
+    },
+    async isAddOrUpdateLine() {
+      if (!this.lineTitle) {
+        this.$message.error("请填写链接标题");
+        return;
+      }
+      //https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E6%97%A0%E6%B3%95%E5%93%87%E5%8F%91%E5%99%B6%E5%99%B6%E5%93%87_b634700f-f084-451d-8141-745d516f28c0.html
+      // if(this.line.includes("ppt.cocorobo.cn")){
+      //   this.$message.error("请使用ppt.cocorobo.cn的链接");
+      //   return;
+      // }
+      // 判断 this.line 链接是不是 html 文件
+      // if (!/\.html(\?|#|$)/i.test(this.line) && !/\.htm(\?|#|$)/i.test(this.line)) {
+      //   this.$message.error("请输入以.html或.htm结尾的链接");
+      //   return;
+      // }
+
+      //  使用this.ajax.get 请求 this.line 链接,如果返回 200 则认为链接有效
+      // 使用XHR请求判断页面是否可以请求到
+      // 先用iframe判断能否访问contentWindow,不能再用XHR请求
+      let isValid = await new Promise((resolve) => {
+        // 创建隐藏iframe
+        let iframe = document.createElement('iframe');
+        iframe.style.display = 'none';
+        iframe.src = this.line;
+        let timeout = setTimeout(() => {
+          // 超时,移除iframe,进入XHR判断
+          document.body.removeChild(iframe);
+          // 用XHR判断
+          let xhr = new XMLHttpRequest();
+          xhr.open('GET', this.line, true);
+          xhr.onreadystatechange = function() {
+            if (xhr.readyState === 4) {
+              if (xhr.status === 200) {
+                resolve(true);
+              } else {
+                resolve(false);
+              }
+            }
+          };
+          xhr.onerror = function() {
+            resolve(false);
+          };
+          xhr.send();
+        }, 5000); // 2秒超时
+
+        iframe.onload = function() {
+          clearTimeout(timeout);
+          try {
+            // 尝试访问contentWindow.document
+            let doc = iframe.contentWindow.document;
+            // 能访问说明同源,页面可用
+            document.body.removeChild(iframe);
+            resolve(true);
+          } catch (e) {
+            // 跨域或其他异常,移除iframe,进入XHR判断
+            document.body.removeChild(iframe);
+            let xhr = new XMLHttpRequest();
+            xhr.open('GET', iframe.src, true);
+            xhr.onreadystatechange = function() {
+              if (xhr.readyState === 4) {
+                if (xhr.status === 200) {
+                  resolve(true);
+                } else {
+                  resolve(false);
+                }
+              }
+            };
+            xhr.onerror = function() {
+              resolve(false);
+            };
+            xhr.send();
+          }
+        };
+        iframe.onerror = function() {
+          clearTimeout(timeout);
+          document.body.removeChild(iframe);
+          // iframe加载失败,进入XHR判断
+          let xhr = new XMLHttpRequest();
+          xhr.open('GET', iframe.src, true);
+          xhr.onreadystatechange = function() {
+            if (xhr.readyState === 4) {
+              if (xhr.status === 200) {
+                resolve(true);
+              } else {
+                resolve(false);
+              }
+            }
+          };
+          xhr.onerror = function() {
+            resolve(false);
+          };
+          xhr.send();
+        };
+        document.body.appendChild(iframe);
+      });
+
+      if (!isValid) {
+        this.$message.error("链接无效");
+        return;
+      }
+
+      let _data = {id:new Date().getTime(),tool:73,title:this.lineTitle,brief:"H5页面",json:{lineTitle:this.lineTitle,line:this.line},url:this.line}
+      if(this.editId){
+        let oldData = this.pptCourseJson.toolsList.find(i=>i.id===this.editId);
+        _data.id = oldData.id;
+        _data.brief = oldData.brief;
+        this.pptCourseJson.toolsList.splice(this.pptCourseJson.toolsList.findIndex(i=>i.id===this.editId),1,_data);
+      }else{
+        this.pptCourseJson.toolsList.push(_data)
+      }
+      this.setPPtToolList();
+      this.dialogVisible7 = false;
+
+    },
+    addAttTextMessage() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData.push({
+        name: this.AttText.title,
+        url: this.AttText.text,
+        type: 6
+      });
+      this.imgChange1(null, null, 6, this.taskCount);
+      this.dialogVisible6 = false;
+    },
+    selectAttText(itemTaskIndex, i) {
+      this.AttText.title = this.unitJson[
+        this.unitIndex
+      ].chapterInfo[0].taskJson[itemTaskIndex].chapterData[i].name;
+      this.AttText.text = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i].url;
+      this.taskCount = itemTaskIndex;
+      this.AttTextIndex = i;
+      this.AttTextType = 1;
+      this.dialogVisible6 = true;
+    },
+    updateAttText() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.AttTextIndex].name = this.AttText.title;
+
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.AttTextIndex].url = this.AttText.text;
+      this.dialogVisible6 = false;
+    },
+    addLine() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.lineCount
+      ].chapterData.push({
+        name: "链接",
+        title: this.lineTitle,
+        url: this.line,
+        type: 8
+      });
+      this.imgChange1(null, null, 8, this.lineCount);
+      this.dialogVisible7 = false;
+    },
+    selectLine(itemTaskIndex, i) {
+      this.line = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i].url;
+      this.lineTitle = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i].title
+        ? this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .chapterData[i].title
+        : "";
+      this.taskCount = itemTaskIndex;
+      this.lineCount = i;
+      this.lineType = 1;
+      this.dialogVisible7 = true;
+    },
+    openUpdateSource(itemTaskIndex, i) {
+      this.sourceData = {};
+      let source = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        itemTaskIndex
+      ].chapterData[i];
+      this.sourceData[source.id] = {};
+      this.sourceData[source.id].name = source.title;
+      this.sourceData[source.id].url = source.url;
+      this.dialogVisibleSource = true;
+      this.updateSourcePan = true;
+      this.taskCount = itemTaskIndex;
+      this.lineCount = i;
+    },
+    updateLine() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].url = this.line;
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData[this.lineCount].title = this.lineTitle;
+      this.dialogVisible7 = false;
+    },
+    addPP() {
+      this.dialogVisible3 = true;
+    },
+    goTo(path) {
+      this.$router.push(path);
+    },
+    openTools(itemTaskIndex, i, toolIndex) {
+      this.toolIndex = toolIndex;
+      this.taskCount = itemTaskIndex;
+      if (i == 4) {
+        if (toolIndex == null) {
+          var a = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            itemTaskIndex
+          ].chapterData;
+          for (var i = 0; i < a.length; i++) {
+            if (a[i].url == 4 && a[i].askJson.askTitle != "") {
+              this.askJson = this.unitJson[
+                this.unitIndex
+              ].chapterInfo[0].taskJson[itemTaskIndex].chapterData[i].askJson;
+            }
+          }
+        } else {
+          this.askJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex]
+            )
+          );
+        }
+        this.askJson2 = JSON.parse(JSON.stringify(this.askJson));
+        this.dialogVisible5 = true;
+      } else if (i == 45) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].testJson
+        ) {
+          this.testJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].testJson
+            )
+          );
+        } else {
+          var testJson = {
+            testCount: 1,
+            testTitle: "",
+            testJson: [
+              {
+                teststitle: "",
+                testItem: 1,
+                checkList: [],
+                timuList: [],
+                answer: [],
+                type: "1"
+              }
+            ]
+          };
+          this.testJson = testJson;
+        }
+        this.testJson2 = JSON.parse(JSON.stringify(this.testJson));
+        this.dialogVisibleChoice = true;
+      } else if (i == 47) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].sentenceList
+        ) {
+          this.sentenceList = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].sentenceList
+            )
+          );
+        } else {
+          var sentenceList = [
+            { sentenceTitle: "", addSentence: [], rightAnswer: [] }
+          ];
+          this.sentenceList = sentenceList;
+        }
+        this.sentenceList2 = JSON.parse(JSON.stringify(this.sentenceList));
+        this.dialogVisibleSentence = true;
+      } else if (i == 48) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].tableJson
+        ) {
+          this.tableJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].tableJson
+            )
+          );
+        } else {
+          var tableJson = { text: "" };
+          this.tableJson = tableJson;
+        }
+        this.dialogVisibleTable = true;
+      } else if (i == 52) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].wordJson
+        ) {
+          this.wordJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].wordJson
+            )
+          );
+        } else {
+          var wordJson = { text: "" };
+          this.wordJson = wordJson;
+        }
+        this.dialogVisibleWord = true;
+        //   else if (i == 50) {
+        //   if (
+        //     this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+        //       .toolChoose[toolIndex].uploadJson
+        //   ) {
+        //     this.uploadJson = JSON.parse(
+        //       JSON.stringify(
+        //         this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        //           itemTaskIndex
+        //         ].toolChoose[toolIndex].uploadJson
+        //       )
+        //     );
+        //   } else {
+        //     var uploadJson = [];
+        //     this.uploadJson = uploadJson;
+        //   }
+        //   this.dialogVisibleMoreUpload = true;
+        // }
+      } else if (i == 10) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].preTime
+        ) {
+          this.preTime = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].preTime
+            )
+          );
+        } else {
+          var preTime = 0;
+          this.preTime = preTime;
+        }
+        this.dialogVisiblePreTime = true;
+      } else if (i == 49) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].groupJson
+        ) {
+          this.groupJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].groupJson
+            )
+          );
+        } else {
+          var groupJson = {
+            group: [{ name: "第1组" }],
+            number: undefined,
+            islock: 1
+          };
+          this.groupJson = groupJson;
+        }
+        this.dialogVisibleGroup = true;
+      } else if (i == 62) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].videoJson
+        ) {
+          this.videoJson = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                itemTaskIndex
+              ].toolChoose[toolIndex].videoJson
+            )
+          );
+        } else {
+          var videoJson = {
+            video: "",
+            setting: []
+          };
+          this.videoJson = videoJson;
+        }
+        this.dialogVisibleVideo = true;
+      } else if (i == 15) {
+        this.answerQ = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].answerQ
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].answerQ
+              )
+            )
+          : "";
+        this.answerQ2 = JSON.parse(JSON.stringify(this.answerQ));
+        this.dialogVisible8 = true;
+      } else if (i == 40) {
+        this.rateJson = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].rateJson
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].rateJson
+              )
+            )
+          : [{ detail: "", score: 5, value: "" }]; //{detail:"",score:5,value:""}
+        this.selectSteps = 1;
+        this.dialogVisibleRate = true;
+      } else if (i == 42) {
+        this.answerQ = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].answerQ
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].answerQ
+              )
+            )
+          : "";
+        this.dialogVisibleMp3 = true;
+      } else if (i == 41) {
+        this.selectJson = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].selectJson
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].selectJson
+              )
+            )
+          : { url: "", select: [], answer: [] };
+        this.selectSteps = 1;
+        this.selectJson2 = JSON.parse(JSON.stringify(this.selectJson));
+        this.dialogVisibleSelect = true;
+      } else if (i == 3) {
+        if (!this.cid) {
+          this.$message.error(
+            "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+          );
+          return;
+        }
+        window.topU.postMessage(
+          {
+            tools: "3y",
+            cid: this.cid,
+            stage: this.unitIndex,
+            task: itemTaskIndex,
+            tool: toolIndex
+          },
+          "*"
+        );
+      } else if (i == 1) {
+        if (!this.cid) {
+          this.$message.error(
+            "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+          );
+          return;
+        }
+        window.topU.postMessage(
+          {
+            tools: "1y",
+            cid: this.cid,
+            stage: this.unitIndex,
+            task: itemTaskIndex,
+            tool: toolIndex
+          },
+          "*"
+        );
+      } else if (i == 57) {
+        if (!this.cid) {
+          this.$message.error(
+            "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+          );
+          return;
+        }
+        window.topU.postMessage(
+          {
+            tools: "57y",
+            cid: this.cid,
+            stage: this.unitIndex,
+            task: itemTaskIndex,
+            tool: toolIndex
+          },
+          "*"
+        );
+      } else if (i == 69) {
+        this.englishList = {};
+        this.englishList = this.unitJson[this.unitIndex].chapterInfo[0]
+          .taskJson[itemTaskIndex].toolChoose[toolIndex].englishList
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].englishList
+              )
+            )
+          : {};
+        this.$forceUpdate();
+        this.englishDialogVisible = true;
+      } else if (i == 70) {
+        this.englishVoiceJson = {};
+        this.englishVoiceJson = this.unitJson[this.unitIndex].chapterInfo[0]
+          .taskJson[itemTaskIndex].toolChoose[toolIndex].englishVoiceJson
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].englishVoiceJson
+              )
+            )
+          : {
+              title: "",
+              detail: "",
+              array: []
+            };
+        this.$forceUpdate();
+        this.EnglishVoiceDialog = true;
+      } else if (i == 72) {
+        let appJson = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].appJson
+          ? JSON.parse(
+              JSON.stringify(
+                this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+                  itemTaskIndex
+                ].toolChoose[toolIndex].appJson
+              )
+            )
+          : {
+              url: ""
+            };
+        this.$forceUpdate();
+        this.$refs.appDialog.openG(
+          appJson,
+          this.unitIndex,
+          itemTaskIndex,
+          toolIndex
+        );
+      }
+      // else if (i == 73){
+      //   if (!this.cid) {
+      //     this.$message.error(
+      //       "极简模式添加时不能添加模板,请添加课程后再修改添加模板"
+      //     );
+      //     return;
+      //   }
+      //   window.topU.postMessage(
+      //     {
+      //       tools: "73y",
+      //       cid: this.cid,
+      //       stage: this.unitIndex,
+      //       task: itemTaskIndex,
+      //       tool: toolIndex
+      //     },
+      //     "*"
+      //   );
+      // }
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+          .toolChoose[toolIndex].tool[0] != 72 &&
+        !!this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+          .toolChoose[toolIndex].appJson
+      ) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].appJson = null;
+      }
+    },
+    setEnglishVoiceJson(val) {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].englishVoiceJson = JSON.parse(
+        JSON.stringify(val)
+      );
+      this.$forceUpdate();
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 70
+      ) {
+        this.addTools(70, this.taskCount, this.toolIndex);
+      }
+    },
+    chapAddTools(i) {
+      if (this.chapTools[0].tools.length == 0) {
+        this.chapTools[0].tools.push(i);
+      } else {
+        if (this.chapTools[0].tools.indexOf(i) != -1) {
+          this.chapTools[0].tools.splice(this.chapTools[0].tools.indexOf(i), 1);
+        } else {
+          this.chapTools[0].tools.push(i);
+        }
+      }
+      this.$forceUpdate();
+    },
+    addChaptersDataTools() {
+      if (this.chapTools[0].tools.indexOf(4) != -1) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.chapCount
+        ].chapterData.push({
+          name: this.chapTools[0].toolDetail,
+          url: this.chapTools[0].tools,
+          type: 7,
+          askJson: this.askJson
+        });
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.chapCount
+        ].chapterData.push({
+          name: this.chapTools[0].toolDetail,
+          url: this.chapTools[0].tools,
+          type: 7
+        });
+      }
+      this.imgChange1(null, null, 7, this.chapCount);
+      this.dialogVisible4 = false;
+    },
+    addTools(i, itemTaskIndex, toolIndex) {
+      // if (
+      //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+      //     .toolChoose[toolIndex].tool.length == 0
+      // ) {
+      //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //     itemTaskIndex
+      //   ].toolChoose[toolIndex].tool.push(i);
+      // } else {
+      //   if (
+      //     this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //       itemTaskIndex
+      //     ].toolChoose[toolIndex].tool.indexOf(i) != -1
+      //   ) {
+      //     this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //       itemTaskIndex
+      //     ].toolChoose[toolIndex].tool.splice(
+      //       this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //         itemTaskIndex
+      //       ].toolChoose[toolIndex].tool.indexOf(i),
+      //       1
+      //     );
+      //   } else {
+      //     this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //       itemTaskIndex
+      //     ].toolChoose[toolIndex].tool.push(i);
+      //   }
+      //   console.log(
+      //     this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+      //       .toolChoose[toolIndex].tool
+      //   );
+      // }
+      if (i == 4) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].askJson.askTitle == "" ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].askJson[0].askstitle == "" ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].askJson[0].checkList < 2
+        ) {
+          this.openTools(itemTaskIndex, 4, toolIndex);
+          // this.$message({
+          //   message: "请填写完整问卷内容",
+          //   type: "error",
+          // });
+          return;
+        }
+      }
+      if (i == 45) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].testJson ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].testJson.testJson[0].teststitle == "" ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].testJson.testJson[0].checkList < 2
+        ) {
+          this.openTools(itemTaskIndex, 45, toolIndex);
+          // this.$message({
+          //   message: "请填写完整问卷内容",
+          //   type: "error",
+          // });
+          return;
+        }
+      }
+      if (i == 47) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].sentenceList ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].sentenceList[0].rightAnswer == 0
+        ) {
+          this.openTools(itemTaskIndex, 47, toolIndex);
+          return;
+        }
+      }
+
+      if (i == 69) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].englishList
+        ) {
+          this.openTools(itemTaskIndex, 69, toolIndex);
+          return;
+        }
+      }
+      if (i == 70) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].englishVoiceJson
+        ) {
+          this.openTools(itemTaskIndex, 70, toolIndex);
+          return;
+        }
+      }
+      if (i == 72) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].appJson ||
+          Object.keys(
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+              .toolChoose[toolIndex].appJson
+          ).length == 0
+        ) {
+          this.openTools(itemTaskIndex, 72, toolIndex);
+          return;
+        }
+      }
+      // if (i == 48) {
+      //   if (
+      //     !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+      //       .toolChoose[toolIndex].tableJson
+      //   ) {
+      //     this.openTools(itemTaskIndex, 48, toolIndex);
+      //     return;
+      //   }
+      // }
+      // if (i == 50) {
+      //   if (
+      //     !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+      //       .toolChoose[toolIndex].uploadJson
+      //   ) {
+      //     this.openTools(itemTaskIndex, 50, toolIndex);
+      //     return;
+      //   }
+      // }
+
+      if (i == 49) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].groupJson
+        ) {
+          this.openTools(itemTaskIndex, 49, toolIndex);
+          return;
+        }
+      }
+      if (i == 62) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].videoJson
+        ) {
+          this.openTools(itemTaskIndex, 62, toolIndex);
+          return;
+        }
+      }
+      if (i == 15) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].answerQ ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].answerQ == ""
+        ) {
+          this.openTools(itemTaskIndex, 15, toolIndex);
+          // this.$message({
+          //   message: "请填写问答内容",
+          //   type: "error",
+          // });
+          return;
+        }
+      }
+      if (i == 40) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].rateJson ||
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].rateJson.length
+        ) {
+          this.openTools(itemTaskIndex, 40, toolIndex);
+          return;
+        }
+      }
+      if (i == 41) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].selectJson ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].selectJson.url == "" ||
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].selectJson.select.length ||
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].selectJson.answer.length
+        ) {
+          this.openTools(itemTaskIndex, 41, toolIndex);
+          return;
+        }
+      }
+      if (i == 42) {
+        if (
+          !this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].answerQ ||
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+            .toolChoose[toolIndex].answerQ == ""
+        ) {
+          this.openTools(itemTaskIndex, 42, toolIndex);
+          return;
+        }
+      }
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+          .toolChoose[toolIndex].tool.length > 0
+      ) {
+        if (
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            itemTaskIndex
+          ].toolChoose[toolIndex].tool.indexOf(i) != -1
+        ) {
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            itemTaskIndex
+          ].toolChoose[toolIndex].tool.splice(
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              itemTaskIndex
+            ].toolChoose[toolIndex].tool.indexOf(i),
+            1
+          );
+        } else {
+          // this.$message({
+          //   message: "每个工具只能添加一个",
+          //   type: "error",
+          // });
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            itemTaskIndex
+          ].toolChoose[toolIndex].tool = [];
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            itemTaskIndex
+          ].toolChoose[toolIndex].tool.push(i);
+        }
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].tool.push(i);
+      }
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+          .toolChoose[toolIndex].tool[0] != 72 &&
+        !!this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
+          .toolChoose[toolIndex].appJson
+      ) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].toolChoose[toolIndex].appJson = null;
+      }
+      this.$forceUpdate();
+    },
+    addAskList(index) {
+      this.askJson.askJson.splice(index + 1, 0, {
+        askstitle: "",
+        askItem: 1,
+        checkList: []
+      });
+      this.askJson.askCount++;
+    },
+    addTestList(index) {
+      this.testJson.testJson.splice(index + 1, 0, {
+        teststitle: "",
+        testItem: 1,
+        checkList: [],
+        timuList: [],
+        answer: [],
+        type: "1"
+      });
+      this.testJson.testCount++;
+    },
+    deleteAskList(index) {
+      if (
+        !this.askJson.askJson[index].askstitle &&
+        this.askJson.askJson[index].askItem == 1 &&
+        !this.askJson.askJson[index].checkList[0]
+      ) {
+        this.askJson.askJson.splice(index, 1);
+        this.askJson.askCount--;
+      } else {
+        let _this = this;
+        _this
+          .$confirm("此操作不可撤销,是否继续?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          })
+          .then(() => {
+            _this.askJson.askJson.splice(index, 1);
+            _this.askJson.askCount--;
+          })
+          .catch(() => {
+            return;
+          });
+      }
+    },
+    deleteTestList(index) {
+      if (
+        !this.testJson.testJson[index].teststitle &&
+        this.testJson.testJson[index].testItem == 1 &&
+        !this.testJson.testJson[index].checkList[0]
+      ) {
+        this.testJson.testJson.splice(index, 1);
+        this.testJson.testCount--;
+      } else {
+        let _this = this;
+        _this
+          .$confirm("此操作不可撤销,是否继续?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          })
+          .then(() => {
+            _this.testJson.testJson.splice(index, 1);
+            _this.testJson.testCount--;
+          })
+          .catch(() => {
+            return;
+          });
+      }
+    },
+    askMove(type, index) {
+      if (type == 1) {
+        if (index > 0) {
+          let a = JSON.parse(JSON.stringify(this.askJson.askJson[index - 1]));
+          let b = JSON.parse(JSON.stringify(this.askJson.askJson[index]));
+          this.askJson.askJson[index - 1] = b;
+          this.askJson.askJson[index] = a;
+        }
+      } else {
+        if (index < this.askJson.askJson.length - 1) {
+          let a = JSON.parse(JSON.stringify(this.askJson.askJson[index + 1]));
+          let b = JSON.parse(JSON.stringify(this.askJson.askJson[index]));
+          this.askJson.askJson[index + 1] = b;
+          this.askJson.askJson[index] = a;
+        }
+      }
+      this.$forceUpdate();
+    },
+    checkMove(type, index, checkIndex) {
+      if (type == 1) {
+        if (checkIndex > 0) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.askJson.askJson[index].checkList[checkIndex - 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(this.askJson.askJson[index].checkList[checkIndex])
+          );
+          this.askJson.askJson[index].checkList[checkIndex - 1] = b;
+          this.askJson.askJson[index].checkList[checkIndex] = a;
+        }
+      } else {
+        if (checkIndex < this.askJson.askJson[index].checkList.length - 1) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.askJson.askJson[index].checkList[checkIndex + 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(this.askJson.askJson[index].checkList[checkIndex])
+          );
+          this.askJson.askJson[index].checkList[checkIndex + 1] = b;
+          this.askJson.askJson[index].checkList[checkIndex] = a;
+        }
+      }
+      this.$forceUpdate();
+    },
+    testMove(type, index) {
+      if (type == 1) {
+        if (index > 0) {
+          let a = JSON.parse(JSON.stringify(this.testJson.testJson[index - 1]));
+          let b = JSON.parse(JSON.stringify(this.testJson.testJson[index]));
+          this.testJson.testJson[index - 1] = b;
+          this.testJson.testJson[index] = a;
+        }
+      } else {
+        if (index < this.testJson.testJson.length - 1) {
+          let a = JSON.parse(JSON.stringify(this.testJson.testJson[index + 1]));
+          let b = JSON.parse(JSON.stringify(this.testJson.testJson[index]));
+          this.testJson.testJson[index + 1] = b;
+          this.testJson.testJson[index] = a;
+        }
+      }
+      this.$forceUpdate();
+    },
+    tcheckMove(type, index, checkIndex) {
+      if (type == 1) {
+        if (checkIndex > 0) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.testJson.testJson[index].checkList[checkIndex - 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(this.testJson.testJson[index].checkList[checkIndex])
+          );
+          this.testJson.testJson[index].checkList[checkIndex - 1] = b;
+          this.testJson.testJson[index].checkList[checkIndex] = a;
+        }
+      } else {
+        if (checkIndex < this.testJson.testJson[index].checkList.length - 1) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.testJson.testJson[index].checkList[checkIndex + 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(this.testJson.testJson[index].checkList[checkIndex])
+          );
+          this.testJson.testJson[index].checkList[checkIndex + 1] = b;
+          this.testJson.testJson[index].checkList[checkIndex] = a;
+        }
+      }
+      this.$forceUpdate();
+    },
+    addcheckList(json, index) {
+      // json.checkList.length++;
+      json.checkList.splice(index + 1, 0, "");
+      json.askItem++;
+      this.$forceUpdate();
+    },
+    deletecheckList(json, index) {
+      // json.checkList.length--;
+      json.checkList.splice(index, 1);
+      json.askItem--;
+      this.$forceUpdate();
+    },
+    addTcheckList(json, index) {
+      // json.checkList.length++;
+      json.checkList.splice(index + 1, 0, "");
+      json.testItem++;
+      this.$forceUpdate();
+    },
+    deleteTcheckList(json, index) {
+      // json.checkList.length--;
+      json.checkList.splice(index, 1);
+      json.testItem--;
+      this.$forceUpdate();
+    },
+    checkTestType(type, json) {
+      json.type = type;
+      setTimeout(() => {
+        json.answer = [];
+      }, 100);
+      this.$forceUpdate();
+    },
+    checkAskType(type, json) {
+      json.type = type;
+      // json.checkList = [];
+      this.$forceUpdate();
+    },
+    addSelectList(json) {
+      json.select.push("");
+      json.answer.push("");
+    },
+    deleteSelectList(json) {
+      // json.select.length--;
+      // json.answer.length--;
+      json.select.splice(json.select.length - 1, 1);
+      json.answer.splice(json.answer.length - 1, 1);
+    },
+    addAsk() {
+      if (this.askJson.askTitle === "") {
+        this.$message.error("标题不能为空!");
+        return;
+      }
+      var aj = this.askJson.askJson;
+      var b = 1;
+      for (var i = 0; i < aj.length; i++) {
+        if (aj[i].askstitle === "") {
+          var a = 1;
+          for (let index = 0; index < aj[i].askItem; index++) {
+            const element = aj[i].checkList[index]
+              ? aj[i].checkList[index]
+              : "";
+            if (element != "") {
+              b++;
+              this.$message.error(`请将题目${i + 1}填写完整。`);
+              return;
+            } else {
+              a++;
+            }
+          }
+          if (b == 1) {
+            this.$message.error("至少填写一个问题");
+            return;
+          }
+        } else if (aj[i].askstitle != "") {
+          for (let index = 0; index < aj[i].askItem; index++) {
+            const element = aj[i].checkList[index]
+              ? aj[i].checkList[index]
+              : "";
+            var index = 0;
+            for (var z = 0; z < aj[i].checkList.length; z++) {
+              let checkC = aj[i].checkList[z] ? aj[i].checkList[z] : "";
+              if (checkC != "") {
+                index++;
+              } else {
+                this.$message.error(`题目${i + 1}选项不能为空!`);
+                return;
+              }
+
+              for (var z2 = z + 1; z2 < aj[i].checkList.length; z2++) {
+                let checkC2 = aj[i].checkList[z2] ? aj[i].checkList[z2] : "";
+                if (checkC == checkC2) {
+                  this.$message.error(
+                    `第${i + 1}题的选项${this.optionTypeList[z]}和选项${
+                      this.optionTypeList[z2]
+                    }重复了,请修改!`
+                  );
+                  return;
+                }
+              }
+            }
+            b++;
+            if (index < 2) {
+              this.$message.error("每道题目至少需要设置2个选项。");
+              return;
+            }
+          }
+        }
+      }
+      this.askJson.askJson = this.askJson.askJson.filter(el => {
+        var elc = el.checkList.filter(element => {
+          return element != "";
+        });
+        return el.askstitle != "" && elc.length != 0;
+      });
+      if (!this.dialogVisible4) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.taskCount
+        ].toolChoose[this.toolIndex] = this.askJson;
+      }
+      this.dialogVisible5 = false;
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 4
+      ) {
+        this.addTools(4, this.taskCount, this.toolIndex);
+      }
+    },
+    addTest() {
+      // if (this.testJson.testTitle === "") {
+      //   this.$message.error("标题不能为空!");
+      //   return;
+      // }
+      var aj = this.testJson.testJson;
+      var b = 1;
+      for (var i = 0; i < aj.length; i++) {
+        if (aj[i].teststitle === "" && aj[i].timuList.length == 0) {
+          var a = 1;
+          for (let index = 0; index < aj[i].testItem; index++) {
+            const element = aj[i].checkList[index]
+              ? aj[i].checkList[index]
+              : "";
+            if (element != "") {
+              b++;
+              this.$message.error(`请将题目${i + 1}填写完整。`);
+              return;
+            } else {
+              a++;
+            }
+          }
+          if (b == 1) {
+            this.$message.error("至少填写一个问题");
+            return;
+          }
+        } else if (aj[i].teststitle != "" || aj[i].timuList.length > 0) {
+          for (let index = 0; index < aj[i].testItem; index++) {
+            const element = aj[i].checkList[index]
+              ? aj[i].checkList[index]
+              : "";
+            var index = 0;
+            for (var z = 0; z < aj[i].checkList.length; z++) {
+              var checkC = aj[i].checkList[z] ? aj[i].checkList[z] : "";
+              if (checkC != "") {
+                index++;
+              } else {
+                this.$message.error(`题目${i + 1}选项不能为空!`);
+                return;
+              }
+
+              for (var z2 = z + 1; z2 < aj[i].checkList.length; z2++) {
+                let checkC2 = aj[i].checkList[z2] ? aj[i].checkList[z2] : "";
+                if (checkC == checkC2) {
+                  this.$message.error(
+                    `第${i + 1}题的选项${this.optionTypeList[z]}和选项${
+                      this.optionTypeList[z2]
+                    }重复了,请修改!`
+                  );
+                  return;
+                }
+              }
+            }
+            b++;
+            if (index < 2) {
+              this.$message.error("每道题目至少需要设置2个选项。");
+              return;
+            }
+            if (
+              (aj[i].type == "2" && !aj[i].answer.length) ||
+              (aj[i].type == "1" &&
+                ((typeof aj[i].answer == "object" && !aj[i].answer.length) ||
+                  (aj[i].answer !== 0 && !aj[i].answer)))
+            ) {
+              this.$message.error(`请将题目${i + 1}的正确选项设置完整`);
+              return;
+            }
+          }
+        }
+      }
+      let testJson = JSON.parse(JSON.stringify(this.testJson));
+      testJson.testJson = this.testJson.testJson.filter(el => {
+        var elc = el.checkList.filter(element => {
+          return element != "";
+        });
+        return (
+          (el.teststitle != "" || el.timuList.length > 0) && elc.length != 0
+        );
+      });
+
+      testJson.testCount = testJson.testJson.length;
+
+      let _data = {id:new Date().getTime(),tool:45,title:"选择题",brief:"选择题工具",json:testJson,url:""}
+      if(this.editId){
+        let oldData = this.pptCourseJson.toolsList.find(i=>i.id===this.editId);
+        _data.id = oldData.id;
+        _data.title = oldData.title;
+        _data.brief = oldData.brief;
+        this.pptCourseJson.toolsList.splice(this.pptCourseJson.toolsList.findIndex(i=>i.id===this.editId),1,_data);
+      }else{
+        this.pptCourseJson.toolsList.push(_data)
+      }
+
+      this.dialogVisibleChoice = false;
+      this.editId = null;
+      this.getWorkPageId(_data.id,45,testJson).then(res=>{
+        // this.pptCourseJson.toolsList.find(i=>i.id===_data.id).url = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/workPage?id=${res}`
+        this.pptCourseJson.toolsList.find(i=>i.id===_data.id).url = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/workPage.html#/workPageNew?id=${res}`
+        this.setPPtToolList();
+      });
+      // var isTestJson = JSON.parse(JSON.stringify(this.testJson));
+      // isTestJson.testJson = this.testJson.testJson.filter(el => {
+      //   var elc = el.checkList.filter(element => {
+      //     return element != "";
+      //   });
+      //   return (
+      //     (el.teststitle != "" || el.timuList.length > 0) && elc.length != 0
+      //   );
+      // });
+      // isTestJson.testCount = isTestJson.testJson.length;
+      // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //   this.taskCount
+      // ].toolChoose[this.toolIndex].testJson = isTestJson;
+
+      // this.dialogVisibleChoice = false;
+      // if (
+      //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+      //     .toolChoose[this.toolIndex].tool != 45
+      // ) {
+      //   this.addTools(45, this.taskCount, this.toolIndex);
+      // }
+    },
+    addVideoJson(videoJson) {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].videoJson = videoJson;
+
+      this.dialogVisibleVideo = false;
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 62
+      ) {
+        this.addTools(62, this.taskCount, this.toolIndex);
+      }
+    },
+
+    addAnswer() {
+      if (this.answerQ == "") {
+        this.$message.error("请输入您想要问的问题");
+        return;
+      }
+      let _data = {id:new Date().getTime(),tool:15,title:"问答题",brief:"问答题工具",json:{answerQ:this.answerQ},url:""}
+      if(this.editId){
+        let oldData = this.pptCourseJson.toolsList.find(i=>i.id===this.editId);
+        _data.id = oldData.id;
+        _data.title = oldData.title;
+        _data.brief = oldData.brief;
+        this.pptCourseJson.toolsList.splice(this.pptCourseJson.toolsList.findIndex(i=>i.id===this.editId),1,_data);
+      }else{
+        this.pptCourseJson.toolsList.push(_data)
+      }
+
+      this.dialogVisible8 = false;
+      this.editId = null;
+      this.getWorkPageId(_data.id,15,{answerQ:this.answerQ}).then(res=>{
+        // this.pptCourseJson.toolsList.find(i=>i.id===_data.id).url = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/workPage.html#/workPage?id=${res}`;
+        this.pptCourseJson.toolsList.find(i=>i.id===_data.id).url = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/workPage.html#/workPageNew?id=${res}`;
+        this.setPPtToolList();
+      });
+
+      // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //   this.taskCount
+      // ].toolChoose[this.toolIndex].answerQ = this.answerQ;
+      // this.dialogVisible8 = false;
+
+      // if (
+      //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+      //     .toolChoose[this.toolIndex].tool != 15
+      // ) {
+      //   this.addTools(15, this.taskCount, this.toolIndex);
+      // }
+    },
+    addMp3Answer() {
+      if (this.answerQ == "") {
+        this.$message.error("请输入您想要回答的问题");
+        return;
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].answerQ = this.answerQ;
+      this.dialogVisibleMp3 = false;
+    },
+    addRateAnswer() {
+      var a = 1;
+      for (var i = 0; i < this.rateJson.length; i++) {
+        if (this.rateJson[i].value == "") {
+          a = 2;
+          break;
+        }
+      }
+      if (a == 2) {
+        this.$message.error("请把评价信息填写完整");
+        return;
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].rateJson = this.rateJson;
+      this.dialogVisibleRate = false;
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 40
+      ) {
+        this.addTools(40, this.taskCount, this.toolIndex);
+      }
+    },
+    addSelectAnswer() {
+      if (this.selectJson.url == "") {
+        this.$message.error("请上传题目");
+        return;
+      }
+      if (!this.selectJson.select.length) {
+        this.$message.error("请添加选项");
+        return;
+      }
+      if (!this.selectJson.answer.length) {
+        this.$message.error("请设置答案");
+        return;
+      }
+      var a = 1;
+      for (var i = 0; i < this.selectJson.answer.length; i++) {
+        if (!this.selectJson.answer[i] && this.selectJson.answer[i] !== 0) {
+          a = 2;
+        }
+      }
+      if (a == 2) {
+        this.$message.error("请设置答案");
+        return;
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].selectJson = this.selectJson;
+      this.dialogVisibleSelect = false;
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 41
+      ) {
+        this.addTools(41, this.taskCount, this.toolIndex);
+      }
+    },
+    nextSelectSteps() {
+      if (this.selectJson.url == "") {
+        this.$message.error("请上传题目");
+        return;
+      }
+      if (!this.selectJson.select.length) {
+        this.$message.error("请添加选项");
+        return;
+      } else {
+        for (var z = 0; z < this.selectJson.select.length; z++) {
+          let checkC = this.selectJson.select[z];
+          for (var z2 = z + 1; z2 < this.selectJson.select.length; z2++) {
+            let checkC2 = this.selectJson.select[z2];
+            if (checkC == checkC2) {
+              this.$message.error(
+                `选项${z + 1}和选项${z2 + 1}重复了,请修改!`
+              );
+              return;
+            }
+          }
+        }
+      }
+      var a = 1;
+      for (var i = 0; i < this.selectJson.select.length; i++) {
+        if (!this.selectJson.select[i]) {
+          a = 2;
+        }
+      }
+      if (a == 2) {
+        this.$message.error("添加的选项不能为空");
+        return;
+      }
+      this.selectSteps++;
+    },
+    selectCourseDetail() {
+      if (this.cid == "" || this.cid == undefined) {
+        if (this.oid == "4c686762-1d0a-11ed-8c78-005056b86db5") {
+          this.isTeacherSee = true;
+        }
+        console.log("这是新增课程");
+        this.selectAllType();
+      } else {
+        this.cidType = 1;
+        let params = {
+          cid: this.cid
+        };
+        this.ajax
+          .get(this.$store.state.api + "select_course_detail", params)
+          .then(res => {
+            this.loading = true;
+            this.pptCourseJson = JSON.parse(res.data[0][0].chapters);
+
+
+            this.$forceUpdate();
+            this.courseName = res.data[0][0].title;
+            this.courseText = res.data[0][0].brief;
+            this.evalua = res.data[0][0].evaId;
+            this.cover = JSON.parse(res.data[0][0].cover);
+            this.noneBtnImg = this.cover.length >= 1;
+            // this.checkboxList =
+            //   res.data[0][0].course_student.length > 0
+            //     ? JSON.parse(res.data[0][0].course_student)
+            //     : [];
+            this.checkboxList2 = res.data[0][0].juri
+              ? res.data[0][0].juri.split(",")
+              : [];
+            this.inviteCode = [];
+            for (var i = 0; i < res.data[2].length; i++) {
+              if(res.data[2][i].classid){
+                this.inviteCode.push({
+                  cid: res.data[2][i].classid,
+                  ic: res.data[2][i].code
+                });
+              }
+            }
+
+            this.checkboxList3 = res.data[0][0].course_teacher
+              ? res.data[0][0].course_teacher.split(",")
+              : [];
+            // this.isTeacherSee =
+            //   res.data[0][0].is_teacher_look == 0 ? true : false;
+            this.isTeacherSee = res.data[0][0].open == 1 ? true : false;
+            this.myWord = res.data[0][0].template;
+            this.templateC.id = "123";
+            this.courseUserid = res.data[0][0].userid;
+            // if(this.courseUserid == this.userid){
+            //   this.InviteChange(this.checkboxList2)
+            // }
+            this.nbOrder = res.data[0][0].ordernumber;
+            this.courseTypeId = [];
+            for (var i = 0; i < res.data[1].length; i++) {
+              this.courseTypeId.push(res.data[1][i].typeid);
+            }
+            console.log(this.courseTypeId);
+            // if (this.timer) clearInterval(this.timer);
+            if (this.timer) clearTimeout(this.timer);
+            this.timer = null;
+            // this.timer = setInterval(() => {
+
+            // this.seleteCourseUpdate();
+            this.setMan();
+            this.selectAllType();
+            this.setPPtToolList()
+            // this.setPPtJson(this.pptCourseJson.pptData)
+            //this.unitJson[
+            //  this.unitIndex
+            //].chapterInfo[0].taskJson[0].toolOpen = true;
+            // }, 5000);
+            this.$forceUpdate();
+            setTimeout(() => {
+              this.checkEva(this.evalua);
+            }, 0);
+          })
+          .catch(err => {
+            console.error(err);
+          });
+      }
+    },
+    seleteCourseUpdate() {
+      let params = {
+        cid: this.cid
+      };
+      this.ajax
+        .get(this.$store.state.api + "select_course_detail", params)
+        .then(res => {
+          // console.log(this.unitJson);
+          let unitJson = JSON.parse(res.data[0][0].chapters);
+          this.unitJson2 = JSON.parse(res.data[0][0].chapters);
+          let _unitJson2 = JSON.parse(JSON.stringify(this.unitJson));
+          let _unitJson = [];
+          let _chapAarry = [];
+          let _unitIndex = JSON.parse(JSON.stringify(this.unitIndex));
+          let _unitIndex2 = JSON.parse(JSON.stringify(this.unitIndex));
+          let index = 1;
+          let chapindex;
+          if (_unitJson2.length > unitJson.length) {
+            for (let c = 0; c < _unitJson2.length; c++) {
+              _chapAarry.push(_unitJson2[c].chapterInfo[0].chapterid);
+            }
+            for (let j = 0; j < unitJson.length; j++) {
+              let count = 0;
+              for (let k = 0; k < _unitJson2.length; k++) {
+                if (
+                  unitJson[j].chapterInfo[0].chapterid ==
+                  _unitJson2[k].chapterInfo[0].chapterid
+                ) {
+                  count++;
+                  _chapAarry.splice(
+                    _chapAarry.indexOf(_unitJson2[k].chapterInfo[0].chapterid),
+                    1
+                  );
+                  _unitJson.push(unitJson[j]);
+                  break;
+                }
+              }
+              // if(count === 0){
+              //   this.$message.error("您所修改的阶段已经被其他老师删除了");
+              // }
+            }
+            for (let k = 0; k < _unitJson2.length; k++) {
+              if (_unitJson2[k].isUpdate == 1) {
+                _chapAarry.splice(
+                  _chapAarry.indexOf(_unitJson2[k].chapterInfo[0].chapterid),
+                  1
+                );
+                _unitJson.push(_unitJson2[k]);
+              }
+            }
+            console.log(_chapAarry);
+            for (let d = 0; d < _unitJson2.length; d++) {
+              if (
+                _chapAarry.indexOf(_unitJson2[d].chapterInfo[0].chapterid) != -1
+              ) {
+                if (_unitIndex == d) {
+                  index = 2;
+                }
+                chapindex = d;
+                // this.$message.error("您所修改的阶段已经被其他老师删除了");
+              }
+            }
+          } else {
+            _unitJson = JSON.parse(JSON.stringify(_unitJson2));
+          }
+
+          for (let i = 0; i < unitJson.length; i++) {
+            if (
+              (i < _unitJson.length - 1 || i == _unitJson.length - 1) &&
+              _unitJson[i].chapterInfo[0].chapterid !=
+                unitJson[i].chapterInfo[0].chapterid
+            ) {
+              if (i == _unitJson.length - 1) {
+                // this.unitIndex++
+                _unitIndex2++;
+              }
+              _unitJson.splice(i, 0, unitJson[i]);
+            } else if (i > _unitJson.length - 1) {
+              _unitJson.push(unitJson[i]);
+            } else if (
+              _unitJson[i].chapterInfo[0].chapterid ==
+              unitJson[i].chapterInfo[0].chapterid
+            ) {
+              _unitJson[i] = unitJson[i];
+            }
+            // if (i == _unitIndex) {
+            //   continue;
+            // } else
+          }
+
+          if (_chapAarry.length && index != 2) {
+            if (chapindex < _unitIndex) {
+              this.isDelete = 2;
+              // this.unitIndex--;
+              _unitIndex2--;
+            } else if (
+              _unitJson2[_unitIndex].chapterInfo[0].chapterid !=
+              _unitJson[_unitIndex].chapterInfo[0].chapterid
+            ) {
+              this.isDelete = 2;
+              for (let n = 0; n < _unitJson.length; n++) {
+                if (
+                  _unitJson2[_unitIndex].chapterInfo[0].chapterid ==
+                  _unitJson[n].chapterInfo[0].chapterid
+                ) {
+                  // this.unitIndex = n;
+                  _unitIndex2 = n;
+                  _unitJson[n] = _unitJson2[_unitIndex];
+                  break;
+                }
+              }
+            }
+          } else if (index != 2) {
+            // _unitJson[this.unitIndex] = _unitJson2[_unitIndex];
+            _unitJson2[_unitIndex];
+            for (
+              var ci = 0;
+              ci < _unitJson2[_unitIndex].chapterInfo[0].taskJson.length;
+              ci++
+            ) {
+              _unitJson2[_unitIndex].chapterInfo[0].taskJson[
+                ci
+              ].toolChoose = _unitJson2[_unitIndex].chapterInfo[0].taskJson[ci]
+                .toolChoose
+                ? _unitJson2[_unitIndex].chapterInfo[0].taskJson[ci].toolChoose
+                : [];
+              let _chapterData = [];
+              for (
+                var c = 0;
+                c <
+                _unitJson2[_unitIndex].chapterInfo[0].taskJson[ci].chapterData
+                  .length;
+                c++
+              ) {
+                if (
+                  _unitJson2[_unitIndex].chapterInfo[0].taskJson[ci]
+                    .chapterData[c]
+                ) {
+                  _chapterData.push(
+                    _unitJson2[_unitIndex].chapterInfo[0].taskJson[ci]
+                      .chapterData[c]
+                  );
+                }
+              }
+              _unitJson2[_unitIndex].chapterInfo[0].taskJson[
+                ci
+              ].chapterData = _chapterData;
+            }
+            _unitJson[_unitIndex2] = _unitJson2[_unitIndex];
+          }
+          if (index == 1) {
+            this.unitJson = _unitJson;
+            this.$forceUpdate();
+            setTimeout(() => {
+              if (this.unitIndex != _unitIndex2) {
+                this.isDelete = 2;
+                this.unitIndex = _unitIndex2;
+              }
+            }, 0);
+            this.timer = setTimeout(() => {
+              this.seleteCourseUpdate();
+            }, 1000);
+          } else if (index == 2) {
+            let _this = this;
+            _this
+              .$confirm(
+                "您所修改的阶段已经被其他老师删除了,需要恢复嘛?",
+                "提示",
+                {
+                  confirmButtonText: "需要",
+                  cancelButtonText: "取消",
+                  type: "warning"
+                }
+              )
+              .then(() => {
+                if (_this.time()) {
+                  _this.restoreWork(
+                    _chapAarry[0],
+                    _unitJson,
+                    chapindex,
+                    _unitJson2,
+                    _unitIndex2
+                  );
+                }
+              })
+              .catch(() => {
+                _this.unitJson = _unitJson;
+                _this.$forceUpdate();
+                setTimeout(() => {
+                  if (this.unitIndex != _unitIndex2) {
+                    this.isDelete = 2;
+                    this.unitIndex = _unitIndex2;
+                  }
+                }, 0);
+                _this.timer = setTimeout(() => {
+                  _this.seleteCourseUpdate();
+                }, 1000);
+              });
+          }
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    restoreWork(chapid, unitJson, chapindex, unitJson2, unitIndex2) {
+      let params = [
+        {
+          cid: this.cid,
+          chapters: JSON.stringify(this.unitJson),
+          uid: this.userid,
+          chapid: chapid
+        }
+      ];
+      this.ajax
+        .post(this.$store.state.api + "restoreWork", params)
+        .then(res => {
+          this.$message({
+            message: "恢复成功",
+            type: "success"
+          });
+          unitJson.splice(chapindex, 0, unitJson2[chapindex]);
+          this.unitJson = unitJson;
+          this.$forceUpdate();
+          setTimeout(() => {
+            if (this.unitIndex != unitIndex2) {
+              this.isDelete = 2;
+              this.unitIndex = unitIndex2;
+            }
+          }, 0);
+          this.timer = setTimeout(() => {
+            this.seleteCourseUpdate();
+          }, 1000);
+        })
+        .catch(err => {
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    getTypeName() {
+      console.log(this.courseTypeId);
+      this.$forceUpdate();
+    },
+    selectAllType() {
+      let params = {
+        org: this.org && this.org != "" ? this.org : "",
+        oid: this.oid && this.oid != "" ? this.oid : "",
+        stand: "cn"
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectAllTypeStand", params)
+        .then(res => {
+          if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
+            res.data[0] = [...res.data[0], ...res.data[4]];
+          }
+          this.CourseType = res.data;
+          this.CourseType2 = [
+            { name: "智见课程", id: [] },
+            { name: "智行课程", id: [] },
+            { name: "智创课程", id: [] }
+          ];
+
+          for (var cti = 0; cti < res.data[0].length; cti++) {
+            if (
+              res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86db5" ||
+              res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86db5"
+            ) {
+              this.CourseType2[0].id.push(res.data[0][cti].id);
+            } else if (
+              res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86ac5" ||
+              res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86ac5"
+            ) {
+              this.CourseType2[1].id.push(res.data[0][cti].id);
+            } else if (
+              res.data[0][cti].id == "34629bcc-d02f-11ec-8c78-005056b86db5"
+            ) {
+              this.CourseType2[2].id.push(res.data[0][cti].id);
+            }
+            if (
+              res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86db5" ||
+              res.data[0][cti].id == "34628934-d02f-11ec-8c78-005056b86ac5"
+            ) {
+              res.data[0][cti].name = "年级";
+            } else if (
+              res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86db5" ||
+              res.data[0][cti].id == "34629907-d02f-11ec-8c78-005056b86ac5"
+            ) {
+              res.data[0][cti].name = "学科";
+            } else if (
+              res.data[0][cti].id == "34629bcc-d02f-11ec-8c78-005056b86db5"
+            ) {
+              res.data[0][cti].name = "主题";
+            }
+          }
+          let _courseTypeId = [];
+          for (var i = 0; i < res.data[0].length; i++) {
+            if (!this.cid) {
+              this.courseTypeId[res.data[0][i].id] = [];
+            }
+            // if (!this.CourseTypeJson[res.data[0][i].id]) {
+            // }
+            this.CourseTypeJson[res.data[0][i].id] = [];
+
+            if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
+              if (res.data[0][i].name == "栏目") {
+                this.CourseType[0][i].name = "主题";
+              }
+            }
+            if (res.data[2].length == 0 && res.data[3].length == 0) {
+              for (var j = 0; j < res.data[1].length; j++) {
+                if (
+                  this.courseTypeId.indexOf(res.data[1][j].id) != -1 &&
+                  _courseTypeId.indexOf(res.data[1][j].id) == -1
+                ) {
+                  _courseTypeId.push(res.data[1][j].id);
+                }
+                if (res.data[0][i].id == res.data[1][j].pid) {
+                  this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); // 去除公共分类
+                }
+              }
+            } else {
+              if (res.data[2].length > 0) {
+                for (var j = 0; j < res.data[2].length; j++) {
+                  if (
+                    this.courseTypeId.indexOf(res.data[2][j].id) != -1 &&
+                    _courseTypeId.indexOf(res.data[2][j].id) == -1
+                  ) {
+                    _courseTypeId.push(res.data[2][j].id);
+                  }
+                  if (res.data[0][i].id == res.data[2][j].pid) {
+                    this.CourseTypeJson[res.data[0][i].id].push(res.data[2][j]); // 去除公共分类
+                  }
+                }
+              }
+              if (res.data[3].length > 0) {
+                for (var j = 0; j < res.data[3].length; j++) {
+                  if (
+                    this.courseTypeId.indexOf(res.data[3][j].id) != -1 &&
+                    _courseTypeId.indexOf(res.data[3][j].id) == -1
+                  ) {
+                    _courseTypeId.push(res.data[3][j].id);
+                  }
+                  if (res.data[0][i].id == res.data[3][j].pid) {
+                    this.CourseTypeJson[res.data[0][i].id].push(res.data[3][j]); // 去除公共分类
+                  }
+                }
+              }
+            }
+          }
+          this.courseTypeId = _courseTypeId;
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    selectType() {
+      this.ajax
+        .get(this.$store.state.api + "selectType")
+        .then(res => {
+          this.CourseType = res.data;
+          for (var i = 0; i < res.data[0].length; i++) {
+            if (!this.cid) {
+              this.courseTypeId[res.data[0][i].id] = "";
+            }
+            if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
+              if (res.data[0][i].name == "栏目") {
+                this.CourseType[0][i].name = "主题";
+              }
+            }
+            for (var j = 0; j < res.data[1].length; j++) {
+              if (res.data[0][i].id == res.data[1][j].pid) {
+                if (!this.CourseTypeJson[res.data[0][i].id]) {
+                  this.CourseTypeJson[res.data[0][i].id] = [];
+                }
+                this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); // 去除公共分类
+              }
+            }
+          }
+          this.selectTypeByOid();
+          this.selectTypeByOrg();
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    selectTypeByOid() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTypeByOid", params)
+        .then(res => {
+          for (var i = 0; i < res.data[0].length; i++) {
+            for (var j = 0; j < res.data[1].length; j++) {
+              if (res.data[0][i].id == res.data[1][j].pid) {
+                if (!this.CourseTypeJson[res.data[0][i].id]) {
+                  this.CourseTypeJson[res.data[0][i].id] = [];
+                }
+                this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]);
+              }
+            }
+          }
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    selectTypeByOrg() {
+      let params = {
+        oid: this.org
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectTypeByOrg", params)
+        .then(res => {
+          for (var i = 0; i < res.data[0].length; i++) {
+            for (var j = 0; j < res.data[1].length; j++) {
+              if (res.data[0][i].id == res.data[1][j].pid) {
+                if (!this.CourseTypeJson[res.data[0][i].id]) {
+                  this.CourseTypeJson[res.data[0][i].id] = [];
+                }
+                this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]);
+              }
+            }
+          }
+          this.$forceUpdate();
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    OtherMb(type) {
+      this.typeMode = type;
+      setTimeout(() => {
+        this.checkEva(this.checkId);
+      }, 0);
+    },
+    openMember() {
+      this.searchTN = "";
+      this.getTeacher();
+      this.dialogVisibleMember = true;
+    },
+    checkEva(id, type) {
+      this.dialogVisiblemb = false;
+      this.selectEva();
+      if (this.evalua != id && type == 2) {
+        this.$message.success("导入成功");
+      }
+      this.evalua = id;
+      this.checkId = id;
+      if (this.evalua != "") {
+        for (var i = 0; i < this.evaJuri.length; i++) {
+          if (this.evalua == this.evaJuri[i].id) {
+            this.eTitle = this.evaJuri[i].title;
+            this.eJson = JSON.parse(this.evaJuri[i].content);
+          }
+        }
+        this.data.data = [];
+        this.$forceUpdate();
+        setTimeout(() => {
+          this.setMindData();
+        }, 500);
+      }
+    },
+    deleteEva() {
+      let _this = this;
+      if (_this.evalua == "") {
+        this.$message.warning("内容已经清空了,请勿重复清空");
+        return;
+      }
+      _this
+        .$confirm("确定删除此目标吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        })
+        .then(() => {
+          _this.evalua = "";
+          _this.checkId = "";
+          _this.eTitle = "";
+          let _unitJson = _this.unitJson;
+          for (var i = 0; i < _unitJson.length; i++) {
+            let _task = _unitJson[i].chapterInfo[0].taskJson;
+            for (var j = 0; j < _task.length; j++) {
+              let _eList = _task[j].eList;
+              for (var k = 0; k < _eList.length; k++) {
+                delete _eList[k].target;
+              }
+            }
+          }
+          _this.$forceUpdate();
+          if (_this.cid) {
+            _this.updateWork();
+          }
+        })
+        .catch(() => {
+          return;
+        });
+    },
+    selectEva() {
+      let params = {
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectAllEvaluation", params)
+        .then(res => {
+          this.evaJuri = res.data[0];
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    setMindData() {
+      let targetArray = [];
+      this.data.data = [];
+      this.data.data.push({ id: "root", isroot: true, topic: this.eTitle });
+      let _eJson = Object.keys(this.eJson);
+      let _e = this.eJson;
+      for (let i = 0; i < _eJson.length; i++) {
+        let element = _e[_eJson[i]];
+        this.data.data.push({
+          id: element.id,
+          parentid: "root",
+          topic: element.name
+        });
+        // targetArray.push({
+        //   id: element.id,
+        //   parentid: "root",
+        //   name: element.name,
+        // });
+        targetArray.push({
+          value: element.name,
+          label: element.name,
+          children: []
+        });
+        let _eJsonc = Object.keys(element.child);
+        let _e2 = element.child;
+        for (let j = 0; j < _eJsonc.length; j++) {
+          let _ec = _e2[_eJsonc[j]];
+          this.data.data.push({
+            id: _ec.id,
+            parentid: element.id,
+            topic: _ec.name
+          });
+          // targetArray.push({
+          //   id: _ec.id,
+          //   parentid: element.id,
+          //   name: _ec.name,
+          // });
+          targetArray[i].children.push({
+            value: _ec.name,
+            label: _ec.name,
+            children: []
+          });
+          let _eJsonz = Object.keys(_ec.child);
+          let _e3 = _ec.child;
+          for (let z = 0; z < _eJsonz.length; z++) {
+            let _ez = _e3[_eJsonz[z]];
+            this.data.data.push({
+              id: _ez.id,
+              parentid: _ec.id,
+              topic: _ez.name
+            });
+            // targetArray.push({
+            //   id: _ez.id,
+            //   parentid: _ec.id,
+            //   name: _ez.name,
+            // });
+            targetArray[i].children[j].children.push({
+              value: _ez.name,
+              label: _ez.name
+            });
+          }
+        }
+      }
+      this.targetArray = targetArray;
+      this.$forceUpdate();
+    },
+    /*添加评价 */
+    addEList(index, tIndex) {
+      this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList
+        ? this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList.push({
+            value: "",
+            detail: "",
+            score: 5
+          })
+        : (this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList = [
+            { value: "", detail: "", score: 5 }
+          ]);
+      this.$forceUpdate();
+    },
+    forceUpdate() {
+      this.$forceUpdate();
+    },
+    deletEList(index, tIndex, eIndex) {
+      this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList.splice(
+        eIndex,
+        1
+      );
+      this.$forceUpdate();
+    },
+    getChoosePic(t) {
+      this.chooseType = t;
+      this.getAllBanner();
+    },
+    getAllBanner() {
+      this.sysPicVisible = true;
+      let params = {
+        t: this.chooseType
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectAllBanner", params)
+        .then(res => {
+          this.sysPic = res.data[0];
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    // getClass() {
+    //   let params = {
+    //     oid: this.oid,
+    //   };
+    //   this.ajax
+    //     .get(this.$store.state.api + "selectClassBySchool", params)
+    //     .then((res) => {
+    //       this.classJuri = res.data[0];
+    //     })
+    //     .catch((err) => {
+    //       console.error(err);
+    //     });
+    // },
+    deleteSysPic() {
+      this.cover = [];
+      this.isSysPic = false;
+      this.isSysPic2 = false;
+    },
+    deleteSelectPic() {
+      this.selectJson.url = "";
+    },
+    setEListStar() {
+      this.$forceUpdate();
+    },
+    deletRateList(i) {
+      this.rateJson.splice(i, 1);
+    },
+    addRateList() {
+      this.rateJson.push({ detail: "", score: 5, value: "" });
+    },
+    addSt() {
+      this.sentenceList.push({
+        sentenceTitle: "",
+        addSentence: [],
+        rightAnswer: []
+      });
+    },
+    addSen(i) {
+      if (!this.sentenceList[i].sentenceTitle) {
+        this.$message.error("请填写卡片内容!");
+        return;
+      }
+      if (this.sentenceList[i].sentenceTitle.length > 10) {
+        this.$message.error("卡片内容字数不能超过10位");
+        return;
+      }
+      if (
+        this.sentenceList[i].addSentence.indexOf(
+          this.sentenceList[i].sentenceTitle
+        ) !== -1
+      ) {
+        this.$message.error("不能添加重复的卡片内容!");
+        return;
+      }
+      this.sentenceList[i].addSentence.push(this.sentenceList[i].sentenceTitle);
+      // this.isPushTitleList.push(this.sentenceTitle);
+      this.sentenceList[i].sentenceTitle = "";
+    },
+    setRightAnswer(s, i, j) {
+      if (this.sentenceList[i].rightAnswer.indexOf(s) == -1) {
+        this.sentenceList[i].rightAnswer.push(s);
+      }
+    },
+    returnCard(r, i, j) {
+      this.sentenceList[i].rightAnswer.splice(j, 1);
+    },
+    addSentenceTool() {
+      for (var i = 0; i < this.sentenceList.length; i++) {
+        if (this.sentenceList[i].rightAnswer.length == 0) {
+          this.$message.error(`请将题目${i + 1}设置完整。`);
+          return;
+        }
+        if (
+          this.sentenceList[i].addSentence.length !=
+          this.sentenceList[i].rightAnswer.length
+        ) {
+          this.$message.error(`请将题目${i + 1}设置完整。`);
+          return;
+        }
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].sentenceList = this.sentenceList;
+      this.sentenceList = [
+        { sentenceTitle: "", addSentence: [], rightAnswer: [] }
+      ];
+      this.dialogVisibleSentence = false;
+      // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //   itemTaskIndex
+      // ].toolChoose[toolIndex].tool = [];
+      // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+      //   itemTaskIndex
+      // ].toolChoose[toolIndex].tool.push(i);
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 47
+      ) {
+        this.addTools(47, this.taskCount, this.toolIndex);
+      }
+    },
+    addTableJson() {
+      // if (this.tableJson.text == "" || this.tableJson.text == "<p></p>") {
+      //   this.$message.error("请将信息填写完整!");
+      //   return;
+      // }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].tableJson = this.tableJson;
+      // this.tableJson = [{ text: "" }];
+      // this.dialogVisibleTable = false;
+      this.$message.success("上传成功");
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 48
+      ) {
+        this.addTools(48, this.taskCount, this.toolIndex);
+      }
+    },
+    addWordJson() {
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].wordJson = this.wordJson;
+      // this.wordJson = [{ text: "" }];
+      // this.dialogVisibleWord = false;
+      this.$message.success("上传成功");
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 52
+      ) {
+        this.addTools(52, this.taskCount, this.toolIndex);
+      }
+    },
+    addMoreUpload() {
+      if (this.uploadJson.length == 0) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.taskCount
+        ].toolChoose[this.toolIndex].uploadJson = [];
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.taskCount
+        ].toolChoose[this.toolIndex].uploadJson = this.uploadJson;
+      }
+
+      this.uploadJson = [];
+      this.dialogVisibleMoreUpload = false;
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 50
+      ) {
+        this.addTools(50, this.taskCount, this.toolIndex);
+      }
+    },
+    addPreTime() {
+      if (this.preTime == 0) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.taskCount
+        ].toolChoose[this.toolIndex].preTime = 0;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.taskCount
+        ].toolChoose[this.toolIndex].preTime = this.preTime;
+      }
+      this.preTime = 0;
+      this.dialogVisiblePreTime = false;
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 10
+      ) {
+        this.addTools(10, this.taskCount, this.toolIndex);
+      }
+    },
+    goToTask(i) {
+      this.toolIndexType = "";
+      if (this.isClickColor == i + 1) {
+        // if (this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen) {
+        //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen = false
+        // } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].toolOpen = true;
+        // }
+        this.$forceUpdate();
+        return;
+      }
+
+      // if (this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen) {
+      //   this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen = false
+      // } else {
+      document.querySelectorAll(".rightBox")[0].scrollTop =
+        document.querySelectorAll(".taskBorder")[i + 1].offsetTop +
+        document.querySelectorAll(".taskBorder")[i + 1].parentElement
+          .parentElement.offsetTop;
+      this.isClickColor = i + 1;
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen = true;
+      // }
+      this.$forceUpdate();
+    },
+    taskOpen(i) {
+      if (this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolOpen) {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].toolOpen = false;
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          i
+        ].toolOpen = true;
+      }
+      this.$forceUpdate();
+    },
+    taskMove(type, index) {
+      // this
+      //   .$confirm("切换任务顺序将删除所有工具的提交成果,是否继续此操作?", "提示", {
+      //     confirmButtonText: "确定",
+      //     cancelButtonText: "取消",
+      //     type: "warning",
+      //   })
+      //   .then(() => {
+      if (type == 1) {
+        if (index > 0) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index - 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index]
+            )
+          );
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            index - 1
+          ] = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index];
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index] = a;
+          if (index - 1 == 0) {
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              index - 1
+            ].chapterData = a.chapterData;
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              index
+            ].chapterData = b.chapterData;
+          }
+        }
+      } else {
+        if (
+          index <
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson.length - 1
+        ) {
+          let a = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index + 1]
+            )
+          );
+          let b = JSON.parse(
+            JSON.stringify(
+              this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index]
+            )
+          );
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+            index + 1
+          ] = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index];
+          this.unitJson[this.unitIndex].chapterInfo[0].taskJson[index] = a;
+
+          if (index == 0) {
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              index + 1
+            ].chapterData = a.chapterData;
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+              index
+            ].chapterData = b.chapterData;
+          }
+        }
+      }
+      this.$forceUpdate();
+      // })
+      // .catch(() => {
+      //   return;
+      // })
+    },
+    addGroup(i) {
+      // this.groupJson.group.splice(i + 1, 0, { name: "第"+(i+1)+"组" });
+      this.groupJson.group.push({
+        name: "第" + (this.groupJson.group.length + 1) + "组"
+      });
+    },
+    deleteGroup(i) {
+      this.groupJson.group.splice(i, 1);
+    },
+    numberPan() {
+      if (
+        /[^\d]/.test(this.groupJson.number) ||
+        this.groupJson.number < 2 ||
+        this.groupJson.number > 10
+      ) {
+        this.$message.error("请输入2-10的数字");
+        this.groupJson.number = "";
+      }
+    },
+    addGroupJson() {
+      for (var i = 0; i < this.groupJson.group.length; i++) {
+        if (!this.groupJson.group[i].name) {
+          this.$message.error("请将信息填写完整!");
+          return;
+        }
+      }
+      if (!this.groupJson.number) {
+        this.$message.error("请将信息填写完整!");
+        return;
+      }
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].toolChoose[this.toolIndex].groupJson = JSON.parse(
+        JSON.stringify(this.groupJson)
+      );
+      this.dialogVisibleGroup = false;
+      this.groupJson = {};
+
+      if (
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .toolChoose[this.toolIndex].tool != 49
+      ) {
+        this.addTools(49, this.taskCount, this.toolIndex);
+      }
+    },
+    updateTime(preTime) {
+      this.preTime = preTime;
+    },
+    InviteChange(val) {
+      console.log(val);
+      let _check = [];
+      let _check2 = [];
+      for (var i = 0; i < this.grade2.length; i++) {
+        var gid = this.grade2[i].id;
+        _check.push(gid);
+      }
+      for (var i = 0; i < this.checkboxList2.length; i++) {
+        var _id = this.checkboxList2[i];
+        if (_check.indexOf(_id) !== -1) {
+          _check2.push(_id);
+        }
+      }
+      this.checkAll = _check2.length === _check.length;
+      return;
+      let array = JSON.parse(JSON.stringify(val));
+      this.inviteCode = this.inviteCode.filter(el => {
+        if (val.indexOf(el.cid) != -1) {
+          array.splice(array.indexOf(el.cid), 1);
+          return el;
+        }
+      });
+      for (var i = 0; i < array.length; i++) {
+        this.getInviteCode(array[i]);
+      }
+    },
+    handleCheckAllChange(val) {
+      if (val) {
+        for (var i = 0; i < this.grade2.length; i++) {
+          var gid = this.grade2[i].id;
+          if (this.checkboxList2.indexOf(gid) === -1) {
+            this.checkboxList2.push(gid);
+          }
+        }
+      } else {
+        let _check = [];
+        let _check2 = [];
+        for (var i = 0; i < this.grade2.length; i++) {
+          var gid = this.grade2[i].id;
+          _check.push(gid);
+        }
+        for (var i = 0; i < this.checkboxList2.length; i++) {
+          var _id = this.checkboxList2[i];
+          if (_check.indexOf(_id) === -1) {
+            _check2.push(_id);
+          }
+        }
+        this.checkboxList2 = _check2;
+      }
+      this.isIndeterminate = false;
+    },
+    async getInviteCode(cid) {
+      let code = this.randomNumber();
+      let params = {
+        code: code,
+        oid: this.oid
+      };
+      let type = 1;
+      for (var i = 0; i < this.inviteCode.length; i++) {
+        if (this.inviteCode[i].cid != cid && code == this.inviteCode[i].ic) {
+          type = 2;
+        }
+      }
+      if (type == 2) {
+        this.getInviteCode(cid);
+        return;
+      }
+      const res = await this.ajax.get(
+        this.$store.state.api + "selectInviteCode2",
+        params
+      );
+      if (
+        res.data.length &&
+        res.data[0].length &&
+        res.data[0][0].courseId != this.cid
+      ) {
+        this.getInviteCode(cid);
+        return;
+      }
+
+      let array = [];
+      for (var i = 0; i < this.inviteCode.length; i++) {
+        array.push(this.inviteCode[i].cid);
+      }
+      if (array.indexOf(cid) != -1) {
+        this.inviteCode[array.indexOf(cid)].ic = code;
+      } else {
+        this.inviteCode.push({ cid: cid, ic: code });
+      }
+    },
+    OpenInviteD(cid) {
+      let array = [];
+      this.icode = "";
+      for (var i = 0; i < this.inviteCode.length; i++) {
+        array.push(this.inviteCode[i].cid);
+      }
+      if (array.indexOf(cid) != -1) {
+        this.icode = this.inviteCode[array.indexOf(cid)].ic;
+      }
+      this.inviteId = cid;
+      this.dialogVisibleInvite = true;
+    },
+    addInvite() {
+      let reg = /^[A-Za-z0-9]{4,}$/;
+      if (!reg.test(this.icode)) {
+        this.$message.error("请输入至少四位数字或英文组合的随机码");
+        return;
+      }
+      let type = 1;
+      for (var i = 0; i < this.inviteCode.length; i++) {
+        if (
+          this.inviteCode[i].cid != this.inviteId &&
+          this.icode == this.inviteCode[i].ic
+        ) {
+          type = 2;
+        }
+      }
+      if (type == 2) {
+        this.$message.error("已有此随机码,不能重复");
+        return;
+      }
+
+      let params = {
+        code: this.icode,
+        oid: this.oid
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectInviteCode", params)
+        .then(res => {
+          if (
+            res.data.length &&
+            res.data[0].length &&
+            res.data[0][0].courseId != this.cid
+          ) {
+            this.$message.error("已有此随机码,不能重复");
+            return;
+          }
+
+          let array = [];
+          for (var i = 0; i < this.inviteCode.length; i++) {
+            array.push(this.inviteCode[i].cid);
+          }
+          if (array.indexOf(this.inviteId) != -1) {
+            this.inviteCode[array.indexOf(this.inviteId)].ic = this.icode;
+          } else {
+            this.inviteCode.push({ cid: this.inviteId, ic: this.icode });
+          }
+          this.icode = "";
+          this.dialogVisibleInvite = false;
+        })
+        .catch(err => {
+          console.error(err);
+        });
+    },
+    randomNumber() {
+      // 随机生成两位数
+      // let num = Math.floor(Math.random() * 900) + 100;
+      // 生成 0 到 99 之间的随机整数
+      const randomNumber = Math.floor(Math.random() * 100);
+
+      // 如果随机数小于 10,补上前导零
+      const num =
+        randomNumber < 10 ? "0" + randomNumber : randomNumber.toString();
+
+      // 随机生成两个大写字母
+      let letters = "";
+      let chars2 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
+      for (let i = 0; i < 3; i++) {
+        letters += chars2.charAt(Math.floor(Math.random() * chars2.length));
+      }
+
+      // 随机生成两位数字和字母的组合
+      let mix = "";
+      let chars =
+        "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
+      for (let i = 0; i < 3; i++) {
+        let char = chars.charAt(Math.floor(Math.random() * chars.length));
+        mix += char;
+      }
+
+      // 随机选择一种类型
+      let type = Math.floor(Math.random() * 3);
+
+      return num;
+
+      // 根据类型输出结果
+      switch (type) {
+        case 0:
+          console.log(num); // 输出两位数
+          return num;
+        case 1:
+          console.log(letters); // 输出两个大写字母
+          return letters;
+        case 2:
+          console.log(mix); // 输出两位数字和字母的组合
+          return mix;
+      }
+    },
+    getPaste() {
+      // let iframe = window.topU.document.querySelectorAll("#AIChat iframe")[0];
+      // if (!iframe) {
+      //   return;
+      // }
+      // let copyData = iframe.contentWindow.copyData;
+      // // if (copyData && copyData.stageData && copyData.stageData.length) {
+      // //   this.isPasteStage = true
+      // // }
+      // if (copyData && copyData.selectData.length) {
+      //   this.isPasteChoice = true;
+      // }
+      // if (copyData && copyData.tasksData && copyData.tasksData.length) {
+      //   this.isPasteTask = true;
+      // }
+    },
+    searchImage() {
+      var _this = this;
+      _this.imageList = [];
+      if (!_this.searchImageValue) {
+        _this.sysPicVisible2 = true;
+        return;
+      }
+      _this.imageloading = true;
+      _this.ajax
+        .post("https://gpt.cocorobo.cn/search_image", {
+          page: _this.ppage,
+          pagesize: 9,
+          query: _this.searchImageValue
+        })
+        .then(function(response) {
+          // console.log(response.data.data);
+          var data = response.data.FunctionResponse.result;
+          for (var i = 0; i < data.length; i++) {
+            _this.imageList.push({ url: data[i].thumbnail });
+          }
+          _this.imageloading = false;
+        })
+        .catch(function(error) {
+          console.log(error);
+        });
+      _this.sysPicVisible2 = true;
+    },
+    changePicture() {
+      this.ppage++;
+      this.searchImage();
+    },
+    resetImage() {
+      this.ppage = 1;
+      this.searchImage();
+    },
+    jumpGj(i, j) {
+      if (i + 1 != this.isClickColor) {
+        this.isClickColor = i + 1;
+      }
+      var a = document.scrollingElement;
+      this.toolIndexType = `gj${i}${j}`;
+      let target = document.querySelector(`#gj${i}${j}`);
+      if (target) {
+        target.scrollIntoView(true);
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].toolChoose[
+          j
+        ].isFold3 = false;
+        // setTimeout(() => {
+        //   this.$refs.rightboxR.scrollTop = this.$refs.rightboxR.scrollTop - 100;
+        // }, 0);
+      }
+    },
+    dragStart(val, i, j) {
+      this.taskCount = j;
+      this.oldIndex = i;
+      this.oldData = val;
+    },
+    dragOver(i, j) {
+      this.typeIndex = "chapter-" + j + "-" + i;
+      this.newIndex = i;
+    },
+    dragEnd() {
+      let newItems = [
+        ...this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
+          .chapterData
+      ];
+      // 删除老的节点
+      newItems.splice(this.oldIndex, 1);
+      // 在列表中目标位置增加新的节点
+      newItems.splice(this.newIndex, 0, this.oldData);
+      this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.taskCount
+      ].chapterData = [...newItems];
+      this.newIndex = "";
+      this.typeIndex = "";
+      this.isdrag = "";
+      this.$forceUpdate();
+    },
+    dragTaskStart(val, i) {
+      this.oldIndex = i;
+      this.oldData = val;
+    },
+    dragTaskOver(i) {
+      this.typeIndex = "task-" + i;
+      this.newIndex = i;
+    },
+    async dragTaskEnd() {
+      if (this.newIndex == this.oldIndex) {
+        this.typeIndex = "";
+        this.newIndex = "";
+        this.isdrag = "";
+        return;
+      }
+      let count1 = await this.getWorksCount(2, 0, this.newIndex, 0);
+      let count2 = await this.getWorksCount(2, 0, this.oldIndex, 0);
+      if (count1 > 0 || count2 > 0) {
+        this.$confirm(
+          "切换任务顺序将删除所有工具的提交成果,是否继续此操作?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        )
+          .then(() => {
+            let newItems = [
+              ...this.unitJson[this.unitIndex].chapterInfo[0].taskJson
+            ];
+            let chapterData = [];
+            if (this.oldIndex == 0) {
+              chapterData = newItems[this.oldIndex].chapterData;
+              newItems[this.oldIndex].chapterData = [];
+            } else if (this.newIndex == 0) {
+              chapterData = newItems[this.newIndex].chapterData;
+              newItems[this.oldIndex].chapterData = [];
+            }
+            // 删除老的节点
+            newItems.splice(this.oldIndex, 1);
+            // 在列表中目标位置增加新的节点
+            newItems.splice(this.newIndex, 0, this.oldData);
+            if (this.oldIndex == 0 || this.newIndex == 0) {
+              newItems[0].chapterData = chapterData;
+            }
+            this.unitJson[this.unitIndex].chapterInfo[0].taskJson = [
+              ...newItems
+            ];
+            this.typeIndex = "";
+            this.newIndex = "";
+            this.isdrag = "";
+            this.$forceUpdate();
+          })
+          .catch(() => {
+            this.typeIndex = "";
+            this.newIndex = "";
+            this.isdrag = "";
+            return;
+          });
+      } else {
+        let newItems = [
+          ...this.unitJson[this.unitIndex].chapterInfo[0].taskJson
+        ];
+        let chapterData = [];
+        if (this.oldIndex == 0) {
+          chapterData = newItems[this.oldIndex].chapterData;
+          newItems[this.oldIndex].chapterData = [];
+        } else if (this.newIndex == 0) {
+          chapterData = newItems[this.newIndex].chapterData;
+          newItems[this.oldIndex].chapterData = [];
+        }
+        // 删除老的节点
+        newItems.splice(this.oldIndex, 1);
+        // 在列表中目标位置增加新的节点
+        newItems.splice(this.newIndex, 0, this.oldData);
+        if (this.oldIndex == 0 || this.newIndex == 0) {
+          newItems[0].chapterData = chapterData;
+        }
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson = [...newItems];
+        this.typeIndex = "";
+        this.newIndex = "";
+        this.$forceUpdate();
+      }
+    },
+    getWorksCount(type, stage, task, tool) {
+      return new Promise((resolve, reject) => {
+        let params = [
+          {
+            cid: this.cid,
+            stage: stage,
+            task: task,
+            tool: tool,
+            type: type
+          }
+        ];
+        this.ajax
+          .post(this.$store.state.api + "getCourseWorkCount", params)
+          .then(res => {
+            let count = res.data[0][0].count;
+            resolve(count);
+          })
+          .catch(err => {
+            resolve(0);
+            this.$message.error("网络不佳");
+            console.error(err);
+          });
+      });
+    },
+    openCodeEditor(type, val, unitIndex, itemTaskIndex = 0, index1) {
+      console.log(
+        "openCodeEditor",
+        type,
+        val,
+        unitIndex,
+        itemTaskIndex,
+        index1
+      );
+
+      this.$refs.CodeEditorRef.open(
+        type,
+        val,
+        unitIndex,
+        itemTaskIndex,
+        index1
+      );
+    },
+    addHtmlSuccess({ Tname, url, type, unitIndex, itemTaskIndex, index1 }) {
+      console.log(
+        "addHtmlSuccess",
+        name,
+        url,
+        "type:",
+        type,
+        "unitIndex",
+        unitIndex,
+        "itemTaskIndex",
+        itemTaskIndex,
+        "index1",
+        index1
+      );
+      if (type == 1) {
+        this.unitJson[unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].chapterData.splice(index1, 1, {
+          name: Tname,
+          url: url,
+          type: 16
+        });
+      } else {
+        this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          itemTaskIndex
+        ].chapterData.push({
+          name: Tname,
+          url: url,
+          type: 16
+        });
+      }
+    },
+    openAddApp(i) {
+      this.lineCount = i;
+      let _index = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+        this.lineCount
+      ].chapterData.findIndex(i => i.type == 15);
+
+      let _obj = {};
+
+      if (_index != -1) {
+        _obj = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
+          this.lineCount
+        ].chapterData[_index];
+      }
+
+      this.$refs.appDialog.openG(_obj, "", "", "", 2);
+    },
+    selectAppSuccess({ data, type }) {
+      let _data = {id:new Date().getTime(),tool:72,title:data.name,brief:data.detail,json:data,icon:data.json.icon,url:data.url}
+      if(this.editId){
+        let oldData = this.pptCourseJson.toolsList.find(i=>i.id===this.editId);
+        _data.id = oldData.id;
+        this.pptCourseJson.toolsList.splice(this.pptCourseJson.toolsList.findIndex(i=>i.id===this.editId),1,_data);
+      }else{
+        this.pptCourseJson.toolsList.push(_data)
+      }
+      this.editId = null;
+      this.setPPtToolList();
+    },
+    // 构建文件结构树
+    buildFileStructure(file, zip) {
+      const root = {
+        folderName: file.name.replace(/\.[^/.]+$/, ""), // 移除扩展名
+        files: []
+      };
+
+      // 遍历ZIP文件中的所有文件/文件夹
+      zip.forEach((relativePath, file) => {
+        if (file.dir) return; // 跳过目录
+
+        const parts = relativePath.split("/");
+        let currentLevel = root.files;
+
+        for (let i = 0; i < parts.length; i++) {
+          const part = parts[i];
+          const isLast = i === parts.length - 1;
+
+          if (isLast) {
+            // 添加文件
+            currentLevel.push({ fileName: part, file: file });
+          } else {
+            // 查找或创建文件夹
+            let folder = currentLevel.find(
+              item => typeof item === "object" && item.folderName === part
+            );
+
+            if (!folder) {
+              folder = {
+                folderName: part,
+                files: []
+              };
+              currentLevel.push(folder);
+            }
+
+            currentLevel = folder.files;
+          }
+        }
+      });
+
+      return root;
+    },
+    openToolDialog(){
+      this.$refs.InteractiveToolDialogRef.open();
+    },
+    //添加工具
+    addTool(tool) {
+      if (tool == 45) {
+        this.testJsonName = "";
+        this.testJsonBrief = "";
+        this.testJson = {
+          testCount: 1,
+          testTitle: "",
+          testJson: [
+            {
+              teststitle: "",
+              testItem: 1,
+              checkList: [],
+              timuList: [],
+              answer: [],
+              type: "1"
+            }
+          ]
+        };
+        this.dialogVisibleChoice = true;
+        // this.$message.info("添加选择题");
+      } else if (tool == 15) {
+        this.answerQ = "";
+        this.dialogVisible8 = true;
+      } else if (tool == 72){
+        this.$refs.appDialog.openG(
+          {url:""},
+          "",
+          "",
+          "",
+          2
+        );
+      }else if(tool == 73){
+        this.line = "";
+        this.lineTitle = "";
+        this.dialogVisible7 = true;
+        // this.$message.info("添加H5页面");
+      }
+    },
+    toolBtn(type,id){
+      let _data = this.pptCourseJson.toolsList.find(i=>i.id===id);
+      if(type==0){
+        if(_data.tool===45){
+          this.editId = _data.id;
+          this.testJson = JSON.parse(JSON.stringify(_data.json));
+          this.dialogVisibleChoice = true;
+        }else if(_data.tool===15){
+          this.editId = _data.id;
+          this.answerQ = JSON.parse(JSON.stringify(_data.json)).answerQ;
+          this.dialogVisible8 = true;
+        }else if(_data.tool==73){
+          this.editId = _data.id;
+          this.lineTitle = JSON.parse(JSON.stringify(_data.json)).lineTitle;
+          this.line = JSON.parse(JSON.stringify(_data.json)).line;
+          this.dialogVisible7 = true;
+        }else if(_data.tool===72){
+          this.editId = _data.id;
+          this.$refs.appDialog.openG(
+            JSON.parse(JSON.stringify(_data.json)),
+            "",
+            "",
+            "",
+            2
+          )
+        }
+      }else if(type==1){
+        let _copyData = JSON.parse(JSON.stringify(_data));
+        _copyData.id = new Date().getTime();
+        this.pptCourseJson.toolsList.push(_copyData);
+        this.setPPtToolList();
+        return this.$message.success("复制工具成功");
+        // if(!_data.url)return this.$message.error("该工具未生成链接,请稍等");
+        // const input = document.createElement("input");
+			  // // 设置 display为none会导致无法复制
+			  // // input.style.display = "none";
+			  // // 所以只能用其他方法隐藏
+			  // input.style.opacity = 0;
+			  // // 为了不影响布局
+			  // input.style.position = "fixed";
+			  // input.style.left = "-100%";
+			  // input.style.top = "-100%";
+			  // input.value = _data.url;
+			  // document.body.appendChild(input);
+			  // input.select();
+			  // const success = document.execCommand("copy");
+			  // document.body.removeChild(input);
+			  // if (!success) {
+			  // 	return this.$message.error("复制工具链接失败");
+			  // } else {
+			  // 	return this.$message.success("复制工具链接成功");
+			  // }
+      }else if(type==2){
+        this.$confirm("确定删除该工具吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(() => {
+          this.pptCourseJson.toolsList = this.pptCourseJson.toolsList.filter(i=>i.id!==id);
+          this.$message.success("删除工具成功")
+          this.setPPtToolList();
+        });
+      }
+    },
+    async getWorkPageId(id,tool,json){
+      let params = [{
+        userid:this.userid,
+        type:tool,
+        json:JSON.stringify(json)
+      }]
+      let res = await this.ajax.post(this.$store.state.api + "insert_workPage", params)
+      return res.data[0][0].id
+    },
+    //获取ppt的数据
+    async getPPtJson() {
+      const checkLoaded = async (resolve) => {
+        console.log("获取ppt数据")
+        let _pptIframe = this.$refs.pptIframeRef;
+        if (
+          _pptIframe &&
+          _pptIframe.contentWindow &&
+          _pptIframe.contentWindow.window &&
+          typeof _pptIframe.contentWindow.window.exportJSON === "function"
+        ) {
+          let _data = _pptIframe.contentWindow.window.exportJSON();
+          resolve(_data);
+        } else {
+          // 递归等待1000ms后重试
+          setTimeout(() => {
+            checkLoaded(resolve);
+          }, 1000);
+        }
+      };
+      return new Promise((resolve) => {
+        checkLoaded(resolve);
+      });
+    },
+    // setPPtJson(data){
+    //   if(!data)return;
+    //   let _pptIframe = this.$refs.pptIframeRef;
+    //   // 判断iframe是否加载完成,加载完成再执行
+    //   if (_pptIframe && _pptIframe.contentWindow && _pptIframe.contentWindow.window && typeof _pptIframe.contentWindow.window.readJSON === "function") {
+    //     let _data = _pptIframe.contentWindow.window.readJSON(data, true);
+    //     return _data;
+    //   } else {
+    //     // 如果未加载完成,延迟重试
+    //     setTimeout(() => {
+    //       this.setPPtJson(data);
+    //     }, 1000);
+    //     return null;
+    //   }
+
+    // },
+    setPPtToolList(){
+      let _toolList = JSON.parse(JSON.stringify(this.pptCourseJson.toolsList));
+      //把toolList挂载到window上
+      window.pptToolList = _toolList;
+    },
+    //上传文件
+    uploadFile(file) {
+      return new Promise((resolve)=>{
+        var credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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"
+      }; //秘钥形式的登录上传
+      window.AWS.config.update(credentials);
+      window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+      var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+      var _this = this;
+
+      if (file) {
+        var params = {
+          Key:
+            file.name.split(".")[0] +
+            new Date().getTime() +
+            "." +
+            file.name.split(".")[file.name.split(".").length - 1],
+          ContentType: file.type,
+          Body: file,
+          "Access-Control-Allow-Credentials": "*",
+          ACL: "public-read"
+        }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+        var options = {
+          partSize: 2048 * 1024 * 1024,
+          queueSize: 2,
+          leavePartsOnError: true
+        };
+        bucket
+          .upload(params, options)
+          .on("httpUploadProgress", function(evt) {
+            //这里可以写进度条
+            // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+          })
+          .send(function(err, data) {
+            if (err) {
+              // var a = _this.$refs.upload1.uploadFiles;
+              // a.splice(a.length - 1, a.length);
+              _this.$message.error("上传失败ppt数据失败");
+            } else {
+              //上传成功处理
+              // _this.unitJson[_this.unitIndex].chapterInfo[0].fileList1.push({
+              //   name: file.name,
+              //   url: data.Location,
+              //   uid: file.uid
+              // });
+              // _this.imgChange();
+              // console.log(data.Location);
+              resolve(data.Location)
+            }
+          });
+      }
+      })
+    },
+  },
+  beforeDestroy() {
+    clearTimeout(this.timer);
+    this.timer = null;
+    clearInterval(this.timer2);
+    this.timer2 = null;
+    clearInterval(this.pasteTimer);
+    this.pasteTimer = null;
+  },
+  beforeRouteLeave(to, from, next) {
+    clearTimeout(this.timer);
+    this.timer = null;
+    clearInterval(this.timer2);
+    this.timer2 = null;
+    clearInterval(this.pasteTimer);
+    this.pasteTimer = null;
+    next();
+  },
+  created() {
+    this.getStudent();
+    this.getTeacher();
+    this.getClass();
+    this.selectGrage();
+    this.getTemplate();
+    // this.selectType();
+    this.selectEva();
+    this.loading = false;
+    this.timer2 = setInterval(() => {
+      this.selectEva();
+    }, 5000);
+    this.pasteTimer = setInterval(() => {
+      this.getPaste();
+    }, 1000);
+    setTimeout(() => {
+      this.selectCourseDetail();
+    }, 500);
+  },
+  mounted() {
+
+    // iframe页面加载完成
+    this.$refs.pptIframeRef.onload = () => {
+      console.log("iframe页面加载完成");
+      // this.iframeIsLoad =this.$refs.pptIframeRef.pptLoading
+
+    }
+  }
+};
+</script>
+
+<style scoped>
+@media screen and (max-width: 1280px) {
+  .mbCss {
+    flex-direction: column !important;
+  }
+
+  .pjCss {
+    width: 100% !important;
+  }
+
+  .evaCss {
+    width: 100% !important;
+  }
+}
+
+.dialog_diy >>> .el-dialog__header {
+  background: #3c3c3c !important;
+  padding: 15px 20px;
+}
+
+.dialog_diy >>> .el-dialog__title {
+  color: #fff;
+}
+
+.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;
+}
+
+.dialog_diy >>> .el-dialog__body,
+.dialog_diy >>> .el-dialog__footer {
+  background: #fafafa;
+}
+
+.dialog_diy3 >>> .el-dialog__body,
+.dialog_diy3 >>> .el-dialog__footer {
+  background: #eee !important;
+}
+
+.dialog_diy3 >>> .el-dialog__body {
+  padding: 20px 20px;
+}
+
+.source_diy >>> .el-dialog {
+  height: 100% !important;
+  margin: 0 auto !important;
+}
+
+.source_diy >>> .el-dialog__body {
+  height: calc(100% - 185px);
+  overflow: auto;
+  background: #e6eaf0;
+}
+
+.source_diy >>> .el-dialog__footer {
+  background: #e6eaf0 !important;
+}
+
+.left {
+  border-right: 1px solid rgb(60, 94, 143);
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  min-height: 600px;
+  width: 385px;
+  height: 80%;
+}
+
+.tips {
+  color: rgb(128, 128, 128);
+  font-size: 12px;
+  width: 270px;
+  margin: 40px;
+}
+
+.pb_content {
+  height: 100% !important;
+  /* margin: 0 20px 0 20px; */
+}
+
+.pb_content_body {
+  width: 100% !important;
+  height: 100%;
+}
+
+.info_solid {
+  width: 270px;
+  height: 30px;
+  border-left: 1px solid #bdbdbd;
+  margin: 10px 0px 10px 30px;
+}
+
+.info_steps {
+  width: 270px;
+  font-size: 0.875rem;
+  display: flex;
+  align-items: center;
+}
+
+.info_steps span:nth-child(1) {
+  width: 30px;
+  height: 30px;
+  background: rgba(0, 0, 0, 0.38);
+  display: block;
+  color: #fff;
+  border-radius: 40px;
+  text-align: center;
+  line-height: 30px;
+}
+
+.steps_active {
+  background: #3d67bc !important;
+}
+
+.info_steps span:nth-child(2) {
+  margin-left: 5px;
+}
+
+.right {
+  height: 100%;
+  width: calc(100% - 40px);
+  display: flex;
+  overflow: hidden;
+  margin: 0 auto;
+}
+
+.basic_box {
+  margin: 0 auto;
+  position: relative;
+  padding: 0 20px 0 20px;
+}
+
+.basic_box2 {
+  position: relative;
+  width: calc(100% - 300px);
+}
+
+.basic_box_success {
+  width: 100%;
+  height: 100%;
+  padding: 50px 0;
+  position: relative;
+  text-align: center;
+  /* border-bottom: 1px solid #bfbfbf; */
+  box-sizing: border-box;
+  display: flex;
+  align-items: center;
+  flex-direction: column;
+  justify-content: center;
+}
+
+.info_title {
+  font-size: 1.5em;
+  margin-right: 25px;
+  /* margin: 20px 30px 20px 30px; */
+}
+
+.bInfo_title {
+  text-align: left;
+  margin: 10px 0;
+}
+
+.small_title {
+  font-size: 14px;
+  line-height: 40px;
+}
+
+.chapter_beizhu {
+  font-size: 12px;
+  font-weight: bold;
+  float: right;
+  color: rgb(128, 128, 128);
+  margin-top: 5px;
+}
+
+.chapter_uploadBox1 {
+  text-align: left;
+  background-color: rgb(242, 242, 242);
+  width: 100%;
+  height: 67px;
+  padding: 0px 15px;
+  border-radius: 8px;
+  overflow: hidden;
+  font-size: 16px;
+  box-sizing: border-box;
+  position: relative;
+}
+
+.chapter_add {
+  width: 100%;
+  height: 32px;
+  margin-top: 15px;
+  cursor: pointer;
+}
+
+.chapter_add_l {
+  margin-left: 5px;
+  width: 30px;
+  height: 30px;
+  float: left;
+  border: 1px solid #aaa;
+  color: #aaa;
+  border-radius: 50%;
+  font-size: 25px;
+  text-align: center;
+}
+
+.chapter_add_r {
+  font-size: 18px;
+  height: 40px;
+  line-height: 30px;
+  text-indent: 10px;
+  color: #aaa;
+}
+
+.chapter_add_r span {
+  font-size: 12px;
+  color: rgb(204, 204, 204);
+}
+
+.chapter_add_input {
+  display: none;
+}
+
+.line {
+  width: 85%;
+  margin: 0 auto;
+  border-top: 1px solid #e5e5e5;
+  margin-top: 20px;
+}
+
+.info_btnBox {
+  width: calc(100%);
+  display: flex;
+  justify-content: center;
+  height: 70px;
+  align-items: center;
+  background: #fff;
+  margin: 0 auto;
+  border-top: 2px solid rgb(228, 232, 237);
+  box-sizing: border-box;
+  border-radius: 0px 0 5px 5px;
+}
+
+.info_btnBox2 {
+  width: calc(100%);
+  display: flex;
+  justify-content: center;
+  height: 20px;
+  align-items: center;
+  background: #fff;
+  margin: 0 auto;
+  border-top: 2px solid rgb(228, 232, 237);
+  box-sizing: border-box;
+  overflow: hidden;
+  cursor: pointer;
+}
+
+.info_btnBox3 {
+  width: calc(100%);
+  display: flex;
+  justify-content: flex-end;
+  padding: 0 20px;
+  height: 60px;
+  align-items: center;
+  background: unset;
+  margin: 0 auto;
+  /* border-top: 1px solid rgb(228, 232, 237); */
+  box-sizing: border-box;
+  overflow: hidden;
+  cursor: pointer;
+  background: #fff;
+  border-radius: 10px;
+}
+
+.info_btn + .info_btn {
+  margin-left: 15px;
+}
+
+.info_btn,
+.teacherWord {
+  color: #fff;
+  background-color: #0f7eff;
+  padding: 8px 24px;
+  font-size: 0.9375rem;
+  box-shadow: 0px 1px 3px 0px rgb(0 0 0 / 20%), 0px 2px 2px 0px rgb(0 0 0 / 14%),
+    0px 3px 1px -2px rgb(0 0 0 / 12%);
+  min-width: 64px;
+  font-weight: 500;
+  border-radius: 4px;
+  box-sizing: border-box;
+  border: none;
+  cursor: pointer;
+}
+
+.teacherWord {
+  width: 105px !important;
+  text-align: center !important;
+  line-height: 36px !important;
+  padding: 0 !important;
+  font-size: 14px !important;
+  margin: 10px 0 !important;
+}
+
+.wordTeacher {
+  display: flex;
+  flex-direction: column;
+  width: 20%;
+  text-align: center;
+  font-size: 14px;
+  margin: 30px 30px 0 10px;
+  background: #fff;
+  position: relative;
+  border-radius: 5px;
+  padding: 25px 0px;
+}
+
+.wordPic {
+  margin: 0 auto;
+  width: 60px;
+  height: 60px;
+  cursor: pointer;
+}
+
+.deleteWord {
+  width: 22px;
+  height: 22px;
+  position: absolute;
+  right: 5px;
+  top: -15px;
+  cursor: pointer;
+  display: none;
+  z-index: 999;
+}
+
+.wordPic > img,
+.deleteWord > img,
+.addToolImg > img {
+  width: 100%;
+  height: 100%;
+}
+
+.info_btn:hover {
+  background-color: #4f7cd5 !important;
+}
+
+.cru_selectBox {
+  display: flex;
+  margin: 24px 0 10px;
+  flex-wrap: nowrap;
+  white-space: nowrap;
+  overflow: auto;
+  position: relative;
+  height: 47px;
+}
+
+.cru_selectBox::-webkit-scrollbar {
+  /*滚动条整体样式*/
+  width: 6px;
+  /*高宽分别对应横竖滚动条的尺寸*/
+  height: 6px;
+}
+
+/*定义滚动条轨道 内阴影+圆角*/
+.cru_selectBox::-webkit-scrollbar-track {
+  border-radius: 10px;
+  background-color: #eee;
+}
+
+/*定义滑块 内阴影+圆角*/
+.cru_selectBox::-webkit-scrollbar-thumb {
+  border-radius: 10px;
+  -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
+  background-color: rgba(0, 0, 0, 0.1);
+}
+
+.cru_line {
+  position: absolute;
+  bottom: 0px;
+  transition: all 0.5s;
+  left: 0px;
+  width: 125px;
+  margin-left: -25px;
+}
+
+.cru_select {
+  font-size: 21px;
+  margin-right: 37px;
+  margin-left: 5px;
+  cursor: pointer;
+  color: #a6a6a6;
+}
+
+.cru_selected {
+  color: #0b7fc2 !important;
+}
+
+.chapter_contentbox {
+  display: flex;
+  align-items: center;
+  margin-top: 15px;
+}
+
+.chapter_contentbox .cc_title {
+  margin: 0px;
+  color: black;
+  display: block;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  margin-right: 20px;
+  font-size: 18px;
+  height: 20px;
+  line-height: 22px;
+  min-width: fit-content;
+  display: flex;
+}
+
+.chapter_contentbox .cc_title::before {
+  content: "";
+  height: 100%;
+  width: 3px;
+  background: #3681fc;
+  border-radius: 3px;
+  opacity: 1;
+  display: block;
+  margin-right: 10px;
+}
+
+.chapter_contentbox .cc_input {
+  width: 100%;
+  display: flex;
+}
+
+.show_taskD {
+  min-width: fit-content;
+  margin-left: 10px;
+  display: flex;
+  align-items: center;
+  font-size: 14px;
+  cursor: pointer;
+  color: #717c8d;
+}
+
+.show_taskD > img {
+  width: 15px;
+  margin-right: 5px;
+  transition: 0.2s all;
+  transform: rotate(-90deg);
+}
+
+.show_taskD.show > img {
+  transform: rotate(0deg);
+}
+
+.show_toolD {
+  min-width: fit-content;
+  margin-left: 10px;
+  display: flex;
+  align-items: center;
+  font-size: 14px;
+  cursor: pointer;
+  color: #717c8d;
+  /* position: absolute;
+  right: 45px;
+  top: 5px; */
+}
+
+.show_toolD > img {
+  width: 15px;
+  margin-right: 5px;
+  transition: 0.2s all;
+  transform: rotate(-90deg);
+}
+
+.show_toolD.show > img {
+  transform: rotate(0deg);
+}
+
+.remove {
+  background-image: url("../../../assets/icon/new/delete_u.png");
+  cursor: pointer;
+  opacity: 0.5;
+  width: 30px;
+  min-width: 30px;
+  height: 30px;
+  background-size: 100% 100%;
+  background-repeat: no-repeat;
+  margin-left: 10px;
+}
+
+.remove1 {
+  background-image: url("../../../assets/remove1.png");
+  background-repeat: no-repeat;
+  background-position: 5px 10px;
+  width: 40px;
+  height: 50px;
+  cursor: pointer;
+  margin-left: 10px;
+}
+
+.binfo_input {
+  width: 100%;
+  margin: 0;
+  padding: 12px 14px;
+  display: block;
+  min-width: 0;
+  outline: none;
+  box-sizing: border-box;
+  background: none;
+  border: none;
+  border-radius: 4px;
+  background: #fff;
+  font-size: 16px;
+  resize: none;
+  font-family: "Microsoft YaHei";
+  min-height: 48px;
+  border: 1.5px solid #cad1dc;
+}
+
+.binfo_textarea {
+  border: 1.5px solid #cad1dc;
+  font-size: 16px;
+  resize: none;
+  background: #f6f6f6;
+  font-family: "Microsoft YaHei";
+}
+
+.binfo_input:focus-visible {
+  border: 1.5px solid #3681fc !important;
+}
+
+.time {
+  display: flex;
+  margin: 35px 0 80px 0;
+}
+
+.chapter_btnbox {
+  width: 160px;
+  border-radius: 5px;
+  border: 2px dashed gray;
+  display: flex;
+  padding: 8px 50px;
+  align-items: center;
+  justify-content: center;
+  margin: 30px auto 0;
+  cursor: pointer;
+}
+
+.icon_add {
+  position: relative;
+  width: 24px;
+  padding-top: 20px;
+  border-radius: 100%;
+  border-width: 2px;
+  border-style: solid;
+  border-color: gray;
+}
+
+.icon_add i:nth-child(1) {
+  position: absolute;
+  left: 50%;
+  top: 50%;
+  height: 60%;
+  transform: translate(-50%, -50%);
+  border-width: 1px;
+  border-style: solid;
+  border-color: inherit;
+}
+
+.icon_add i:nth-child(2) {
+  position: absolute;
+  top: 50%;
+  left: 50%;
+  width: 60%;
+  transform: translate(-50%, -50%);
+  border-width: 1px;
+  border-style: solid;
+  border-color: inherit;
+}
+
+.chapter_btn_w {
+  font-size: 0.9375rem;
+  font-weight: bold;
+  color: gray;
+  margin-left: 20px;
+}
+
+.disUoloadSty >>> .el-icon-plus {
+  display: none !important;
+  /* 上传按钮隐藏 */
+}
+
+.imgLeft {
+  margin: 15px 0;
+}
+
+.add_info_box {
+  margin: 0 0 0 auto;
+  display: flex;
+  flex-wrap: wrap;
+}
+
+.add_info_box button {
+  margin: 0 5px 10px 0;
+}
+
+.add_info_box2 {
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+}
+
+.add_info_box2::after {
+  content: "提示:支持上传10M以内的PPT和Word文件、5M以内的Excel文件, PDF文件不限制大小。";
+  color: red;
+  font-size: 14px;
+  margin-bottom: 10px;
+}
+
+.add_chapters_box {
+  text-align: left;
+  background-color: #fff;
+  width: 100%;
+  border-radius: 4px;
+  font-size: 16px;
+  box-sizing: border-box;
+  position: relative;
+  padding: 0 15px;
+  height: auto;
+  overflow-y: auto;
+  overflow-x: hidden;
+  border: 1px solid #cad1dc;
+}
+
+.add_chapters_box.add_c_none {
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  padding: 15px;
+}
+
+.add_c_none > img {
+  width: 25px;
+}
+
+.add_chapters_box.add_c_none > span {
+  font-size: 14px;
+  font-weight: 400;
+  margin: 0 0 5px 5px;
+}
+
+.homework_box {
+  display: flex;
+  align-items: flex-start;
+  flex-wrap: wrap;
+  margin: 15px 0 0 0;
+  flex-direction: column;
+  align-content: flex-start;
+}
+
+.course_homework {
+  display: flex;
+  justify-content: center;
+  flex-direction: row;
+  align-items: center;
+  margin: 0 10px 0 0;
+}
+
+.course_homework >>> .el-input__inner {
+  width: 140px;
+  margin-left: 15px;
+}
+
+.chapter_upload_move {
+  position: relative;
+  background-color: #fff;
+  position: absolute;
+  width: 100%;
+  top: 0px;
+  left: 0px;
+  border: 1px solid #eee;
+  border-radius: 5px;
+  transition: width 2s;
+  -moz-transition: width 2s;
+  -webkit-transition: width 2s;
+  -o-transition: width 2s;
+}
+
+.chapter_upload_l_i {
+  background-image: url("../../../assets/icon.png");
+  background-position: 3px -165px;
+  width: 30px;
+  height: 30px;
+  margin: 10px auto 0 auto;
+}
+
+.course_input_box {
+  display: flex;
+  margin-right: 20px;
+  width: 100%;
+  align-items: center;
+  position: relative;
+}
+
+.course_input_box > .binfo_input {
+  width: calc(100% - 0 - 200px - 20px);
+  margin: 0 10px;
+}
+
+.bb_courseIcon {
+  width: 57px;
+  height: 45px;
+  background: #f0f4fa;
+  border-radius: 5px 0px 0px 5px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  border-right: 1.5px solid rgb(202, 209, 220);
+  box-sizing: border-box;
+  position: absolute;
+  left: 1.5px;
+}
+
+.bb_courseIcon > img {
+  width: 25px;
+  height: auto;
+}
+
+.big_box {
+  /* margin-top: 20px; */
+  display: flex;
+  justify-content: space-between;
+  /* border-bottom: 1px solid #E0E2ED; */
+}
+
+.left_first {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  width: calc(100% - 310px);
+  padding: 20px;
+  box-sizing: border-box;
+  background: #fff;
+  border-radius: 5px;
+}
+
+.right_first {
+  width: 300px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  /* border-left: 1px solid #E0E2ED; */
+  box-sizing: border-box;
+  padding: 20px;
+  flex-direction: column;
+  background: #fff;
+  border-radius: 5px;
+}
+
+.ai_box {
+  width: 204px;
+  display: flex;
+  justify-content: flex-end;
+  margin-bottom: 15px;
+}
+
+.ai_content {
+  display: flex;
+  align-items: center;
+  font-size: 14px;
+  padding: 7px 20px;
+  box-sizing: border-box;
+  box-shadow: 0px 0px 12px 1px rgba(0, 0, 0, 0.16);
+  border-radius: 12px;
+  font-weight: 700;
+  cursor: pointer;
+}
+
+.ai_content > img {
+  width: 40px;
+  margin-right: 5px;
+}
+
+.c_info_title {
+  padding: 15px 0 15px 0;
+  font-size: 16px;
+  font-weight: bold;
+  margin: 0 0 0 20px;
+  box-sizing: border-box;
+  display: flex;
+  align-items: center;
+  line-height: 20px;
+}
+
+.c_info_title::before {
+  content: "";
+  display: block;
+  width: 3px;
+  height: 20px;
+  background: #0061ff;
+  border-radius: 3px;
+  margin: 0 5px 0 0;
+}
+
+.right_title {
+  /* height: 30px; */
+  padding: 0 20px;
+  font-size: 18px;
+  font-weight: bold;
+  /* color: #0f7eff; */
+  margin: 20px auto 0;
+  display: flex;
+  /* justify-content: space-between; */
+  align-items: center;
+}
+
+.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 10px 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: 20px 10px;
+  flex-direction: column;
+  flex-wrap: wrap;
+}
+
+.p_box {
+  position: relative;
+}
+
+.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: calc(100%);
+}
+
+.people_name2 >>> .el-checkbox__label {
+  width: calc(100% - 130px);
+}
+
+.inviteCode {
+  position: absolute;
+  right: 30px;
+  color: #237ade;
+  top: 0;
+  cursor: pointer;
+  font-size: 13px;
+}
+
+.noneInvite {
+  color: #a8a8a8;
+}
+
+.inviteImg {
+  position: absolute;
+  right: 5px;
+  top: 0;
+  width: 20px;
+}
+
+.right_img {
+  width: 150px;
+  height: 150px;
+  margin: 20px auto;
+}
+
+.right_img > img {
+  width: 100%;
+  height: 100%;
+}
+
+.number {
+  margin-top: 20px;
+  color: #4aa6ff;
+  text-decoration: underline;
+}
+
+.success_button {
+  display: flex;
+  text-align: center;
+  margin: 5% 0 auto;
+  flex-direction: row;
+  justify-content: center;
+}
+
+.look_course {
+  margin-right: 40px;
+  background: #3d67bc;
+  width: 200px;
+  height: 35px;
+  line-height: 35px;
+  color: #fff;
+  text-align: center;
+  font-size: 14px;
+  border-radius: 5px;
+  cursor: pointer;
+}
+
+.attend_others {
+  width: 250px;
+  background: #4fb13c;
+  height: 35px;
+  line-height: 35px;
+  color: #fff;
+  text-align: center;
+  font-size: 14px;
+  border-radius: 5px;
+  cursor: pointer;
+}
+
+.dialog_diy2 >>> .el-dialog__body {
+  text-align: center;
+}
+
+.write_togother {
+  position: absolute;
+  right: 45px;
+  display: flex;
+  top: 5%;
+}
+
+.write_people {
+  font-size: 14px;
+  line-height: 50px;
+  padding-right: 10px;
+}
+
+.end_write {
+  background: #3d67bc;
+  color: #fff;
+  width: 100px;
+  height: 35px;
+  line-height: 35px;
+  text-align: center;
+  font-size: 14px;
+  border-radius: 5px;
+  cursor: pointer;
+}
+
+.chapter_upload + .chapter_upload {
+  /* margin-top: 15px; */
+  border-top: 1px solid #e7ebf1;
+}
+
+.chapter_upload {
+  height: 45px;
+  position: relative;
+  display: flex;
+  align-items: center;
+  width: 100%;
+  min-height: 45px;
+  /* box-shadow: 0px 0px 6px 1px rgba(0, 0, 0, 0.16); */
+  /* border-radius: 4px; */
+  /* overflow: hidden; */
+  box-sizing: border-box;
+}
+
+.chapter_upload:hover > .chapter_upload_drag {
+  display: block;
+}
+
+.chapter_upload_drag {
+  position: absolute;
+  cursor: pointer;
+  width: 16px;
+  height: 16px;
+  left: -9px;
+  background-image: url("../../../assets/icon/new/icon_course_drag.png");
+  background-size: 100% 100%;
+  z-index: 10;
+  display: none;
+}
+
+.chapter_upload_t {
+  background-color: #fff;
+  position: absolute;
+  height: 100%;
+  top: 0px;
+  left: 0px;
+  box-sizing: border-box;
+}
+
+.chapter_upload_o {
+  width: 100%;
+  height: 100%;
+  position: relative;
+  z-index: 1;
+}
+
+.chapter_upload_ic {
+  margin: 0 15px 0px auto;
+  display: flex;
+  align-items: center;
+}
+
+.chapter_upload_ic_l {
+  width: 50px;
+  height: 50px;
+  float: left;
+}
+
+.chapter_upload_ic_l div {
+  width: 30px;
+  height: 35px;
+  background: url("../../../assets/icon/icon.png");
+}
+
+.chapter_upload_ic_edit {
+  height: 100%;
+  display: flex;
+  align-items: center;
+  cursor: pointer;
+  margin: 0 10px 0 0;
+}
+
+.chapter_upload_ic_edit div {
+  width: 18px;
+  height: 18px;
+  background-image: url("../../../assets/icon/new/edit_u.png");
+  background-size: 100% 100%;
+}
+
+.chapter_upload_ic_r {
+  height: 100%;
+  display: flex;
+  align-items: center;
+  cursor: pointer;
+}
+
+.chapter_upload_ic_r div {
+  width: 18px;
+  height: 18px;
+  background-image: url("../../../assets/icon/new/delete_u.png");
+  background-size: 100% 100%;
+}
+
+.chapter_upload_n {
+  display: flex;
+  text-indent: 10px;
+  text-decoration: none;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+  overflow: hidden;
+  width: 55%;
+  margin-left: 10px;
+  cursor: pointer;
+  margin-top: 2px;
+  align-items: center;
+}
+
+.chapter_upload_l_i2,
+.chapter_upload_l_i3,
+.chapter_upload_l_i8,
+.chapter_upload_l_i6,
+.chapter_upload_l_i12,
+.chapter_upload_l_i14,
+.chapter_upload_l_i13,
+.chapter_upload_l_i15 {
+  width: 15px;
+  height: 15px;
+  background-size: 100% 100%;
+}
+
+.chapter_upload_l_i2 {
+  background-image: url("../../../assets/icon/new/u_word.png");
+}
+
+.chapter_upload_l_i3 {
+  background-image: url("../../../assets/icon/new/u_video.png");
+}
+
+.chapter_upload_l_i8 {
+  background-image: url("../../../assets/icon/new/u_url.png");
+}
+
+.chapter_upload_l_i14 {
+  background-image: url("../../../assets/icon/new/u_source.png");
+}
+
+.chapter_upload_l_i15 {
+  background-image: url("../../../assets/icon/new/appStore.png");
+}
+
+.chapter_upload_l_i6 {
+  background-image: url("../../../assets/icon/new/u_picture.png");
+}
+
+.chapter_upload_l_i12 {
+  background-image: url("../../../assets/icon/new/u_word.png");
+}
+
+.chapter_upload_l_i13 {
+  background-image: url("../../../assets/icon/new/u_img.png");
+}
+
+.chapter_upload_noSee {
+  background-image: url("../../../assets/icon/new/u_noUpload.png");
+  width: 18px;
+  height: 18px;
+  background-size: 100% 100%;
+  display: block;
+  margin-right: 10px;
+}
+
+.chapter_upload_ud {
+  display: flex;
+  flex-direction: row;
+  justify-content: center;
+  margin: 0 10px 0 0;
+}
+
+.chapter_upload_ud > .chapter_upload_up {
+  margin-bottom: 0;
+  margin-right: 10px;
+}
+
+.chapter_upload_down,
+.chapter_upload_up {
+  width: 20px;
+  height: 20px;
+  background: #e4eaf2;
+  cursor: pointer;
+  margin: 0 auto;
+  border-radius: 5px;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+}
+
+.chapter_upload_up::after,
+.chapter_upload_down::after {
+  content: "";
+  background-image: url("../../../assets/icon/new/downBtn.png");
+  width: 13px;
+  height: 13px;
+  background-size: 100% 100%;
+  display: block;
+}
+
+.chapter_upload_up::after {
+  background-image: url("../../../assets/icon/new/upBtn.png") !important;
+}
+
+.chapter_upload_up {
+  margin-bottom: 5px;
+}
+
+.chapter_upload_ud2 {
+  display: flex;
+  flex-direction: row;
+  justify-content: center;
+  margin: 0 10px 0 0;
+}
+
+.chapter_upload_ud2 > .chapter_upload_up2 {
+  margin-bottom: 0;
+  margin-right: 10px;
+}
+
+.chapter_upload_down2,
+.chapter_upload_up2 {
+  cursor: pointer;
+  margin: 0 auto;
+  border-radius: 5px;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  color: #717c8d;
+  font-size: 14px;
+}
+.chapter_upload_up2 {
+  margin-right: 10px;
+}
+.chapter_upload_up2::before,
+.chapter_upload_down2::before {
+  content: "";
+  background-image: url("../../../assets/icon/new/c_down.png");
+  width: 14px;
+  height: 14px;
+  background-size: 100% 100%;
+  display: block;
+  margin-right: 5px;
+}
+
+.chapter_upload_up2::before {
+  background-image: url("../../../assets/icon/new/c_up.png") !important;
+}
+
+.addWordStyle {
+  display: flex;
+  flex-direction: row;
+  justify-content: flex-start;
+  overflow-x: auto;
+  white-space: nowrap;
+  flex-wrap: wrap;
+}
+
+/* table 样式 */
+.cont >>> table {
+  border-top: 1px solid #ccc;
+  border-left: 1px solid #ccc;
+}
+
+.cont >>> table td,
+.cont >>> table th {
+  border-bottom: 1px solid #ccc;
+  border-right: 1px solid #ccc;
+  /* padding: 20px 5px; */
+  padding: 5px 10px;
+  max-width: 0px;
+  height: 30px;
+  vertical-align: baseline;
+}
+
+.cont >>> table th {
+  border-bottom: 2px solid #ccc;
+  text-align: center;
+}
+
+/* blockquote 样式 */
+.cont >>> blockquote {
+  display: block;
+  border-left: 8px solid #d0e5f2;
+  padding: 5px 10px;
+  margin: 10px 0;
+  line-height: 1.4;
+  font-size: 100%;
+  background-color: #f1f1f1;
+}
+
+/* code 样式 */
+.cont >>> code {
+  display: inline-block;
+  /* *display: inline; */
+  zoom: 1;
+  background-color: #f1f1f1;
+  border-radius: 3px;
+  padding: 3px 5px;
+  margin: 0 3px;
+}
+
+.cont >>> pre code {
+  display: block;
+}
+
+/* ul ol 样式 */
+.cont >>> ul,
+ol {
+  margin: 10px 0 10px 20px;
+}
+
+.wordbox {
+  display: flex;
+  flex-wrap: wrap;
+  cursor: pointer;
+  width: 100%;
+}
+
+.checkword {
+  width: 22px;
+  height: 22px;
+  margin: 10px auto 0;
+  cursor: pointer;
+}
+
+.checkword img {
+  width: 100%;
+}
+
+.stepBg {
+  display: flex;
+  flex-direction: column;
+  justify-content: space-between;
+  align-items: center;
+  background: #fff;
+  width: 300px;
+  margin: 0 25px 0 0;
+}
+
+.stepTop {
+  min-width: 300px;
+  width: 300px;
+  /* border-radius: 10px; */
+  display: flex;
+  flex-direction: column;
+  justify-content: flex-start;
+  align-items: center;
+  flex-wrap: nowrap;
+  background: #fff;
+  /* top: 18%; */
+}
+
+.stepTop > div {
+  height: 80px;
+  width: 85%;
+  cursor: pointer;
+  margin: 10px 0;
+  border-radius: 10px;
+}
+
+.first,
+.second,
+.third,
+.four {
+  background: #4a83d0;
+  height: 90px;
+  color: #fff;
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  justify-content: center;
+}
+
+.first > div:nth-child(1),
+.second > div:nth-child(1),
+.third > div:nth-child(1),
+.four > div:nth-child(1) {
+  margin: 5px 10px 0 0;
+  width: 2rem;
+}
+
+.firstNo,
+.secondNo,
+.thirdNo,
+.fourNo {
+  background: #e7e7e7;
+  color: #adadad;
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  justify-content: center;
+}
+
+.firstNo > div:nth-child(1),
+.secondNo > div:nth-child(1),
+.thirdNo > div:nth-child(1),
+.fourNo > div:nth-child(1) {
+  margin: 5px 10px 0 0;
+  width: 2rem;
+}
+
+.uploadWidth >>> .el-upload {
+  width: 60px;
+  height: 60px;
+  position: relative;
+}
+
+.addPeople {
+  background: #fa6060;
+  width: 150px;
+  height: 40px;
+  color: #fff;
+  border-radius: 5px;
+  text-align: center;
+  line-height: 40px;
+  font-size: 14px;
+  cursor: pointer;
+}
+
+.kcImg {
+  width: 60px;
+  margin-left: 10px;
+}
+
+.zyImg {
+  width: 55px;
+  margin: 0 10px;
+}
+
+.deleteZy {
+  width: 20px;
+  position: absolute;
+  top: 5px;
+  right: 5px;
+  cursor: pointer;
+}
+
+.kcImg > img,
+.zyImg > img,
+.deleteZy > img {
+  width: 100%;
+  height: 100%;
+}
+
+.zyBox {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  background: #67d37d;
+  color: #fff;
+  width: 210px;
+  margin: 20px 20px 0 0;
+  border-radius: 10px;
+  height: 70px;
+  position: relative;
+}
+
+.upCss {
+  display: flex;
+  flex-direction: row;
+  justify-content: flex-start;
+}
+
+.upCss >>> .el-icon-plus {
+  position: none !important;
+  width: 200px;
+  height: 100px;
+  display: flex;
+  flex-wrap: nowrap;
+  flex-direction: column;
+  align-items: center;
+  justify-content: center;
+  border: 1px dashed #ccc;
+  min-width: 78px;
+  min-height: 100px;
+  z-index: 999;
+}
+
+.upCss >>> .el-upload-list__item-name {
+  width: 100px;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.upCss >>> .el-upload-list__item .el-icon-close {
+  font-size: 20px;
+  z-index: 9999;
+}
+
+.addStageImg {
+  min-width: 25px;
+  min-height: 25px;
+  width: 25px;
+  height: 25px;
+  cursor: pointer;
+}
+
+.addHW {
+  width: 28px;
+  height: 28px;
+  cursor: pointer;
+}
+
+.addStageImg > img,
+.addHW > img {
+  width: 100%;
+  height: 100%;
+}
+
+.addNewPP >>> .el-dialog__body {
+  padding: 5px 20px;
+}
+
+.addNewPP >>> .el-dialog {
+  margin-top: 5vh !important;
+}
+
+.addNewPP2 >>> .el-dialog__body {
+  padding: 5px 0;
+}
+
+.addNewPP2 >>> .el-dialog {
+  margin-top: 5vh !important;
+}
+
+.isHeight {
+  height: 680px;
+}
+
+.toolChoose {
+  display: flex;
+  /* width: 100%; */
+  flex-direction: row;
+  flex-wrap: wrap;
+}
+
+.tool,
+.isToolChoose {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  width: fit-content;
+  margin: 10px 10px 10px 10px;
+  align-items: center;
+  border: 2px solid #dbdbdb00;
+  padding: 10px 20px;
+  border-radius: 5px;
+  cursor: pointer;
+  /* box-shadow: 0 0 2px 0px #dedede; */
+  position: relative;
+  box-sizing: border-box;
+  transition:.2s;
+}
+
+.tool:hover {
+  box-shadow: 0 0 2px 0px #438aff;
+  /* border: 2px solid #a5c7ff; */
+}
+
+/* .tool:hover > .noCTool {
+  display: block;
+  opacity: 0.5;
+} */
+
+.isToolChoose {
+  border: 2px solid #438aff !important;
+  box-shadow: 0 0 2px 0px #438aff;
+  opacity: 1 !important;
+}
+
+.isCTool,
+.noCTool {
+  width: 30px;
+  height: 30px;
+  position: absolute;
+  top: -4px;
+  right: -4px;
+}
+
+.noCTool {
+  display: none;
+}
+
+.isCTool > img,
+.noCTool > img {
+  width: 100%;
+  height: 100%;
+}
+
+.tool + .tool {
+  margin-right: 10px;
+}
+
+.whiteBIcon {
+  width: 80px;
+  cursor: pointer;
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: center;
+  font-size: 14px;
+}
+
+.whiteBIcon > img,
+.toolIcon > img,
+.arrow > img {
+  width: 100%;
+  height: 100%;
+}
+
+.check img {
+  width: 20px;
+  height: 20px;
+}
+
+.whiteBIcon > img {
+  box-shadow: 0px 4px 8px 0px rgb(44 133 255 / 14%);
+  border-radius: 15px;
+}
+
+.whiteBIcon > div:nth-child(2) {
+  height: 20px;
+  line-height: 20px;
+}
+
+.check {
+  /* width: 20px;
+  height: 20px; */
+  cursor: pointer;
+  margin: 10px 0 0;
+}
+
+.checkDiv {
+  display: flex;
+  align-items: center;
+}
+
+.checkDiv span {
+  margin-left: 5px;
+  color: #858585;
+}
+
+.customWidth >>> .el-dialog {
+  min-width: 500px !important;
+}
+
+.a_addBox {
+  margin: 10px 0;
+  background: #fff;
+  padding: 15px;
+  /* max-height: 600px; */
+  overflow: auto;
+}
+
+.a_add_box {
+  border-bottom: 2px solid #eee;
+  padding-bottom: 25px;
+}
+
+.a_add_head {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  margin: 10px 0 0 0;
+  font-size: 18px;
+}
+
+.a_add_checkType {
+  margin-top: 10px;
+  display: flex;
+  font-size: 14px;
+  align-items: center;
+}
+
+.a_add_checkType span {
+  box-sizing: border-box;
+  padding: 0 0 5px 0;
+  cursor: pointer;
+}
+
+.a_add_checkType span + span {
+  margin-left: 10px;
+}
+
+.a_add_checkType .active {
+  border-bottom: 2px solid #409eff;
+  color: #409eff;
+}
+
+.a_add_head .a_add_head_input {
+  width: 100%;
+}
+
+.a_add_head .a_add_head_div {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+}
+
+.a_add_body {
+  display: flex;
+  /* align-items: center; */
+  align-items: flex-end;
+}
+
+.a_add_input {
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+}
+
+.a_add_input_choice {
+  flex-direction: column;
+  margin-right: 10px;
+}
+
+.a_add_input_choice >>> .el-radio {
+  display: flex;
+  align-items: center;
+  flex-direction: row-reverse;
+  margin: 30px 0 0 0;
+  position: relative;
+}
+
+.a_add_input_choice >>> .el-checkbox {
+  display: flex;
+  align-items: center;
+  flex-direction: row-reverse;
+  margin: 30px 0 0 0;
+  position: relative;
+}
+
+.width100 {
+  width: 100%;
+}
+
+.a_add_input .a_add_persent {
+  width: 100%;
+}
+
+.a_add_persent_div {
+  width: 100%;
+  display: flex;
+  align-items: center;
+}
+
+.a_add_persent_div span {
+  margin: 5px 0;
+}
+
+.a_add_persent_div span:nth-child(1) {
+  width: 30%;
+}
+
+.a_add_persent_div span:nth-child(2) {
+  width: 7%;
+}
+
+.a_add_persent_div span:nth-child(3) {
+  width: 40%;
+}
+
+.a_add_body_div {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  /* flex-direction: column; */
+  position: absolute;
+  right: -20px;
+  transform: translateX(100%);
+}
+
+.a_add_body_div >>> .el-button--primary {
+  background: #466b99;
+  border: none;
+}
+
+.all_choose {
+  display: flex;
+  flex-direction: row;
+  align-items: flex-start;
+  width: 100%;
+}
+
+.all_choose > span {
+  min-width: fit-content;
+  display: block;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  margin-right: 20px;
+  font-weight: bold;
+  font-size: 14px;
+}
+
+.all_choose >>> .el-checkbox-group {
+  display: flex;
+  flex-direction: row;
+  width: 100%;
+  flex-wrap: wrap;
+  align-content: center;
+  justify-content: flex-start;
+  align-items: center;
+  margin-top: 3px;
+}
+
+.all_choose > .el-checkbox-group >>> .el-checkbox {
+  margin-bottom: 10px;
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  margin-right: 10px;
+}
+
+.all_choose > .el-checkbox-group > .el-checkbox >>> .el-checkbox__label {
+  min-width: 80px;
+  overflow: hidden;
+  width: 80px;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.all_choose > .el-checkbox-group > .el-checkbox >>> .el-checkbox__label:hover {
+  width: auto;
+}
+
+.choose > div:nth-child(3) > span {
+  /* letter-spacing: 0 !important; */
+}
+
+.choose {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  height: 100%;
+  justify-content: space-evenly;
+  align-items: flex-start;
+}
+
+.both {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  width: 100%;
+  align-items: center;
+  justify-content: flex-start;
+  margin: 15px 0;
+}
+
+.notice >>> .el-dialog {
+  width: 500px !important;
+  text-align: center;
+}
+
+.notice >>> .el-button {
+  margin-top: 20px;
+}
+
+.whiteBg {
+  background: #fff;
+  border-radius: 10px;
+}
+
+.wb_j_box {
+  display: flex;
+  width: 100%;
+  padding: 10px 20px;
+  box-sizing: border-box;
+}
+
+.wb_j_box_content {
+  width: calc(100% - 55% - 100px);
+  display: flex;
+  align-items: center;
+}
+
+.wb_j_box_p_box {
+  max-width: calc(100% - 200px);
+  word-break: break-all;
+  overflow: hidden;
+  margin: 0 0 0 10px;
+  font-size: 14px;
+  color: #6e6e6e;
+}
+
+.chooseWho {
+  display: flex;
+  width: 410px;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  justify-content: space-between;
+  padding-bottom: 10px;
+}
+
+.chooseWho > div {
+  cursor: pointer;
+  padding-bottom: 10px;
+  font-weight: bold;
+}
+
+.isChooseActive {
+  color: #3e88f4;
+  border-bottom: 2px solid #2f80f3;
+}
+
+.toolSort {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  justify-content: flex-start;
+  align-items: flex-start;
+}
+
+.toolSort > div {
+  margin-right: 10px;
+}
+
+.tools {
+  width: 100%;
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: flex-start;
+}
+
+.leftTools,
+.rightTools {
+  width: 50%;
+}
+
+.leftTools + .leftTools {
+  border-top: 1px solid #dbdbdb;
+  padding-top: 30px;
+}
+
+.rightTools {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  justify-content: space-around;
+}
+
+.firstToolList {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: center;
+}
+
+.iconList {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  justify-content: flex-start;
+  align-items: center;
+  margin: 20px 0 5px 0;
+  width: 240px;
+  min-width: 240px;
+}
+
+.iconTool {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: center;
+  justify-content: flex-start;
+  margin: 15px 10px;
+}
+
+.toolIcon {
+  width: 50px;
+}
+
+.taskBorder {
+  /*border: 1px solid #e1e1e1; */
+  border-radius: 8px;
+  margin-top: 10px;
+  /* min-height: 1160px; */
+  position: relative;
+  background: #fff;
+  padding: 20px 20px 0;
+  overflow: hidden;
+  box-sizing: border-box;
+}
+
+.smallTaskBorder {
+  height: 340px;
+  min-height: 340px !important;
+  overflow: hidden;
+}
+
+.taskBorder > div {
+  /* padding: 30px 0 10px 30px; */
+}
+
+.addTaskBorder {
+  /* border: 2px solid #5E9AFC; */
+  border-radius: 8px;
+  margin-top: 10px;
+  cursor: pointer;
+  /* height: 50px;
+  line-height: 50px; */
+  background: #fff;
+  padding: 15px 0;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+/* .addTaskBorder>div {
+  margin: 0 auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.addTaskBorder>div>img {
+  width: 20px;
+}
+
+.addTaskBorder>div>span {
+  font-size: 16px;
+  margin-left: 10px;
+  color: #5E9AFC;
+} */
+
+.funBlock {
+  display: flex;
+  padding: 15px 0;
+  flex-direction: row;
+  justify-content: center;
+  align-items: center;
+  position: absolute;
+  right: 0;
+  bottom: 0;
+  background: #fff;
+  width: 100%;
+  height: 60px;
+  z-index: 9;
+}
+
+.fold {
+  display: flex;
+  margin: 0 20px;
+  flex-direction: row;
+  align-items: center;
+  cursor: pointer;
+  color: #2b7bff;
+}
+
+.arrow {
+  margin-right: 8px;
+  width: 16px;
+  height: 16px;
+  min-width: 16px;
+  min-height: 16px;
+  background-size: 100% 100%;
+  display: block;
+  background-image: url(../../../assets/icon/new/u_up.png);
+  /* border-left: 7px solid transparent;
+  border-bottom: 7px solid #717C8D;
+  border-top: 0px solid transparent;
+  border-right: 7px solid transparent; */
+  /* box-sizing: border-box; */
+  transition: all 0.3s;
+}
+
+.arrowZ {
+  transform: rotate(180deg);
+}
+.addToolFun {
+  display: flex;
+  width: 150px;
+  flex-direction: row;
+  align-items: center;
+  justify-content: center;
+  border: 1px dashed;
+  border-radius: 5px;
+  height: 50px;
+  margin: 20px auto 35px;
+  cursor: pointer;
+}
+
+.addToolFun2 {
+  display: flex;
+  width: 150px;
+  border: 2px dashed #cad1dc;
+  flex-direction: row;
+  align-items: center;
+  justify-content: center;
+  border-radius: 5px;
+  height: 50px;
+  margin: 0 auto 0;
+  cursor: pointer;
+}
+
+.addToolImg {
+  width: 20px;
+  height: 20px;
+  margin-right: 10px;
+}
+
+.addToolsDia >>> .el-dialog__body {
+  padding: 20px;
+}
+
+.addToolsDia >>> .el-dialog__body > .toolChoose {
+  padding: 0;
+}
+
+.addToolsDia >>> .el-dialog__body > .toolChoose > .leftTools {
+  padding: 0;
+  border-bottom: none;
+  margin-bottom: 0;
+}
+
+.addToolsDia >>> .el-dialog__body > .toolChoose > .leftTools > .chooseWho {
+  width: 100%;
+}
+
+.lineCss >>> .el-form-item__label {
+  width: auto !important;
+}
+
+.lineCss >>> .el-form-item__content {
+  margin-left: 50px !important;
+}
+
+.newSteps {
+  display: flex;
+  width: 100% !important;
+  height: 80px;
+  cursor: pointer;
+  margin: 10px 0;
+  border-radius: 10px;
+  flex-direction: row;
+  align-content: center;
+  justify-content: center;
+  align-items: center;
+  margin: 0 !important;
+}
+
+/* 评价样式 */
+.elist_css {
+  padding-bottom: 60px !important;
+}
+
+.elist_title {
+  margin-bottom: 10px;
+}
+
+.elist_input {
+}
+
+.elist_input_box {
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+}
+
+.elist_input_box + .elist_input_box {
+  margin-top: 30px;
+}
+
+.elist_input .elist_input_box input {
+  font: inherit;
+  color: currentColor;
+  /* width: 200px; */
+  max-width: 200px;
+  padding: 8px 14px;
+  display: block;
+  min-width: 0;
+  outline: none;
+  border: 1px solid rgba(0, 0, 0, 0.23);
+  border-radius: 4px;
+  box-sizing: border-box;
+  background: #fff;
+  margin: 0 5px 0 0;
+}
+
+.elist_input .elist_input_box span {
+  height: 36px;
+  line-height: 36px;
+  color: rgb(82, 82, 82);
+  min-width: 80px;
+}
+
+.elist_input .elist_input_box .remove {
+  height: 20px;
+  width: 20px;
+  min-width: 20px;
+  background-size: 100% 100%;
+  background-position: unset;
+  margin-left: 5px;
+}
+
+.elist_input_box >>> .el-rate {
+  display: flex;
+  height: 36px;
+  align-items: center;
+}
+
+.elist_input_box .elist_inptu_text {
+  width: 100%;
+  display: flex;
+  align-items: center;
+  margin-top: 10px;
+}
+
+.elist_input_box .elist_inptu_text input {
+  /* width: 500px; */
+  width: 100%;
+  max-width: unset;
+}
+
+.elist_input_box >>> .el-rate__icon {
+  font-size: 24px;
+}
+
+.elist_btn {
+  margin-top: 10px;
+}
+
+.lineTitle {
+  /* margin-top: 15px; */
+  width: 110px;
+  font-size: 16px;
+  display: flex;
+  align-items: center;
+  line-height: 20px;
+}
+
+.lineTitle::before {
+  content: "";
+  display: block;
+  width: 3px;
+  height: 20px;
+  background: #0061ff;
+  border-radius: 3px;
+  margin: 0 5px 0 0;
+}
+
+.clineTitle::before {
+  content: "";
+  display: block;
+  min-width: 10px;
+  width: 10px;
+  height: 10px;
+  background: #0061ff;
+  border-radius: 50%;
+  margin: 0 5px 0 0;
+}
+
+.courseTop {
+  display: flex;
+  flex-direction: row;
+  justify-content: space-between;
+  align-items: center;
+  width: calc(100%);
+  padding: 10px 0;
+  margin: 0 auto;
+}
+
+.stepsNav {
+  display: flex;
+  flex-direction: row;
+  justify-content: flex-start;
+  align-items: center;
+}
+
+.stepsWord {
+  font-size: 18px;
+  color: #fff;
+  font-weight: bold;
+  margin-left: auto;
+  background: rgb(15, 126, 255);
+  border-radius: 5px;
+  padding: 3px 25px;
+  box-sizing: border-box;
+}
+
+.rightBox {
+  width: calc(100%);
+  background: #f0f2f5;
+  /* border-radius: 10px; */
+  overflow: auto;
+  height: calc(100% - 120px);
+  margin: 0 auto;
+  position: relative;
+  box-sizing: border-box;
+  border-radius: 5px;
+}
+
+.e_add_top {
+  display: flex;
+  justify-content: space-between;
+  padding: 20px 20px 0 20px;
+  border-radius: 3px;
+  background: #fff;
+}
+
+.e_add_title2 {
+  display: flex;
+  align-items: center;
+}
+
+.e_add_title2 span {
+  width: 40px;
+}
+
+.e_add_title {
+  display: flex;
+  align-items: center;
+  color: #b8b8b8;
+  font-size: 18px;
+  position: relative;
+  height: 40px;
+}
+
+.e_add_title span {
+  margin-right: 10px;
+}
+
+.e_add_title .el_input {
+  width: 300px;
+}
+
+.e_add_title >>> .el-input__inner {
+  width: 400px;
+}
+
+.e_add_btn {
+}
+
+.e_add_content {
+  display: flex;
+  width: 100%;
+}
+
+.e_add_list {
+  background: #fff;
+  height: 500px;
+  width: 210px;
+  position: relative;
+  margin: 15px 5px 0 0;
+  flex-shrink: 0;
+  display: flex;
+  flex-direction: column;
+}
+
+.e_add_list_title {
+  font-size: 20px;
+  width: 100%;
+  box-sizing: border-box;
+  padding: 15px 40px;
+  text-align: center;
+  border-bottom: 1px solid #eaeaea;
+  position: relative;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  height: 57px;
+  background: #f6f6f6;
+}
+
+.e_add_list_title span {
+  overflow: hidden;
+  white-space: nowrap;
+  text-overflow: ellipsis;
+}
+
+.e_add_list_title img {
+  position: absolute;
+  right: 15px;
+  width: 25px;
+  cursor: pointer;
+  top: 50%;
+  transform: translateY(-50%);
+}
+
+.e_add_list_body {
+  height: calc(100% - 187px);
+  overflow: auto;
+}
+
+.e_add_list_child {
+  width: 100%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  position: relative;
+  box-sizing: border-box;
+  padding: 15px 40px;
+  text-align: center;
+}
+
+.e_add_list_child span {
+  overflow: hidden;
+  white-space: nowrap;
+  text-overflow: ellipsis;
+  cursor: pointer;
+}
+
+.e_add_list_child img {
+  position: absolute;
+  right: 10px;
+  width: 21px;
+  cursor: pointer;
+  top: 50%;
+  transform: translateY(-50%);
+}
+
+.e_add_list_child + .e_add_list_child {
+  border-top: 1px solid #eaeaea;
+}
+
+.e_add_list_child .active {
+  color: #409eff;
+}
+
+.e_add_list_btn {
+  position: absolute;
+  bottom: 0;
+  height: 50px;
+  background: rgb(120, 120, 254);
+  width: 100%;
+  color: #fff;
+  font-size: 16px;
+  text-align: center;
+  line-height: 50px;
+  cursor: pointer;
+}
+
+.e_add_list_detail {
+  position: absolute;
+  bottom: 0;
+  height: 130px;
+  background: rgb(120, 120, 254);
+  width: 100%;
+  color: #fff;
+  font-size: 16px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.e_add_list_detail textarea {
+  height: 90%;
+  width: 95%;
+  border: none;
+  resize: none;
+  outline: none;
+  padding: 5px;
+  box-sizing: border-box;
+}
+
+.e_add_list_pbox {
+  width: 100%;
+}
+
+.e_add_list_pbox_title {
+  height: 50px;
+  background: #fff;
+  display: flex;
+  align-items: center;
+  width: 100%;
+  box-sizing: border-box;
+  padding: 0 20px;
+  flex-direction: row;
+  flex-wrap: wrap;
+}
+
+.type_title {
+  font-size: 18px;
+  font-weight: 700;
+}
+
+.type_content {
+  font-size: 16px;
+  margin-left: 30px;
+}
+
+.type_content span + span {
+  margin-left: 20px;
+}
+
+.type_content span {
+  cursor: pointer;
+  padding-bottom: 5px;
+  box-sizing: border-box;
+}
+
+.type_content .active {
+  color: #409eff;
+  border-bottom: 2px solid #409eff;
+}
+
+.e_add_list_pbox_content {
+  height: calc(100% - 50px);
+  display: flex;
+  align-items: center;
+  width: 100%;
+  background: #fff;
+}
+
+.mbCss {
+  width: 100%;
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-content: center;
+  align-items: flex-start;
+  justify-content: flex-start;
+}
+
+.pjCss {
+  /* width: 42%; */
+  width: calc(100% - 55%);
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: flex-start;
+  margin-top: 1.5%;
+}
+
+.e_box {
+  display: flex;
+  flex-wrap: wrap;
+  max-height: 500px;
+  align-items: flex-start;
+  overflow: auto;
+}
+
+.e_card {
+  border: 1px solid #ccc;
+  background: #fff;
+  margin-right: 20px;
+  width: 270px;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  border-radius: 5px;
+  margin-top: 10px;
+  text-align: center;
+}
+
+.e_card_picture {
+  margin: 10px 0;
+}
+
+.e_card_picture > img {
+  width: 50px;
+}
+
+.e_card_name {
+  width: 100%;
+  padding: 0 10px;
+  box-sizing: border-box;
+  margin-bottom: 10px;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.e_card_time {
+  width: 100%;
+  padding: 0 10px;
+  box-sizing: border-box;
+  font-size: 15px;
+  color: #c3c3c3;
+  margin-bottom: 10px;
+}
+
+.e_card_btn {
+  height: 40px;
+  display: flex;
+  align-items: center;
+  width: 100%;
+  background: rgb(244, 244, 244);
+}
+
+.e_card_btn:hover {
+  background: rgb(221 221 221);
+}
+
+.e_card_btn span {
+  flex: 1 1 auto;
+  text-align: center;
+  cursor: pointer;
+}
+
+.addEva {
+  border: 1px solid #ccc;
+  background: #fff;
+  margin-right: 20px;
+  width: 270px;
+  height: 149px;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  border-radius: 5px;
+  margin-top: 10px;
+  text-align: center;
+  cursor: pointer;
+  justify-content: center;
+}
+
+.addEva > img {
+  width: 50px;
+  object-fit: cover;
+}
+
+.uploadFm {
+  border: 1px dashed #ccc;
+  width: 100%;
+  height: 140px;
+  position: relative;
+  cursor: pointer;
+  display: flex;
+  flex-direction: column;
+  justify-content: center;
+  align-items: center;
+  font-size: 14px;
+  color: #6e6e6e;
+  position: relative;
+}
+
+.cover_p {
+  width: 100% !important;
+  height: 100%;
+  object-fit: cover;
+}
+
+.uploadFm2:hover .cover_mask {
+  display: flex !important;
+}
+
+.cover_mask {
+  display: none;
+  width: 100%;
+  height: 100%;
+  position: absolute;
+  background: #00000054;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+}
+
+.cover_mask > img {
+  width: 30px;
+}
+
+.cover_mask > span {
+  color: #fff;
+  font-size: 12px;
+}
+
+.uploadFm > img {
+  width: 50px;
+}
+
+.fileCss {
+  width: 100%;
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  justify-content: space-around;
+  align-items: center;
+  padding-top: 15px;
+}
+
+.fileCss > div {
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+}
+
+.fileCss .spanName {
+  margin-top: 10px;
+}
+
+.sysPicBox {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  align-content: flex-start;
+  height: 435px;
+  overflow: auto;
+  position: relative;
+}
+
+.picNone {
+  position: absolute;
+  left: 50%;
+  top: 45%;
+  transform: translate(-50%, -50%);
+  width: fit-content;
+  color: #9c9c9c;
+}
+
+.sysPic {
+  width: 200px;
+  height: 115px;
+  margin: 0 20px 20px 0;
+  cursor: pointer;
+}
+
+.sysPic > img,
+.isSysPic > img,
+.deletePic > img {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+}
+
+.isSysPic {
+  width: 200px;
+  height: 115px;
+  position: relative;
+}
+
+.deletePic {
+  width: 20px;
+  height: 20px;
+  position: absolute;
+  top: 0;
+  right: 0;
+  cursor: pointer;
+}
+
+.select_box1 {
+  height: 100%;
+}
+
+.select_box1_img {
+  background: #fff;
+  border-radius: 5px;
+  padding: 15px;
+  box-sizing: border-box;
+  margin-bottom: 20px;
+}
+
+.select_box1_title {
+  padding: 0 0 15px 0;
+  border-bottom: 1px solid #eee;
+  margin-bottom: 15px;
+}
+
+.select_box1_title span:nth-child(1) {
+  font-size: 16px;
+  margin-right: 20px;
+  color: #000;
+}
+
+.select_box1_title span:nth-child(2) {
+  font-size: 14px;
+  color: rgb(112, 112, 112);
+}
+
+.select_box1_add_img {
+}
+
+.select_box1_select {
+  background: #fff;
+  border-radius: 5px;
+  padding: 15px;
+  box-sizing: border-box;
+  height: calc(100% - 200px);
+  overflow: auto;
+}
+
+.select_box2 {
+  height: 100%;
+}
+
+.select_box2_title {
+  background: #fff;
+  border-radius: 5px;
+  padding: 5px 10px;
+  box-sizing: border-box;
+  margin-bottom: 10px;
+}
+
+.select_box2_box {
+  display: flex;
+  height: calc(100% - 30px);
+}
+
+.select_box2_img {
+  width: calc(100% - 310px);
+  height: 100%;
+  overflow: auto;
+  background: #fff;
+  border-radius: 5px;
+}
+
+.select_box2_img img {
+  width: 100%;
+}
+
+.select_box2_answer {
+  background: #fff;
+  margin-left: 10px;
+  border-radius: 5px;
+  width: 300px;
+  overflow: auto;
+  height: 100%;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  padding-top: 10px;
+  box-sizing: border-box;
+}
+
+.select_box2_answer_box {
+  margin: 0 0 10px 0;
+  width: 85%;
+}
+
+.rate_textarea {
+  font: inherit;
+  color: currentColor;
+  width: 100%;
+  padding: 8px 14px;
+  display: block;
+  min-width: 0;
+  outline: none;
+  border: 1px solid rgba(0, 0, 0, 0.23);
+  border-radius: 4px;
+  box-sizing: border-box;
+  background: #fff;
+  margin: 0 20px 0 0;
+  resize: none;
+}
+
+.select_answer_title {
+  text-align: left;
+  width: 85%;
+  margin-bottom: 10px;
+  font-size: 18px;
+  color: #8e8e8e;
+}
+
+.mask {
+  background-color: rgb(0 0 0 / 30%);
+  /* position: fixed; */
+  position: absolute;
+  top: 0;
+  left: 0;
+  width: 100%;
+  height: 100%;
+  z-index: 90;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.progressBox {
+  width: 300px;
+  height: 150px;
+  background: #fff;
+  border-radius: 10px;
+  box-shadow: 0 0 6px 1px #bfbfbf;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+  position: relative;
+  color: #6c6c6c;
+}
+
+.progressBox >>> .el-progress-bar__outer {
+  background-color: #d1dfff !important;
+}
+
+.progressBox .lbox {
+  height: 50px;
+  font-size: 19px;
+  display: flex;
+  align-items: center;
+  color: #747474;
+}
+
+.progressBox .lbox img {
+  width: 40px;
+  margin-right: 20px;
+}
+
+.closeCss {
+  position: absolute;
+  top: 8px;
+  right: 8px;
+  cursor: pointer;
+  width: 20px;
+  height: 20px;
+}
+
+.closeCss > img {
+  width: 100%;
+  height: 100%;
+}
+
+.updateTips::after {
+  content: "协同编辑课程暂不支持修改基本信息,只支持修改阶段内容。";
+  font-size: 14px;
+  margin-left: 20px;
+  font-weight: 400;
+  color: #ff3a3a;
+}
+
+.updateMask {
+  width: 100%;
+  z-index: 3;
+  top: 0;
+  position: absolute;
+  /* background-color: rgba(0,0,0,.3); */
+}
+
+.t_j_box {
+  display: flex;
+}
+
+.t_j_box span:nth-child(1) {
+  width: 15%;
+  overflow: hidden;
+  margin-right: 10px;
+  text-overflow: ellipsis;
+  white-space: nowrap;
+}
+
+.t_j_box span:nth-child(2) {
+  width: 30%;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  margin-right: 10px;
+}
+
+.t_j_box span:nth-child(3) {
+  max-width: calc(55% - 20px);
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.sentenBox {
+  background: #fff;
+  height: 600px;
+  overflow: auto;
+  background-image: url("../../../assets/icon/conSentences/csBg.png");
+  background-position: 102%;
+  background-repeat: no-repeat;
+  background-size: 60%;
+}
+
+.sentenBox > .sentenContent {
+  padding-bottom: 10px;
+  width: 97%;
+  margin: 0 auto;
+}
+
+.sentenBox > .sentenContent + .sentenContent {
+  border-top: 1px solid #cbcbcb;
+}
+
+.addSen {
+  background: #409efe;
+  width: 90px;
+  color: #fff;
+  height: 35px;
+  text-align: center;
+  line-height: 35px;
+  border-radius: 5px;
+  float: right;
+  margin: 10px 20px 0 0;
+  cursor: pointer;
+}
+
+.sentenTop {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+}
+
+.sentenTop::before {
+  content: attr(index);
+  background: #3681fc;
+  border-radius: 50%;
+  color: #fff;
+  width: 25px;
+  height: 25px;
+  min-width: 25px;
+  min-height: 25px;
+  text-align: center;
+  line-height: 25px;
+  margin-right: 5px;
+}
+
+.sentenTop > div:nth-child(2) {
+  width: 300px;
+  margin: 0 15px;
+}
+
+.sentenTop > div:nth-child(3) {
+  background: #409efe;
+  color: #fff;
+  width: 65px;
+  height: 35px;
+  text-align: center;
+  line-height: 35px;
+  border-radius: 5px;
+  cursor: pointer;
+}
+
+.cardList {
+  padding: 20px 0 20px 0;
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  align-items: center;
+  box-sizing: border-box;
+  border-bottom: 1px solid #f4f4f4;
+  width: 98%;
+  margin: 0 auto;
+}
+
+.rightCardList {
+  display: flex;
+  flex-wrap: wrap;
+}
+
+.cardBox {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: wrap;
+  align-items: center;
+  align-content: center;
+}
+
+.isCard,
+.isCard1 {
+  width: auto;
+  padding: 0 20px;
+  height: 65px;
+  text-align: center;
+  line-height: 65px;
+  font-size: 14px;
+  cursor: pointer;
+  background-image: url("../../../assets/icon/conSentences/titleBorder.png");
+  background-size: 100% 100%;
+  position: relative;
+  z-index: 99;
+}
+
+.isCard1 {
+  background-image: url("../../../assets/icon/conSentences/answerBorder.png");
+}
+
+.isCard:hover .deleteWord {
+  display: block;
+}
+
+.isCard > div:nth-child(1),
+.isCard1 > div:nth-child(1) {
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  width: 100%;
+  margin: 0 auto;
+}
+
+.card {
+  width: 140px;
+  height: 65px;
+}
+
+.card > img {
+  width: 100%;
+  height: 100%;
+}
+
+.rightCardBox {
+  width: 98%;
+  margin: 10px auto 0;
+}
+
+.rightCardBox > div:nth-child(1) {
+  margin-bottom: 10px;
+}
+
+.cardCss {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: center;
+  border-bottom: 3px solid #b4c3d3;
+  padding: 0 0 5px 0;
+  /* margin-right: 10px; */
+}
+
+.cardCss > div:nth-child(2) {
+  background: #5b7b9d;
+  color: #fff;
+  width: 20px;
+  height: 20px;
+  border-radius: 50%;
+  text-align: center;
+  line-height: 20px;
+}
+
+.sentenTopBox {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  justify-content: space-between;
+  padding: 55px 0 0 20px;
+  box-sizing: border-box;
+  width: 85%;
+}
+
+.stepsBottom {
+  width: 85%;
+  margin-bottom: 20px;
+  box-shadow: 0 0 10px 10px #f7f7f7;
+  background: #f7f7f7;
+  border-radius: 10px;
+  overflow: hidden;
+}
+
+.course_left {
+  width: 300px;
+  height: auto;
+  position: relative;
+}
+
+.stepsBottom2 {
+  width: 300px;
+  margin: 10px 0;
+  /* box-shadow: 0 0 10px 10px #f7f7f7; */
+  /* background: #f7f7f7; */
+  border-radius: 8px;
+  overflow: hidden;
+  height: fit-content;
+  position: relative;
+  /* transition: all .5s; */
+}
+
+.navTop {
+  background: #53749b;
+  color: #fff;
+  height: 40px;
+  line-height: 40px;
+  padding-left: 15px;
+  font-size: 18px;
+}
+
+.navBottom {
+  background: #fff;
+  height: calc(100vh - 210px);
+  overflow: auto;
+}
+
+.navTask {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  padding: 10px 10px 10px 0;
+  cursor: pointer;
+  background: #ffffff;
+  width: 95%;
+  margin: 5px auto 5px;
+  box-sizing: border-box;
+  border-radius: 5px;
+  flex-wrap: wrap;
+  position: relative;
+}
+
+.navTask:hover > .chapter_upload_drag {
+  display: block;
+}
+.navTask .chapter_upload_open {
+  content: "";
+  display: block;
+  width: 16px;
+  height: 16px;
+  background-image: url(../../../assets/icon/new/icon_arrow.png);
+  background-size: 100%;
+  margin-left: 23px;
+}
+
+.noImage .chapter_upload_open {
+  display: none;
+  background-image: unset !important;
+}
+
+.isNavOpen .chapter_upload_open {
+  /* background-image: url(../../assets/icon/new/icon_arrow_a.png) !important; */
+  transform: rotate(90deg);
+}
+
+.isNavTask .chapter_upload_open {
+  background-image: url(../../../assets/icon/new/icon_arrow_a.png) !important;
+  transform: rotate(-90deg);
+}
+
+.isNavTask.isNavOpen .chapter_upload_open {
+  transform: rotate(0deg);
+}
+
+.dragOverTop {
+  border-top: 2px solid #0061ff !important;
+  border-radius: 0 !important;
+  margin-top: 10px;
+}
+
+.dragOverBottom {
+  border-bottom: 2px solid #0061ff !important;
+  border-radius: 0 !important;
+  margin-top: 10px;
+}
+
+.dragOverTop2 {
+  border-top: 2px solid #0061ff !important;
+  border-radius: 0 !important;
+}
+
+.dragOverBottom2 {
+  border-bottom: 2px solid #0061ff !important;
+  border-radius: 0 !important;
+}
+
+.isNavTask {
+  /* background: #3681FC; */
+  background: #eef3fb;
+}
+
+.isNavTask > .chapter_upload_drag {
+  background-image: url(../../../assets/icon/new/icon_course_drag_active.png) !important;
+}
+
+.isNavTask .nt_taskName {
+  /* color: #fff !important; */
+  font-weight: bold !important;
+  color: #0061ff !important;
+}
+
+.isNavTask .nt_taskTitle {
+  /* color: #AECCFE !important; */
+  font-weight: bold !important;
+  color: #0061ff !important;
+}
+
+.navTask .nt_taskBox {
+  width: calc(100% - 40px);
+  padding: 0 0 0 5px;
+  box-sizing: border-box;
+  box-sizing: border-box;
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: baseline;
+}
+
+.navTask .nt_taskTitle {
+  /* color: #717C8D; */
+  color: #060e17;
+  line-height: 25px;
+  font-size: 16px;
+  /* min-width: 66px; */
+}
+
+.navTask .nt_taskName {
+  /* color: #fff; */
+  /* max-width: 130px; */
+  /* width: 100%; */
+  max-width: calc(100% - 66px);
+  font-size: 16px;
+  color: #060e17;
+  /* color: #0E1E33; */
+}
+
+.navTask .nt_taskName span {
+  width: 100%;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  display: block;
+}
+
+.gjBox {
+  width: calc(100% - 25px);
+  padding: 0 0 0 0;
+  box-sizing: border-box;
+  border-left: 1px solid #cad1dc;
+  margin-left: 25px;
+}
+
+.gjBox > div {
+  display: flex;
+  align-items: center;
+}
+
+.gjBox > div::before {
+  content: "";
+  height: 1px;
+  width: 10px;
+  background: #cad1dc;
+  display: block;
+  margin-right: 5px;
+}
+
+.gjCss {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  padding: 15px 0;
+  box-sizing: border-box;
+  font-size: 14px;
+  cursor: pointer;
+}
+
+.isGjCss {
+  color: #0061ff;
+}
+
+.groupBox {
+}
+
+.groupContent + .groupContent {
+  margin-top: 30px;
+}
+
+.groupTitle {
+  font-size: 24px;
+  color: rgb(80, 80, 80);
+  margin-bottom: 20px;
+}
+
+.groupName {
+  display: flex;
+  align-items: center;
+}
+
+.groupn {
+  font-size: 15px;
+  margin-right: 10px;
+}
+
+.groupName + .groupName {
+  margin-top: 15px;
+}
+
+.groupBtn {
+  margin-left: 10px;
+}
+
+.groupContent >>> .el-input-number.is-without-controls .el-input__inner {
+  text-align: left;
+}
+
+.radioBox > div {
+  margin: 10px 0 0 10px;
+}
+
+.radioBox >>> .el-radio__input,
+.radioBox >>> .el-checkbox__inner {
+  margin-left: 10px;
+}
+
+.radioBox >>> .el-radio__label,
+.radioBox >>> .el-checkbox__label {
+  display: flex;
+  align-items: center;
+}
+
+.inImg {
+  width: 50px;
+}
+
+.inImg > img {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+}
+
+.upCss >>> .el-upload-list--picture .el-upload-list__item {
+  height: auto;
+  padding: 10px;
+  margin: 0;
+}
+
+.upCss >>> .el-upload-list {
+  width: 100%;
+}
+
+.upCss >>> .el-upload-list--picture .el-upload-list__item-thumbnail {
+  width: 100%;
+  height: 120px;
+  object-fit: contain;
+  background: unset;
+  margin-left: 0;
+}
+
+.upCss
+  >>> .el-upload-list--picture
+  .el-upload-list__item.is-success
+  .el-upload-list__item-name {
+  display: none;
+}
+
+.tcMember + .tcMember::before {
+  content: "、";
+}
+
+.xzUpImg {
+  width: 25px;
+  height: 25px;
+  min-width: 25px;
+  min-height: 25px;
+  cursor: pointer;
+  margin: 0 10px;
+}
+
+.xzUpImg > img {
+  width: 100%;
+  height: 100%;
+}
+
+.closeCss {
+  position: absolute;
+  top: 8px;
+  right: 8px;
+  cursor: pointer;
+  width: 20px;
+  height: 20px;
+}
+
+.closeCss > img {
+  width: 100%;
+  height: 100%;
+}
+
+.moveBtn {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+  width: 55px;
+}
+
+.timuUpImg {
+  display: flex;
+  flex-direction: row;
+  align-items: center;
+  width: 100%;
+  margin-right: 10px;
+}
+
+.timuUpImg > div:nth-child(1) {
+  margin-right: 10px;
+  display: flex;
+  align-items: center;
+  width: 100%;
+}
+
+.timuImgBox {
+  margin: 10px 0;
+  display: flex;
+  flex-direction: column;
+  flex-wrap: wrap;
+  align-items: flex-start;
+}
+
+.timuImg {
+  width: 100px;
+  margin: 5px 0;
+  cursor: pointer;
+  position: relative;
+}
+
+.timuImg:hover .deleteWord {
+  display: block;
+}
+
+.deleteWord {
+  width: 25px;
+  height: 25px;
+  position: absolute;
+  right: -5px;
+  top: -5px;
+  cursor: pointer;
+  display: none;
+}
+
+.timuImg > img,
+.deleteWord > img {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+}
+
+.e_add_delete {
+  cursor: pointer;
+  margin-left: 10px;
+}
+
+.pType_box {
+  margin-top: 30px;
+  align-items: flex-end;
+}
+
+.noneBox {
+  height: 100%;
+  width: 100%;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin-top: 150px;
+}
+
+.noneBox > img {
+  width: 300px;
+}
+
+.textarea_css {
+  display: block;
+  resize: none;
+  padding: 10px 15px;
+  line-height: 1.5;
+  box-sizing: border-box;
+  width: 100%;
+  font-size: 14px;
+  color: #606266;
+  background-color: #fff;
+  background-image: none;
+  border: 1px solid #dcdfe6;
+  border-radius: 4px;
+  transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
+  outline: none;
+  overflow: hidden;
+  height: 46px;
+  font-family: "Microsoft YaHei";
+}
+
+.textarea_css::-webkit-input-placeholder {
+  color: #c0c4cc;
+}
+
+.textarea_css:focus {
+  border-color: #409eff;
+  outline: 0;
+}
+
+.moveBtn2 {
+  flex-direction: column;
+  width: fit-content;
+  margin: 0 10px 0 10px;
+}
+
+.moveBtn2 .chapter_upload_down,
+.moveBtn2 .chapter_upload_up {
+  width: 16px;
+  height: 16px;
+}
+
+.moveBtn2 .chapter_upload_up::after,
+.moveBtn2 .chapter_upload_down::after {
+  width: 10px;
+  height: 10px;
+}
+
+.fullStyle >>> .el-dialog__body {
+  height: calc(100% - 125px) !important;
+  box-sizing: border-box;
+}
+
+.fullStyle >>> .el-dialog {
+  width: 100% !important;
+  max-width: 100% !important;
+  height: 100% !important;
+  margin: 0 !important;
+}
+
+.fullStyle {
+  width: 100% !important;
+  max-width: 100% !important;
+  height: 100% !important;
+  margin: 0 auto !important;
+}
+.fullStyle1 >>> .el-dialog__body {
+  height: auto !important;
+}
+
+.wb_j_box_btn {
+  width: calc(100% - 30px);
+  display: flex;
+  height: 40px;
+  border: 1.5px solid #cad1dc;
+  border-radius: 4px;
+  box-sizing: border-box;
+  align-items: center;
+  font-size: 14px;
+  cursor: pointer;
+  overflow: hidden;
+}
+
+.wb_j_box_btn:hover {
+  border: 1.5px solid #0061ff;
+}
+
+.wb_j_box_title {
+  background: #f0f4fa;
+  height: 100%;
+  line-height: 40px;
+  width: 90px;
+  text-align: center;
+  color: #060e17;
+  border-right: 1.5px solid #cad1dc;
+  box-sizing: border-box;
+}
+
+.wb_j_box_btn_c {
+  width: calc(100% - 90px);
+  padding: 0 35px 0 10px;
+  box-sizing: border-box;
+  position: relative;
+}
+
+.wb_j_box_span {
+  width: 100%;
+  overflow: hidden;
+  white-space: nowrap;
+  text-overflow: ellipsis;
+  word-wrap: break-word;
+  color: #717c8d;
+}
+
+.wb_j_box_arrow {
+  content: "";
+  width: 14px;
+  height: 14px;
+  background: url(../../../assets/icon/new/u_arrow.png);
+  background-size: 100% 100%;
+  position: absolute;
+  right: 12px;
+  top: 50%;
+  transform: translateY(-50%);
+}
+
+.check_classBox {
+  height: 400px;
+  display: flex;
+  border-top: 1.5px solid #e7ebf1;
+  border-bottom: 1.5px solid #e7ebf1;
+}
+
+.check_class_right {
+  width: 130px;
+  border-right: 1px solid #e7ebf1;
+  display: flex;
+  align-items: center;
+  flex-direction: column;
+  height: 100%;
+  overflow: auto;
+  padding: 15px 0;
+  box-sizing: border-box;
+}
+
+.check_class {
+  width: 85%;
+  border-radius: 5px;
+  height: 30px;
+  min-height: 30px;
+  line-height: 30px;
+  text-align: center;
+  padding: 0 10px;
+  box-sizing: border-box;
+  cursor: pointer;
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.check_class.activeX {
+  background: #e0eafb;
+  color: #3681fc;
+  font-weight: 700;
+}
+
+.check_class + .check_class {
+  margin-top: 15px;
+}
+
+.check_class_left {
+  background: #fafafa;
+  width: calc(100% - 130px);
+  padding: 15px;
+  box-sizing: border-box;
+}
+
+.check_class_all_box {
+  display: flex;
+  margin-bottom: 10px;
+}
+
+.all_check {
+  display: flex;
+  align-items: center;
+  padding: 2px 0 0;
+  margin-left: 10px;
+}
+
+.all_check >>> .el-checkbox__label {
+  line-height: 18px;
+}
+
+.check_class_left_title {
+  font-size: 16px;
+  font-weight: 700;
+}
+
+.check_class_item {
+  display: flex;
+  flex-wrap: wrap;
+  height: calc(100% - 45px);
+  overflow: auto;
+  justify-content: flex-start;
+  align-items: flex-start;
+  align-content: flex-start;
+}
+
+.class_item:first-child {
+  /* margin: 0 15px 15px 67px; */
+}
+.class_item {
+  margin: 0 15px 15px 0;
+}
+
+.class_item:hover >>> .el-checkbox__label {
+  color: #409eff;
+}
+
+.class_item >>> .el-checkbox__label {
+  color: #0e1e33;
+}
+
+.class_item:hover >>> .el-checkbox__inner {
+  border-color: #409eff;
+}
+
+.class_item >>> .el-checkbox,
+.class_item >>> .el-checkbox__input {
+  display: flex;
+  align-items: center;
+}
+.taskTitle {
+  font-size: 20px;
+  font-weight: bold;
+  margin-bottom: 35px;
+}
+
+.taskTitle:after {
+  content: "";
+  width: 100%;
+  display: block;
+  height: 1px;
+  background: #cad1dc;
+  position: absolute;
+  left: 0;
+  margin: 15px 0 0;
+}
+
+.text_panel >>> .text {
+  height: 400px;
+}
+.Ovh {
+  width: 4em;
+  -webkit-line-clamp: 2;
+  text-align: center;
+  display: -webkit-box;
+  -webkit-box-orient: vertical;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.pptIframeArea {
+  width: 100%;
+  height: 1000px;
+  margin: 10px 0;
+  background-color: #fff;
+  overflow: hidden;
+  border-radius: 10px;
+}
+
+.pptIframeArea > iframe {
+  width: 98%;
+  height: 100%;
+  border: 0;
+}
+
+.pptToolsArea{
+  width:100%;
+  height:auto;
+  background-color: #fff;
+  border-radius:10px;
+  margin:10px 0;
+  box-sizing: border-box;
+  flex-wrap:wrap;
+}
+
+.pta_header{
+  width:100%;
+  height:60px;
+  background:#FAFBFC;
+  border-radius:10px 10px 0 0;
+  display:flex;
+  align-items:center;
+  box-sizing:border-box;
+  padding:0 30px;
+  border-bottom:solid 1px #E4EAEE;
+}
+
+.pta_header>span{
+  font-size:16px;
+  color:#000;
+  font-weight:bold;
+}
+
+.pta_buttonArea{
+  width:100%;
+  height:auto;
+  display:flex;
+  align-items:center;
+  box-sizing:border-box;
+  padding:20px 20px;
+  border-bottom:solid 1px #E1E8ED;
+}
+
+.pta_ba_item{
+  width:auto;
+  height:40px;
+  display:flex;
+  align-items:center;
+  justify-content:center;
+  padding:0 20px;
+  color:#fff;
+  border:solid 2px #fff;
+  border-radius:5px;
+  margin-right:15px;
+  cursor: pointer;
+  font-weight:bold;
+  background:#fff;
+  transition:.2s;
+}
+
+.pta_ba_item:hover{
+  background:#85858513;
+}
+
+.pta_ba_item>svg{
+  width:20px;
+  height:20px;
+}
+
+.pta_ba_item>span{
+  margin:0 5px;
+}
+
+.pta_ba_item1{
+  color:#2ED574;
+  border-color:#2ED574;
+}
+
+.pta_ba_item2{
+  color:#FF6347;
+  border-color:#FF6347;
+}
+
+.pta_ba_item3{
+  color:#3742FA;
+  border-color:#3742FA;
+}
+
+.pta_tooListArea{
+  width:100%;
+  height:auto;
+  box-sizing:border-box;
+  padding:30px;
+}
+
+.pta_tla_header{
+  width:100%;
+  height:auto;
+  display:flex;
+  align-items:center;
+  justify-content:space-between;
+  margin-bottom:30px;
+}
+
+.pta_tla_header>span{
+  font-size:16px;
+  font-weight:bold;
+  color:#000;
+}
+
+.pta_tla_header>div{
+  color:#78869A;
+  font-size: 14px;
+}
+
+.pta_tla_header>div>span{
+  margin:0 5px;
+}
+
+.pta_tla_filterArea{
+  width:100%;
+  height:auto;
+  margin-bottom:30px;
+  display:flex;
+  align-items: center;
+}
+
+.pta_tla_filterArea>span{
+  display:flex;
+  align-items:center;
+  justify-content:center;
+  width:auto;
+  height:30px;
+  padding:0 20px;
+  border-radius:20px;
+  border:solid 1px #E2E8F0;
+  margin-right:10px;
+  cursor:pointer;
+  font-size:14px;
+  color:#4A5568;
+  transition:.2s;
+}
+
+.filterActive{
+  background:#0458D2 !important;
+  color:#fff !important;
+  border-color:#0458D2 !important;
+}
+
+.pta_tla_list{
+  width:100%;
+  height:auto;
+}
+
+.pta_tla_l_item{
+  width:100%;
+  height:80px;
+  border-radius:10px;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  padding:0 20px;
+  box-sizing: border-box;
+  margin-bottom:20px;
+  background-color: #fff;
+  border:solid 1px #E1E8ED;
+  transition:.2s;
+}
+
+.pta_tla_l_i_left{
+  width:auto;
+  height:auto;
+  display: flex;
+  align-items: center;
+}
+
+.pta_tla_l_i_left>img{
+  width: 40px;
+  height:40px;
+  margin-right:10px;
+  box-shadow: 0px 4px 8px 0px rgb(44 133 255 / 14%);
+  border-radius: 5px;
+}
+
+.pta_tla_l_i_left>svg{
+  width: 40px;
+  height:40px;
+  margin-right:10px;
+  box-shadow: 0px 4px 8px 0px rgb(44 133 255 / 14%);
+  border-radius: 5px;
+}
+
+.pta_tla_l_i_left>div{
+  display: flex;
+  flex-direction: column;
+  align-items: flex-start;
+}
+
+.pta_tla_l_i_left>div>span:nth-child(1){
+  font-size:16px;
+  color:#000;
+  font-weight: bold;
+}
+
+.pta_tla_l_i_left>div>span:nth-child(2){
+  font-size:14px;
+  color:#717c8d;
+}
+
+.pta_tla_l_i_right{
+  width:auto;
+  height:auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.pta_tla_l_i_right>div{
+  width: auto;
+  height:35px;
+  border-radius: 5px;
+  box-sizing: border-box;
+  border:solid 1px #E2E8F0;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin-left:10px;
+  cursor:pointer;
+  transition:.2s;
+  padding: 0 20px;
+  color:#4A5568;
+  font-size:14px;
+  background: #fff;
+  white-space:nowrap;
+  transition: .2s;
+}
+
+.pta_tla_l_i_right>div:hover{
+  background:#dadada;
+}
+
+.pta_tla_l_i_right>div>svg{
+  width:15px;
+  height:15px;
+  margin-right:5px;
+}
+
+.pta_tla_l_i_right>.edit{
+  color: #fff;
+  background:#0458D2;
+  border-color:#0458D2;
+}
+
+.pta_tla_l_i_right>.edit:hover{
+  background:#0349b3;
+  border-color:#0349b3;
+}
+
+</style>

+ 360 - 0
src/components/pages/pptEasy/commpont/englishRight.vue

@@ -0,0 +1,360 @@
+<template>
+  <div class="englishBox">
+    <div class="themeTitle">
+      <div>作文题目<span style="color: red">*</span></div>
+      <div>
+        <el-input
+          v-model="engList.engTitle"
+          placeholder="请填写作文题目"
+        ></el-input>
+      </div>
+    </div>
+    <div class="themeText">
+      <div>作文要求<span style="color: red">*</span></div>
+      <div>
+        <editor-bar
+          placeholder="请填写作文要求"
+          v-model="engList.englishText"
+        ></editor-bar>
+      </div>
+    </div>
+    <div class="themeEva" style="align-items: flex-start">
+      <div>评价设置</div>
+      <div>
+        <div
+          style="
+            display: flex;
+            flex-direction: row;
+            flex-wrap: nowrap;
+            align-items: center;
+          "
+        >
+          <el-select
+            v-model="engEvaId"
+            placeholder="预设"
+            @change="setTestJson"
+          >
+            <el-option
+              v-for="(e, eIndex) in englistEva"
+              :key="eIndex"
+              :label="e.title"
+              :value="e.id"
+            >
+            </el-option>
+          </el-select>
+          <el-tooltip
+            effect="light"
+            content="点击将下列内容设置成评价模板"
+            placement="top"
+            v-if="engList.textJson.startJson.length > 0"
+          >
+            <div
+              class="addeEva"
+              @click="setEvaTitle"
+            >
+              <img src="../../../../assets/icon/addEva.png" alt="" />
+            </div>
+          </el-tooltip>
+        </div>
+        <div class="addEva">
+          <el-rate
+            v-model="engList.textJson.score"
+            disabled
+            class="engRate"
+          ></el-rate>
+          <div v-if="engList.textJson.startJson.length > 0">
+            <div
+              class="firstJson"
+              v-for="(item, index) in engList.textJson.startJson"
+              :key="index"
+            >
+              <div class="delteBox">
+                <el-input v-model="item.title"></el-input>
+                <img
+                  v-if="engList.textJson.startJson.length > 0"
+                  @click="delteItem(index)"
+                  src="../../../../assets/icon/deleteN.png"
+                  alt=""
+                />
+              </div>
+              <el-input v-model="item.detile"></el-input>
+            </div>
+          </div>
+          <div class="addeEvaItem" @click="addStartItem">
+            <img src="../../../../assets/icon/addEva.png" alt="" />
+          </div>
+        </div>
+      </div>
+    </div>
+    <el-dialog
+      title="设置名称"
+      :visible.sync="engEvadialogVisible"
+      :append-to-body="true"
+      width="500px"
+      :before-close="handleClose"
+      class="dialog_diy"
+    >
+      <el-input v-model="englishTitle" placeholder="请输入名称"></el-input>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="engEvadialogVisible = false">取 消</el-button>
+        <el-button type="primary" @click="insertEnglishEva">确 定</el-button>
+      </span>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import EditorBar from "../../../../components/tools/wangEnduit";
+export default {
+  components: {
+    EditorBar,
+  },
+  props: ["englishList", "oid"],
+  data() {
+    return {
+      engList: {
+        engTitle: "",
+        englishText: "",
+        textJson: {
+          score: 5,
+          startJson: [],
+        },
+      },
+      englistEva: [],
+      engEvaId: "",
+      englishTitle: "",
+      time: null,
+      engEvadialogVisible: false,
+    };
+  },
+  methods: {
+    handleClose(done) {
+      done();
+    },
+    selectEnglishEva() {
+      this.englistEva = [];
+      let params = {
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectEnglishEva", params)
+        .then((res) => {
+          this.englistEva = res.data[0];
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+    addStartItem() {
+      this.engList.textJson.startJson.push({
+        title: "",
+        detile: "",
+      });
+    },
+    delteItem(i) {
+      this.engList.textJson.startJson.splice(i, 1);
+      this.$forceUpdate();
+    },
+    setEvaTitle() {
+      this.englishTitle = "";
+      this.engEvadialogVisible = true;
+    },
+    insertEnglishEva() {
+      if (this.englishTitle == "") {
+        this.$message.error("请设置名称!");
+        return;
+      } else if (this.engList.textJson.startJson.length == 0) {
+        this.$message.error("请添加至少一条评价!");
+        return;
+      }
+      let params = [
+        {
+          t: this.englishTitle,
+          c: JSON.stringify(this.engList.textJson),
+          oid: this.oid,
+        },
+      ];
+      this.ajax
+        .post(this.$store.state.api + "insertEnglishEva", params)
+        .then((res) => {
+          this.$message.success("添加成功!");
+          this.engEvadialogVisible = false;
+          this.selectEnglishEva();
+          this.$forceUpdate();
+        })
+        .catch((err) => {
+          this.$message.error("网络不佳");
+          console.error(err);
+        });
+    },
+    setTestJson() {
+      if (this.engEvaId != "") {
+        this.selectTextJsonById();
+      }
+    },
+    selectTextJsonById() {
+      let params = {
+        id: this.engEvaId,
+        oid: this.oid,
+      };
+      this.ajax
+        .get(this.$store.state.api + "selectEnglishEvaById", params)
+        .then((res) => {
+          var tJson = JSON.parse(res.data[0][0].content);
+          if (this.engList.textJson.startJson.length == 0) {
+            this.engList.textJson = tJson;
+          } else {
+            this.engList.textJson.score = tJson.score;
+            for (var i = 0; i < tJson.startJson.length; i++) {
+              this.engList.textJson.startJson.push(tJson.startJson[i]);
+            }
+          }
+          this.engEvaId = "";
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+  },
+  watch: {
+    englishList: {
+      handler(newVal) {
+        if (newVal) {
+          if(Object.keys(this.englishList).length > 0){
+            this.engList = this.englishList;
+          }else{
+            this.engList = this.engList;
+          }
+          this.$forceUpdate();
+        }
+      },
+      deep: true,
+    },
+  },
+  created() {
+    this.engList =
+      Object.keys(this.englishList).length > 0
+        ? this.englishList
+        : this.engList;
+    this.selectEnglishEva();
+  },
+};
+</script>
+
+<style scoped>
+.dialog_diy >>> .el-dialog__header {
+  background: #3c3c3c !important;
+  padding: 15px 20px;
+}
+
+.dialog_diy >>> .el-dialog__title {
+  color: #fff;
+}
+
+.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;
+}
+
+.dialog_diy >>> .el-dialog__body,
+.dialog_diy >>> .el-dialog__footer {
+  background: #fafafa;
+}
+.englishBox {
+  width: 50%;
+  margin: 50px auto 0;
+}
+.englishBox > div:not(:first-child) {
+  margin-top: 20px;
+}
+.themeTitle,
+.themeText,
+.themeEva {
+  display: flex;
+  flex-direction: row;
+  flex-wrap: nowrap;
+  align-items: center;
+}
+.themeText {
+  align-items: flex-start;
+}
+.themeText > div:last-child >>> .text {
+  min-height: 400px !important;
+}
+.themeTitle > div:first-child,
+.themeText > div:first-child,
+.themeEva > div:first-child {
+  min-width: 65px;
+  font-weight: bold;
+}
+.themeText > div:first-child {
+  margin-top: 10px;
+}
+.themeTitle > div:last-child,
+.themeText > div:last-child,
+.themeEva > div:last-child {
+  width: calc(100% - 75px);
+  margin-left: 10px;
+}
+.addeEva {
+  width: 200px;
+  height: 40px;
+  border: 1px dashed #dbdbdb;
+  border-radius: 10px;
+  margin-left: 10px;
+  cursor: pointer;
+}
+.addeEvaItem {
+  width: 50px;
+  height: 30px;
+  border: 1px dashed #dbdbdb;
+  margin-top: 5px;
+  border-radius: 10px;
+  float: right;
+  cursor: pointer;
+}
+.addeEva > img,
+.addeEvaItem > img {
+  width: 100%;
+  height: 100%;
+  object-fit: contain;
+}
+.engRate {
+  height: 25px;
+  margin: 5px 0;
+}
+.engRate >>> .el-rate__icon {
+  font-size: 25px;
+}
+.addEva {
+  width: 100%;
+}
+.firstJson {
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: flex-start;
+}
+.firstJson > div {
+  margin-bottom: 5px;
+}
+.delteBox {
+  position: relative;
+  width: 100%;
+}
+.delteBox > img {
+  position: absolute;
+  top: 4px;
+  right: 10px;
+  width: 30px;
+  height: 30px;
+  cursor: pointer;
+}
+</style>

+ 250 - 0
src/components/pages/pptEasy/dialog/InteractiveToolDialog.vue

@@ -0,0 +1,250 @@
+<template>
+	<div>
+		<el-dialog
+			:center="true"
+			:visible.sync="show"
+			:close-on-click-modal="false"
+			:modal="true"
+			width="auto"
+			height="auto"
+			:append-to-body="true"
+			class="dialog"
+		>
+			<div class="box">
+				<div class="b_head">
+					<span>互动工具</span>
+					<svg
+						@click="close()"
+						t="1748587270371"
+						class="icon"
+						viewBox="0 0 1024 1024"
+						version="1.1"
+						xmlns="http://www.w3.org/2000/svg"
+						p-id="5023"
+						width="200"
+						height="200"
+					>
+						<path
+							d="M0 0h1024v1024H0z"
+							fill="#FF0033"
+							fill-opacity="0"
+							p-id="5024"
+						></path>
+						<path
+							d="M240.448 168l2.346667 2.154667 289.92 289.941333 279.253333-279.253333a42.666667 42.666667 0 0 1 62.506667 58.026666l-2.133334 2.346667-279.296 279.210667 279.274667 279.253333a42.666667 42.666667 0 0 1-58.005333 62.528l-2.346667-2.176-279.253333-279.253333-289.92 289.962666a42.666667 42.666667 0 0 1-62.506667-58.005333l2.154667-2.346667 289.941333-289.962666-289.92-289.92a42.666667 42.666667 0 0 1 57.984-62.506667z"
+							fill="#111111"
+							p-id="5025"
+						></path>
+					</svg>
+				</div>
+				<div class="b_main" v-loading="loading">
+          <div class="tool">
+            <div class="whiteBIcon" @click.stop="addTool(45)">
+              <img
+                src="../../../../assets/icon/thirdToolList/choose.png"
+                alt
+              />
+              <div style="margin: 5px 0">选择题</div>
+            </div>
+          </div>
+
+          <div class="tool">
+            <div class="whiteBIcon" @click.stop="addTool(15)">
+              <img
+                src="../../../../assets/icon/thirdToolList/answer.png"
+                alt
+              />
+              <div style="margin: 5px 0">问答</div>
+            </div>
+          </div>
+<!--
+          <div class="tool">
+            <div class="whiteBIcon" @click.stop="addTool(72)">
+              <img
+                src="../../../../assets/icon/firstToolList/appStore.png"
+                alt
+              />
+              <div style="margin: 5px 0">应用中心</div>
+            </div>
+          </div> -->
+				</div>
+				<div class="b_bottom">
+					<el-button size="small" type="primary" @click="close()">确定</el-button>
+				</div>
+			</div>
+		</el-dialog>
+	</div>
+</template>
+
+<script>
+export default {
+	data() {
+		return {
+			loading: false,
+			show: false,
+			data: null,
+			value: "",
+		};
+	},
+	computed: {},
+	methods: {
+		open(data) {
+			this.data = data;
+			this.loading = false;
+			this.show = true;
+		},
+		close() {
+			this.show = false;
+			this.init();
+		},
+		init() {
+			this.data = null;
+			this.loading = false;
+		},
+    addTool(type){
+      this.$emit("addTool",type);
+      this.close();
+    }
+	},
+};
+</script>
+
+<style scoped>
+.dialog >>> .el-dialog {
+	width: 50vw !important;
+	border-radius: 8px;
+	padding: 0;
+	background-color: #fff;
+	overflow: hidden;
+}
+
+.dialog >>> .el-dialog__body {
+	width: 50vw !important;
+	height: auto;
+	flex-shrink: 0;
+	padding: 0;
+	box-sizing: border-box;
+	overflow: auto;
+}
+
+.dialog >>> .el-dialog__header {
+	display: none !important;
+}
+
+.box {
+	width: 100%;
+	height: 50vh;
+	background: #fafafa;
+	border-radius: 15px;
+	box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05),
+		0px 16px 24px 2px rgba(0, 0, 0, 0.04), 0px 8px 10px -5px rgba(0, 0, 0, 0.08);
+}
+
+.b_head {
+	width: 100%;
+	height: 50px;
+	border-radius: 15px 15px 0 0;
+	background: #fff;
+	display: flex;
+	align-items: center;
+	justify-content: space-between;
+	box-sizing: border-box;
+	padding: 0 20px;
+}
+
+.b_head > span {
+	font-size: 18px;
+	font-weight: bold;
+	color: #000;
+}
+
+.b_head > img {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_head > svg {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_main {
+	width: 100%;
+	height: calc(100% - 70px - 50px);
+	background: #fafafa;
+	padding: 20px 20px 0 20px;
+	box-sizing: border-box;
+  overflow: auto;
+  display: flex;
+  flex-wrap: wrap;
+}
+
+.b_bottom {
+	width: 100%;
+	height: 70px;
+	display: flex;
+	align-items: center;
+	justify-content: flex-end;
+	box-sizing: border-box;
+	padding: 0 20px;
+}
+
+.tool,
+.isToolChoose {
+  height: 135px;
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  width: fit-content;
+  margin: 10px 10px 10px 10px;
+  align-items: center;
+  border: 2px solid #dbdbdb00;
+  padding: 10px 20px;
+  border-radius: 5px;
+  cursor: pointer;
+  /* box-shadow: 0 0 2px 0px #dedede; */
+  position: relative;
+  box-sizing: border-box;
+  transition:.2s;
+}
+
+.tool:hover {
+  box-shadow: 0 0 2px 0px #438aff;
+  /* border: 2px solid #a5c7ff; */
+}
+
+.tool + .tool {
+  margin-right: 10px;
+}
+
+
+.whiteBIcon {
+  width: 80px;
+  cursor: pointer;
+  display: flex;
+  flex-direction: column;
+  flex-wrap: nowrap;
+  align-items: center;
+  font-size: 14px;
+}
+
+.whiteBIcon > img,
+.toolIcon > img,
+.arrow > img {
+  width: 100%;
+  height: 100%;
+}
+
+.whiteBIcon > img {
+  box-shadow: 0px 4px 8px 0px rgb(44 133 255 / 14%);
+  border-radius: 15px;
+}
+
+.whiteBIcon > div:nth-child(2) {
+  height: 20px;
+  line-height: 20px;
+}
+
+</style>

+ 45 - 16
src/components/pages/sassPlatform/index.vue

@@ -1,16 +1,15 @@
 <template>
   <div class="sassPlatform">
+    <backPage v-if="gotype" tit="表单管理"></backPage>
+    <!-- v-if="gotype" -->
     <div class="sp_header">
-      <!-- <div class="sp_h_logo">
-
-      </div> -->
       <div class="sp_h_tagArea">
         <span :class="{tagActive:tagIndex==0}" style="margin-left: 10px;" @click="tagIndex = 0">应用中心</span>
         <span :class="{tagActive:tagIndex==1}" style="margin-left: 17.5px;" @click="goTestSmarter()">智能助手</span>
       </div>
     </div>
     <div class="sp_bottom">
-      <div class="sp_b_left">
+      <div class="sp_b_left" v-if="!sassPlatFormTypeId">
         <div class="sp_b_l_form" v-for="(item,index) in navList" :key="item.navIndex">
           <span @click="item.open = !item.open">{{ item.name }}<svg :style="`transform: rotate(${item.open?'180':'0'}deg);`" t="1739262423649" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7079" width="200" height="200"><path d="M52.335 261.072c-31.269 30.397-31.269 79.722 0 110.194l403.212 391.718c31.325 30.382 82.114 30.382 113.377 0l403.197-391.718c31.325-30.466 31.325-79.793 0-110.194-31.28-30.449-82.058-30.449-113.39 0l-346.497 336.64-346.457-336.64c-31.325-30.448-82.105-30.448-113.446 0l0 0z" p-id="7080"></path></svg></span>
           <div v-show="item.open" v-if="item.children.length>0">
@@ -31,11 +30,13 @@
 import tableView from './view/tableView.vue';
 import examine from './view/examine/index'
 import databoard from './view/databoard.vue';
+import backPage from "../liyuan/components/backPage.vue";
 export default {
   components:{
     tableView,
     examine,
-    databoard
+    databoard,
+    backPage
   },
   data(){
     return{
@@ -47,7 +48,18 @@ export default {
       oid: this.$route.query.oid,
       org: this.$route.query.org,
       role:this.$route.query.role,
-      userData:null
+      userData:null,
+      liYuanOrgList:["3823a6a5-1b6e-11f0-a66a-005056924926",
+				"292e34dc-1b6e-11f0-a66a-005056924926",
+				"21d6b367-1b6e-11f0-a66a-005056924926",
+				"1a1a172d-1b6e-11f0-a66a-005056924926",
+				"1197f86b-1b6e-11f0-a66a-005056924926",
+				"f235659b-1b6d-11f0-a66a-005056924926",
+				"d87b62d3-1b6d-11f0-a66a-005056924926",
+				"c25ea59b-1b6d-11f0-a66a-005056924926",
+      ],
+      sassPlatFormTypeId:this.$route.query.sassPlatFormTypeId,
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
     }
   },
   computed:{
@@ -73,11 +85,16 @@ export default {
         let params = {
         oid: "",//this.oid
       };
+      let _url = "selectTestType"
+            if(this.liYuanOrgList.includes(this.org)){
+              _url = "selectTestType_liYuan"
+            }
+
       this.ajax
-        .get(this.$store.state.api + "selectTestType", params)
+        .get(this.$store.state.api + _url, params)
         .then(res => {
           let _data = res.data[0];
-          let _type1 = _data.filter(i => i.pid == "");
+          let _type1 = _data.filter(i => !i.pid);
           _type1.forEach((i,index) => {
             let _typeList = [];
             _typeList = _data.filter(i2 => i2.pid == i.id);
@@ -85,20 +102,25 @@ export default {
             let _children = [{name:"表单管理",type:"formManage",typeId:i.id,navIndex:`${index}-0`}]
             i.open = false;
 
-            if(i.id=='e18d88b3-e828-11ef-b508-005056924926'){
-
-
+            if(i.id=='e18d88b3-e828-11ef-b508-005056924926' || i.id=="4cdce114-8a00-11f0-9c7b-005056924926"){
               if(this.userData && this.userData.type === 1 && this.userData.role == 1){
                 _children.push({name:"年度考核",type:"annualAssessment",navIndex:`${index}-1`})
               }
               _children.push({name:"考核数据可视化",type:"evaluationDataVisualization",navIndex:`${index}-2`})
               i.open = true;
             }
+
+
+
             i.children = _children;
             i.typeList = _typeList;
             i.navIndex = `${index}`
           });
 
+
+
+
+
           this.navList = _type1;
           resolve()
         })
@@ -145,10 +167,17 @@ export default {
   mounted(){
     this.getUser(this.userId).then(()=>{
       this.getNavType().then(_=>{
-      if(this.navList.length>0){
-        let _data = this.navList[0].children[0];
-        this.changeNavIndex(_data.navIndex,_data)
-      }
+
+        if(this.sassPlatFormTypeId){
+          this.navList.forEach(i=>{
+            if(i.id == this.sassPlatFormTypeId){
+              this.changeNavIndex(`${i.navIndex}-0`,i.children[0])
+            }
+          })
+        }else if(this.navList.length>0){
+          let _data = this.navList[0].children[0];
+          this.changeNavIndex(_data.navIndex,_data)
+        }
     });
     })
 
@@ -214,7 +243,7 @@ export default {
 
 .sp_bottom{
   width: 100%;
-  height: calc(100% - 70px);
+  /* height: calc(100% - 70px); */
   display: flex;
 }
 

+ 26 - 13
src/components/pages/studentManage/student.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="pb_content" style="background: unset">
+  <div class="pb_content" style="background: unset;height: 100%;">
     <div class="sm_box">
       <div class="sm_left">
         <div class="nav" @click="
@@ -76,7 +76,7 @@
             </div>
           </div>
         </div>
-        <div class="pb_content_body">
+        <div class="pb_content_body" style="overflow: auto;">
           <div class="student_table">
             <el-table ref="table" :data="tableData" border :height="tableHeight" :fit="true" v-loading="isLoading"
               style="width: 100%" :header-cell-style="{ background: '#f1f1f1', fontSize: '17px' }"
@@ -352,9 +352,11 @@ export default {
     getExcel(res) {
       require.ensure([], () => {
         const { export_json_to_excel } = require("../../../common/Export2Excel");
-        const tHeader = ["学生姓名", "学生账号", "班级"];//"学号", "学生手机号", 
+        // 增加 colWidths 参数以调整列宽,例如调整为 [20, 35, 20]
+        const tHeader = ["学生姓名", "学生账号(建议直接使用学号)", "班级"];
         const data = [];
-        export_json_to_excel(tHeader, data, "上传学生样例");
+        const colWidths = [20, 45, 20]; // 设置每一列的宽度
+        export_json_to_excel(tHeader, data, "上传学生样例", colWidths);
       });
     },
     handleCurrentChange(val) {
@@ -722,18 +724,21 @@ export default {
             obj.name = v["学生姓名"];
             // obj.mail = v["学生账号"] ? v["学生账号"] : a;
             // console.log('v["学生账号"]',v["学生账号"]==true,v["学生账号"]);
-            if (v["学生账号"]) {
-              if(/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(v["学生账号"])){
-                obj.mail = v["学生账号"];
+            // 兼容“学生账号(建议直接使用学号)”和“学生账号”两种表头
+            let accountValue = v["学生账号(建议直接使用学号)"] !== undefined && v["学生账号(建议直接使用学号)"] !== "" 
+              ? v["学生账号(建议直接使用学号)"] 
+              : v["学生账号"];
+            if (accountValue) {
+              if(/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(accountValue)){
+                obj.mail = accountValue;
               }else{
-                if(_this.org != "" && _this.org != "null"  && _this.org != undefined && _this.org && _this.schoolChar){
-                  obj.mail = v["学生账号"] + "@" + _this.schoolChar + '.' + _this.userSuffix
+                if(_this.org != "" && _this.org != "null" && _this.org != undefined && _this.org && _this.schoolChar){
+                  obj.mail = accountValue + "@" + _this.schoolChar + '.' + _this.userSuffix
                 }else {
-                  obj.mail = v["学生账号"] + "@" + _this.userSuffix
+                  obj.mail = accountValue + "@" + _this.userSuffix
                 }
-                // obj.mail = v["学生账号"] + "@" + _this.userSuffix
+                // obj.mail = accountValue + "@" + _this.userSuffix
               }
-              
             }else{
               obj.mail = a;
             }
@@ -1047,7 +1052,9 @@ export default {
                   message: "新增成功",
                   type: "success",
                 });
-                _this.getStudent();
+                setTimeout(() => {
+                  _this.getStudent();
+                }, 5000);
               }
               loading.close();
             })
@@ -1490,17 +1497,23 @@ export default {
 
 .pb_content_body {
   width: 100% !important;
+  /* flex: 1; */
+  /* overflow: auto; */
 }
 
 .sm_box {
   display: flex;
   width: calc(100% - 20px);
   margin: 0 auto;
+  height: 100%;
 }
 
 .sm_right {
   width: calc(100% - 210px);
   margin-left: 210px;
+  height: 100%;
+  display: flex;
+  flex-direction: column;
 }
 
 .sm_left {

+ 39 - 2
src/components/pages/sz/teacher.vue

@@ -125,9 +125,19 @@
           <el-table-column label="操作" width="220px">
             <template slot-scope="scope">
               <div style="display: flex;">
+                <el-button class="de_button" type="primary" size="small" style="
+                      width: auto;
+                      padding: 5px !important;
+                      line-height: 15px;
+                    " @click="iniPassword(scope.row.userid)">初始化密码</el-button>
                 <el-button
-                  size="mini"
+                  class="de_button"
+                  size="small"
                   type="primary"
+                  style="
+                      width: auto;
+                      padding:0 10px !important;
+                      line-height: 15px;"
                   @click="modifyDiaBtn(scope.row)"
                   >修改</el-button
                 >
@@ -311,7 +321,7 @@ export default {
     },
   data() {
     return {
-      gotype: sessionStorage.getItem('gotype'),
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       tableHeight: "500px",
       isLoading: false,
       formLabelWidth: "100px",
@@ -416,6 +426,33 @@ export default {
           console.error("请求失败,错误信息:", err);
         });
     },
+    iniPassword(id) {
+      this.$confirm("确定" + "初始化" + "此教师的密码吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          let params = [
+            {
+              uid: id,
+              pa: 'Coco1234',
+            },
+          ];
+          this.ajax
+            .post(this.$store.state.api + "iniPassword", params)
+            .then((res) => {
+              this.$message({
+                message: "初始化密码成功!",
+                type: "success",
+              });
+            })
+            .catch((err) => {
+              console.error(err);
+            });
+        })
+        .catch(() => { });
+    },
     getEmailWithAt(email) {
       const regex = /@[^@]+$/;  // 匹配最后一个 @ 及其后的内容
       const match = email.match(regex);

+ 122 - 122
src/components/pages/teacherOffice/index.vue

@@ -10,7 +10,7 @@
               ">
       <div class="pb_head top">
         <div style="display: flex;align-items: center;">
-          <span class="sub_head">{{ lang.DepartmentManagement }}</span>
+          <span class="sub_head">教研室管理</span>
           <span class="subClick" @click="
             goTo(
               '/teacherType?userid=' +
@@ -20,19 +20,19 @@
               '&org=' +
               org
             )
-            ">{{ lang.DepartmentTypeManagement }}</span>
+            ">教研室类型管理</span>
         </div>
         <div class="student_button" style="border-radius: 4px;">
-          <el-button type="primary" class="bgColor" @click="openAddTeacher">{{ lang.AddDepartment }}</el-button>
+          <el-button type="primary" class="bgColor" @click="openAddTeacher">添加教研室</el-button>
         </div>
       </div>
       <div class="student_head">
         <div class="student_search">
           <span>
-            <el-input :placeholder="lang.Enterdepartmentname" v-model="sClassName" clearable>
+            <el-input placeholder="请输入教研室名称" v-model="sClassName" clearable>
             </el-input>
           </span>
-          <el-button type="primary" @click="searchClass">{{ lang.Search }}</el-button>
+          <el-button type="primary" @click="searchClass">查询</el-button>
         </div>
       </div>
     </div>
@@ -41,22 +41,22 @@
         <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="lang.DepartmentName" align="center">
+          <el-table-column prop="name" label="教研室名称" align="center">
           </el-table-column>
-          <el-table-column prop="typeName" :label="lang.DepartmentType" align="center">
+          <el-table-column prop="typeName" label="教研室类型" align="center">
             <template slot-scope="scope">
-              <span v-if="scope.row.parentid == 6">{{ lang.Department }}</span>
+              <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="lang.Action" width="400px">
+          <el-table-column label="操作" width="400px">
             <template slot-scope="scope">
-              <el-button type="primary" size="small" @click="getStudent(scope.row.id)">{{ lang.ViewTeacher }}</el-button>
+              <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)">{{ lang.Edit }}</el-button>
-              <el-button type="primary" size="small" @click="deleteClass(scope.row.id)">{{ lang.Delete }}</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>
@@ -74,23 +74,23 @@
                 border-radius: 5px;
               ">
       <div class="pb_head top">
-        <span>{{ lang.ViewTeacher }}-{{ getGrade(cid) }}</span>
+        <span>查看老师-{{ getGrade(cid) }}</span>
         <div class="student_button" style="border-radius: 4px;">
-          <el-button type="primary" class="bgColor" @click="ctype = 1, getClass()">{{ lang.return }}</el-button>
+          <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="lang.Enterusername" style="margin:0 10px"></el-input>
+          <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">{{ lang.Search }}</el-button>
+          <el-button class="student_button" @click="searchStudent">查询</el-button>
         </div>
         <div class="head_right">
-          <el-button @click="addStudent">{{ lang.AddTeacher }}</el-button>
+          <el-button @click="addStudent">添加老师</el-button>
         </div>
       </div>
     </div>
@@ -99,7 +99,7 @@
         <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="lang.Name" min-width="10" align="center">
+          <el-table-column label="姓名" min-width="10" align="center">
             <template slot-scope="scope">
               <div class="userImg">
                 <div class="tx">
@@ -120,21 +120,21 @@
               </div>
             </template>
           </el-table-column>
-          <el-table-column :fixed="lang.TeacherAccount" min-width="15" align="center">
+          <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="lang.Department" min-width="15" align="center">
+          <el-table-column prop="classname2" label="教研室" min-width="15" align="center">
           </el-table-column>
-          <el-table-column :label="lang.Action" width="250px">
+          <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">{{ lang.InitialPassword }}</el-button>
+                  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)">{{ lang.Remove }}</el-button>
+                  @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> -->
@@ -154,43 +154,43 @@
         <div class="logoImg">
           <img src="../../../assets/logo.png" alt />
         </div>
-        <div class="title_add_student">{{ lang.AddTeachers }}</div>
+        <div class="title_add_student">添加老师</div>
       </div>
       <el-form>
-        <el-form-item :label="lang.Teachername" :label-width="formLabelWidth">
+        <el-form-item label="老师姓名" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.enterteachername" clearable v-model="sName" class="add_input"></el-input>
+            <el-input placeholder="请输入老师姓名" clearable v-model="sName" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.TeacherNumber" :label-width="formLabelWidth">
+        <el-form-item label="老师学号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.enterteacherID" clearable v-model="sId" class="add_input"></el-input>
+            <el-input placeholder="请输入老师学号" clearable v-model="sId" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.Teacherphonenumber" :label-width="formLabelWidth">
+        <el-form-item label="老师手机号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.EnterTeacherPhoneNumber" clearable v-model="sPhone" class="add_input"></el-input>
+            <el-input placeholder="请输入老师手机号" clearable v-model="sPhone" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.Teacheraccount" :label-width="formLabelWidth">
+        <el-form-item label="老师账号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.Teacheraccount" clearable v-model="sMail" class="add_input"></el-input>
+            <el-input placeholder="请输入老师账号" clearable v-model="sMail" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.AffiliatedSchool" :label-width="formLabelWidth">
+        <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="lang.Department" :label-width="formLabelWidth">
-          <el-select v-model="cid" :placeholder="lang.selectdepartment" disabled>
+        <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">
-          {{ lang.teacherpassword }}
+          注:添加老师的账号密码为Coco1234
         </div>
       </el-form>
       <span slot="footer" class="dialog-footer flex">
-        <el-button class="right" @click="insertStudent">{{ lang.confirm }}</el-button>
+        <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"
@@ -199,120 +199,120 @@
         <div class="logoImg">
           <img src="../../../assets/logo.png" alt />
         </div>
-        <div class="title_add_student">{{ lang.Modifyteacher }}</div>
+        <div class="title_add_student">修改老师</div>
       </div>
       <el-form>
-        <el-form-item :label="lang.Teachername" :label-width="formLabelWidth">
+        <el-form-item label="老师名称" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.enterteachername" clearable v-model="userinfo.name" class="add_input"></el-input>
+            <el-input placeholder="请输入老师姓名" clearable v-model="userinfo.name" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.TeacherNumber" :label-width="formLabelWidth">
+        <el-form-item label="老师学号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.enterteacherID" clearable v-model="userinfo.studentid" class="add_input"></el-input>
+            <el-input placeholder="请输入老师学号" clearable v-model="userinfo.studentid" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.Teacherphonenumber" :label-width="formLabelWidth">
+        <el-form-item label="老师手机号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.EnterTeacherPhoneNumber" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
+            <el-input placeholder="请输入老师手机号" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.Teacheraccount" :label-width="formLabelWidth">
+        <el-form-item label="老师账号" :label-width="formLabelWidth">
           <span>
-            <el-input :placeholder="lang.enterteacheraccount" clearable v-model="userinfo.un" class="add_input"></el-input>
+            <el-input placeholder="请输入老师账号" clearable v-model="userinfo.un" class="add_input"></el-input>
           </span>
         </el-form-item>
-        <el-form-item :label="lang.AffiliatedSchool" :label-width="formLabelWidth">
+        <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="lang.Department" :label-width="formLabelWidth">
-          <el-select multiple collapse-tags v-model="userinfo.classid" :placeholder="lang.selectdepartment">
+        <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">
-         {{ lang.teacherpassword }}
+          注:添加老师的账号密码为Coco1234
         </div>
       </el-form>
       <span slot="footer" class="dialog-footer flex">
-        <el-button class="right" @click="updateStudent">{{ lang.Edit }}</el-button>
+        <el-button class="right" @click="updateStudent">修改</el-button>
       </span>
     </el-dialog>
-    <el-dialog :title="lang.AddDepartment" :visible.sync="dialogVisible" :append-to-body="true" width="25%"
+    <el-dialog title="添加教研室" :visible.sync="dialogVisible" :append-to-body="true" width="25%"
       :before-close="handleClose" class="dialog_diy">
       <el-form>
-        <el-form-item :label="lang.DepartmentName" :label-width="formLabelWidth">
-          <el-input v-model="className" auto-complete="off" :placeholder="lang.enterdepartment"></el-input>
+        <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="lang.DepartmentType" :label-width="formLabelWidth">
-          <el-select v-model="typeId" :placeholder="lang.type">
+        <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">{{ lang.Cancel }}</el-button>
-        <el-button type="primary" @click="insertClass">{{ lang.Confirm }}</el-button>
+        <el-button @click="handleCancel">取 消</el-button>
+        <el-button type="primary" @click="insertClass">确 定</el-button>
       </span>
     </el-dialog>
-    <el-dialog :title="lang.EditGrade" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
+    <el-dialog title="修改年级" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
       :before-close="handleClose" class="dialog_diy">
       <el-form>
-        <el-form-item :label="lang.SelectGrade" :label-width="formLabelWidth">
-          <el-select v-model="gid" :placeholder="lang.selectdepartment" class="student_input" style="margin:0 10px" clearable>
+        <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">{{ lang.Cancel }}</el-button>
-        <el-button type="primary" @click="updateGrade">{{ lang.Confirm }}</el-button>
+        <el-button @click="dialogVisibleGrade = false">取 消</el-button>
+        <el-button type="primary" @click="updateGrade">确 定</el-button>
       </span>
     </el-dialog>
-    <el-dialog :title="lang.EditDepartment" :visible.sync="dialogVisible1" :append-to-body="true" width="25%"
+    <el-dialog title="修改教研室" :visible.sync="dialogVisible1" :append-to-body="true" width="25%"
       :before-close="handleClose" class="dialog_diy">
       <el-form>
-        <el-form-item :label="lang.DepartmentName" :label-width="formLabelWidth">
-          <el-input v-model="className1" auto-complete="off" :placeholder="lang.enterdepartment"></el-input>
+        <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="lang.DepartmentType" :label-width="formLabelWidth">
-          <el-select v-model="typeId2" :placeholder="lang.type">
+        <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">{{ lang.Cancel }}</el-button>
-        <el-button type="primary" @click="updateClass">{{ lang.Confirm }}</el-button>
+        <el-button @click="dialogVisible1 = false">取 消</el-button>
+        <el-button type="primary" @click="updateClass">确 定</el-button>
       </span>
     </el-dialog>
-    <el-dialog :title="lang.AddTeacher" :visible.sync="dialogVisibleMember" :append-to-body="true" width="500px" height="80%"
+    <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="lang.Searchteachername" v-model="searchTN" @keyup.enter.native="getClassStudent"></el-input>
+              <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">{{ lang.SelectMembers }}</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>{{ lang.Name }}</span>
-          <span>{{ lang.Account }}</span>
+          <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 : lang.Noname">
-                <span>{{ item.name ? item.name : lang.Noname }}</span>
+              <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>
@@ -320,7 +320,7 @@
             </div>
           </el-checkbox>
         </el-checkbox-group>
-        <div style="text-align: center; margin-top: 10px" v-else>{{ lang.Noname }}</div>
+        <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"
@@ -328,8 +328,8 @@
           @current-change="handleCurrentChange3"></el-pagination>
       </div>
       <span slot="footer" class="dialog-footer">
-        <el-button @click="dialogVisibleMember = false">{{ lang.Cancel }}</el-button>
-        <el-button type="primary" @click="addClassStudent">{{ lang.Confirm }}</el-button>
+        <el-button @click="dialogVisibleMember = false">取 消</el-button>
+        <el-button type="primary" @click="addClassStudent">确定</el-button>
       </span>
     </el-dialog>
   </div>
@@ -344,7 +344,7 @@ export default {
 
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       tableHeight: "500px",
       isLoading: false,
       formLabelWidth: "100px",
@@ -416,7 +416,7 @@ export default {
             name = element.name
           }
         });
-        return name ? name : this.lang.None
+        return name ? name : '暂无'
       }
     }
   },
@@ -471,7 +471,7 @@ export default {
           this.options.push(
             {
               id: '6',
-              name: this.lang.Department
+              name:'教研室'
             }
           )
         })
@@ -522,9 +522,9 @@ export default {
       this.dialogVisibleGrade = true;
     },
     updateGrade() {
-      this.$confirm(this.lang.makechanges, this.lang.tip, {
-        confirmButtonText: this.lang.Confirm,
-        cancelButtonText: this.lang.Cancel,
+      this.$confirm("确定修改吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
         type: "warning",
       })
         .then(() => {
@@ -558,7 +558,7 @@ export default {
       // 检查是否选择了教研室类型
       if (this.typeId == "") {
         this.$message({
-          message: this.lang.selectthetypeofteaching,
+          message: "请选择教研室类型",
           type: "warning",
         });
         return; // 停止继续执行
@@ -574,12 +574,12 @@ export default {
         .then((res) => {
           if (res.data[0] && res.data[0][0].classname == 1) {
             this.$message({
-              message: this.lang.nameasother,
+              message: "不能与其他教研室名称相同!",
               type: "error",
             });
           } else {
             this.$message({
-              message: this.lang.AddSuccessful,
+              message: "新增成功",
               type: "success",
             });
             this.dialogVisible = false;
@@ -590,7 +590,7 @@ export default {
         })
         .catch((err) => {
           this.$message({
-            message: this.lang.Additionfailed,
+            message: "新增失败",
             type: "error",
           });
           console.error(err);
@@ -614,12 +614,12 @@ export default {
         .then((res) => {
           if (res.data[0] && res.data[0][0].classname == 1) {
             this.$message({
-              message: this.lang.nameasother,
+              message: "不能与其他教研室名称相同!",
               type: "error",
             });
           } else {
             this.$message({
-              message: this.lang.Editsuccessful,
+              message: "修改成功",
               type: "success",
             });
             this.dialogVisible1 = false;
@@ -630,7 +630,7 @@ export default {
         })
         .catch((err) => {
           this.$message({
-            message: this.lang.Modificationfailed,
+            message: "修改失败",
             type: "error",
           });
           console.error(err);
@@ -667,9 +667,9 @@ export default {
         id: id,
       };
       if (this.time()) {
-        this.$confirm(this.lang.Aystdtd, this.lang.tip, {
-          confirmButtonText: this.lang.Confirm,
-          cancelButtonText: this.lang.Cancel,
+        this.$confirm("确定删除此教研室吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
           type: "warning",
         })
           .then(() => {
@@ -677,7 +677,7 @@ export default {
               .get(this.$store.state.api + "deleteClass", params)
               .then((res) => {
                 this.$message({
-                  message: this.lang.DeleteSuccessful,
+                  message: "删除成功",
                   type: "success",
                 });
                 if (this.page != 1 && this.tableData.length == 1) {
@@ -686,7 +686,7 @@ export default {
                 this.getClass();
               })
               .catch((err) => {
-                this.$message.error(this.lang.Deletefailed);
+                this.$message.error("删除失败");
                 console.error(err);
               });
           })
@@ -704,18 +704,18 @@ export default {
     //新增老师
     insertStudent() {
       if (this.sName === "") {
-        this.$message.error(this.lang.Teachercannotempty);
+        this.$message.error("老师姓名不能为空");
         return;
       } else if (
         this.sPhone != "" &&
         !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.sPhone)
       ) {
-        this.$message.error(this.lang.phonenumberincorrect);
+        this.$message.error("手机号格式不正确");
         return;
       } else if (
         !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
       ) {
-        this.$message.error(this.lang.Emailformatincorrect);
+        this.$message.error("邮箱格式不正确");
         return;
       }
 
@@ -725,7 +725,7 @@ export default {
           .get(this.$store.state.api + "findMail", params)
           .then((res) => {
             if (res.data[0].length > 0) {
-              this.$message.error(this.lang.alreadybeenregistered);
+              this.$message.error("此老师账号已被注册");
             } else {
               this.add_Student();
             }
@@ -773,7 +773,7 @@ export default {
               console.error(err);
             });
           this.$message({
-            message: this.lang.AddSuccessful,
+            message: "新增成功",
             type: "success",
           });
           this.dialogVisibleAddStudent = false;
@@ -786,7 +786,7 @@ export default {
         .catch((err) => {
           this.isLoading = false;
           this.$message({
-            message: this.lang.Additionfailed,
+            message: "新增失败",
             type: "error",
           });
           console.error(err);
@@ -800,23 +800,23 @@ export default {
     },
     updateStudent() {
       if (this.userinfo.name === "") {
-        this.$message.error(this.lang.Teachercannotempty);
+        this.$message.error("老师姓名不能为空");
         return;
       } else if (!this.userinfo.classid) {
-        this.$message.error(this.lang.chooseateaching);
+        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(this.lang.phonenumberincorrect);
+        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(this.lang.Emailformatincorrect);
+        this.$message.error("邮箱格式不正确");
         return;
       }
 
@@ -827,7 +827,7 @@ export default {
             .get(this.$store.state.api + "findMail", params)
             .then((res) => {
               if (res.data[0].length > 0) {
-                this.$message.error(this.lang.alreadybeenregistered);
+                this.$message.error("此老师账号已被注册");
               } else {
                 this.update_Student();
               }
@@ -855,7 +855,7 @@ export default {
         .post(this.$store.state.api + "updateStudentInfo", params)
         .then((res) => {
           this.$message({
-            message: this.lang.Editsuccessful,
+            message: "修改成功",
             type: "success",
           });
           this.dialogVisibleUpdate = false;
@@ -864,7 +864,7 @@ export default {
         .catch((err) => {
           this.isLoading = false;
           this.$message({
-            message: this.lang.Modificationfailed,
+            message: "修改失败",
             type: "error",
           });
           console.error(err);
@@ -872,9 +872,9 @@ export default {
     },
     deleteClassStudent(id) {
       let params = [{ uid: id, cid: this.cid }];
-      this.$confirm(this.lang.Aystrttfta, this.lang.tip, {
-        confirmButtonText: this.lang.Confirm,
-        cancelButtonText: this.lang.Cancel,
+      this.$confirm("确定在本教研室移除此老师吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
         type: "warning",
       })
         .then(() => {
@@ -882,13 +882,13 @@ export default {
             .post(this.$store.state.api + "deleteClassTeacher", params)
             .then((res) => {
               this.$message({
-                message: this.lang.OperateSuccessful,
+                message: "操作成功",
                 type: "success",
               });
               this.getStudent(this.cid);
             })
             .catch((err) => {
-              this.$message.error(this.lang.operationfailed);
+              this.$message.error("操作失败");
               console.error(err);
             });
         })
@@ -980,7 +980,7 @@ export default {
     },
     addClassStudent() {
       if (!this.checkboxList3.length) {
-        this.$message.error(this.lang.selecttheteacher);
+        this.$message.error('请选择要添加教研室的老师');
         return;
       }
       let params = [{
@@ -990,7 +990,7 @@ export default {
       this.ajax
         .post(this.$store.state.api + "addClassTeacher", params)
         .then((res) => {
-          this.$message.success(this.lang.Addedsuccessfully)
+          this.$message.success("添加成功")
           this.checkboxList3 = []
           this.dialogVisibleMember = false
           this.getStudent(this.cid)
@@ -1000,9 +1000,9 @@ export default {
         });
     },
     iniPassword(id) {
-      this.$confirm(this.lang.initializepasswordteacher, this.lang.tip, {
-        confirmButtonText: this.lang.Confirm,
-        cancelButtonText: this.lang.Cancel,
+      this.$confirm("确定" + "初始化" + "此老师的密码吗?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
         type: "warning",
       })
         .then(() => {
@@ -1016,7 +1016,7 @@ export default {
             .post(this.$store.state.api + "iniPassword", params)
             .then((res) => {
               this.$message({
-                message: this.lang.Resetsuccessful,
+                message: "初始化密码成功!",
                 type: "success",
               });
             })

+ 112 - 112
src/components/pages/teacherOffice/teacherType.vue

@@ -17,20 +17,20 @@
                 '&org=' +
                 org
               )
-              ">{{ lang.DepartmentManagement }}</span>
-            <span class="sub_head">{{ lang.DepartmentTypeManagement }}</span>
+              ">教研室管理</span>
+            <span class="sub_head">教研室类型管理</span>
           </div>
           <div class="student_button" style="border-radius: 4px;">
-            <el-button type="primary" class="bgColor" @click="dialogVisible = true">{{ lang.Adddepartmenttype }}</el-button>
+            <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="lang.Enterdepartmenttype" v-model="sClassName" clearable>
+              <el-input placeholder="请输入教研室类型" v-model="sClassName" clearable>
               </el-input>
             </span>
-            <el-button type="primary" @click="searchClass">{{ lang.Search }}</el-button>
+            <el-button type="primary" @click="searchClass">查询</el-button>
           </div>
         </div>
       </div>
@@ -39,16 +39,16 @@
           <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="lang.DepartmentType" align="center">
+            <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="lang.Action" width="400px">
+            <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)">{{ lang.Edit }}</el-button>
-                <el-button type="primary" size="small" @click="deleteClass(scope.row.id)">{{ lang.Delete }}</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>
@@ -66,23 +66,23 @@
                 border-radius: 5px;
               ">
         <div class="pb_head top">
-          <span>{{ lang.ViewTeacher }}-{{ getGrade(cid) }}</span>
+          <span>查看老师-{{ getGrade(cid) }}</span>
           <div class="student_button" style="border-radius: 4px;">
-            <el-button type="primary" class="bgColor" @click="ctype = 1, getClass()">{{ lang.return }}</el-button>
+            <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="lang.Pleaseenteryourusername" style="margin:0 10px"></el-input>
+            <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">{{ lang.Search }}</el-button>
+            <el-button class="student_button" @click="searchStudent">查询</el-button>
           </div>
           <div class="head_right">
-            <el-button @click="addStudent">{{ lang.AddTeacher }}</el-button>
+            <el-button @click="addStudent">添加老师</el-button>
           </div>
         </div>
       </div>
@@ -91,7 +91,7 @@
           <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="lang.Name" min-width="10" align="center">
+            <el-table-column label="姓名" min-width="10" align="center">
               <template slot-scope="scope">
                 <div class="userImg">
                   <div class="tx">
@@ -112,21 +112,21 @@
                 </div>
               </template>
             </el-table-column>
-            <el-table-column :label="lang.TeacherAccount" min-width="15" align="center">
+            <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="lang.Department" min-width="15" align="center">
+            <el-table-column prop="classname2" label="教研室" min-width="15" align="center">
             </el-table-column>
-            <el-table-column :label="lang.Action" width="250px">
+            <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">{{ lang.InitialPassword }}</el-button>
+                    @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)">{{ lang.Remove }}</el-button>
+                    @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> -->
@@ -146,43 +146,43 @@
           <div class="logoImg">
             <img src="../../../assets/logo.png" alt />
           </div>
-          <div class="title_add_student">{{ lang.AddTeacher }}</div>
+          <div class="title_add_student">添加老师</div>
         </div>
         <el-form>
-          <el-form-item :label="lang.Teachername" :label-width="formLabelWidth">
+          <el-form-item label="老师姓名" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteachername" clearable v-model="sName" class="add_input"></el-input>
+              <el-input placeholder="请输入老师姓名" clearable v-model="sName" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.TeacherNumber" :label-width="formLabelWidth">
+          <el-form-item label="老师学号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteacherID" clearable v-model="sId" class="add_input"></el-input>
+              <el-input placeholder="请输入老师学号" clearable v-model="sId" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.Teacherphonenumber" :label-width="formLabelWidth">
+          <el-form-item label="老师手机号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.EnterTeacherPhoneNumber" clearable v-model="sPhone" class="add_input"></el-input>
+              <el-input placeholder="请输入老师手机号" clearable v-model="sPhone" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.Teacheraccount" :label-width="formLabelWidth">
+          <el-form-item label="老师账号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteacheraccount" clearable v-model="sMail" class="add_input"></el-input>
+              <el-input placeholder="请输入老师账号" clearable v-model="sMail" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.AffiliatedSchool" :label-width="formLabelWidth">
+          <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="lang.Department" :label-width="formLabelWidth">
-            <el-select v-model="cid" :placeholder="lang.selectdepartment" disabled>
+          <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">
-            {{ lang.teacherpassword }}
+            注:添加老师的账号密码为Coco1234
           </div>
         </el-form>
         <span slot="footer" class="dialog-footer flex">
-          <el-button class="right" @click="insertStudent">{{ lang.confirm }}</el-button>
+          <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"
@@ -191,111 +191,111 @@
           <div class="logoImg">
             <img src="../../../assets/logo.png" alt />
           </div>
-          <div class="title_add_student">{{ lang.Modifyteacher }}</div>
+          <div class="title_add_student">修改老师</div>
         </div>
         <el-form>
-          <el-form-item :label="lang.Modifyteacher" :label-width="formLabelWidth">
+          <el-form-item label="老师名称" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteachername" clearable v-model="userinfo.name" class="add_input"></el-input>
+              <el-input placeholder="请输入老师姓名" clearable v-model="userinfo.name" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.TeacherNumber" :label-width="formLabelWidth">
+          <el-form-item label="老师学号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteacherID" clearable v-model="userinfo.studentid" class="add_input"></el-input>
+              <el-input placeholder="请输入老师学号" clearable v-model="userinfo.studentid" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.Teacherphonenumber" :label-width="formLabelWidth">
+          <el-form-item label="老师手机号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.EnterTeacherPhoneNumber" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
+              <el-input placeholder="请输入老师手机号" clearable v-model="userinfo.phonenumber" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.Teacheraccount" :label-width="formLabelWidth">
+          <el-form-item label="老师账号" :label-width="formLabelWidth">
             <span>
-              <el-input :placeholder="lang.enterteacheraccount" clearable v-model="userinfo.un" class="add_input"></el-input>
+              <el-input placeholder="请输入老师账号" clearable v-model="userinfo.un" class="add_input"></el-input>
             </span>
           </el-form-item>
-          <el-form-item :label="lang.AffiliatedSchool" :label-width="formLabelWidth">
+          <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="lang.Department" :label-width="formLabelWidth">
-            <el-select multiple collapse-tags v-model="userinfo.classid" :placeholder="lang.selectdepartment">
+          <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">
-            {{ lang.teacherpassword }}
+            注:添加老师的账号密码为Coco1234
           </div>
         </el-form>
         <span slot="footer" class="dialog-footer flex">
-          <el-button class="right" @click="updateStudent">{{ lang.Edit }}</el-button>
+          <el-button class="right" @click="updateStudent">修改</el-button>
         </span>
       </el-dialog>
-      <el-dialog :title="lang.Adddepartmenttype" :visible.sync="dialogVisible" :append-to-body="true" width="25%" :before-close="handleClose"
+      <el-dialog title="添加教研室类型" :visible.sync="dialogVisible" :append-to-body="true" width="25%" :before-close="handleClose"
         class="dialog_diy">
         <el-form>
-          <el-form-item :label="lang.DepartmentType" :label-width="formLabelWidth">
-            <el-input v-model="className" auto-complete="off" :placeholder="lang.Enterdepartmenttype+'...'"></el-input>
+          <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">{{ lang.Cancel }}</el-button>
-          <el-button type="primary" @click="insertClass">{{ lang.Confirm }}</el-button>
+          <el-button @click="dialogVisible = false">取 消</el-button>
+          <el-button type="primary" @click="insertClass">确 定</el-button>
         </span>
       </el-dialog>
-      <el-dialog :title="lang.EditGrade" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
+      <el-dialog title="修改年级" :visible.sync="dialogVisibleGrade" :append-to-body="true" width="25%"
         :before-close="handleClose" class="dialog_diy">
         <el-form>
-          <el-form-item :label="lang.SelectGrade" :label-width="formLabelWidth">
-            <el-select v-model="gid" :placeholder="lang.selectdepartment" class="student_input" style="margin:0 10px" clearable>
+          <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">{{ lang.Cancel }}</el-button>
-          <el-button type="primary" @click="updateGrade">{{ lang.Confirm }}</el-button>
+          <el-button @click="dialogVisibleGrade = false">取 消</el-button>
+          <el-button type="primary" @click="updateGrade">确 定</el-button>
         </span>
       </el-dialog>
-      <el-dialog :title="lang.EditDepartment" :visible.sync="dialogVisible1" :append-to-body="true" width="25%" :before-close="handleClose"
+      <el-dialog title="修改教研室" :visible.sync="dialogVisible1" :append-to-body="true" width="25%" :before-close="handleClose"
         class="dialog_diy">
         <el-form>
-          <el-form-item :label="lang.DepartmentName" :label-width="formLabelWidth">
-            <el-input v-model="className1" auto-complete="off" :placeholder="lang.enterdepartment"></el-input>
+          <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">{{ lang.Cancel }}</el-button>
-          <el-button type="primary" @click="updateClass">{{ lang.Confirm }}</el-button>
+          <el-button @click="dialogVisible1 = false">取 消</el-button>
+          <el-button type="primary" @click="updateClass">确 定</el-button>
         </span>
       </el-dialog>
-      <el-dialog :title="lang.AddTeacher" :visible.sync="dialogVisibleMember" :append-to-body="true" width="500px" height="80%"
+      <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="lang.Searchteachername" v-model="searchTN" @keyup.enter.native="getClassStudent"></el-input>
+                <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">{{ lang.SelectMembers }}</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>{{ lang.Name }}</span>
-            <span>{{ lang.Account }}</span>
+            <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 : lang.Noname">
-                  <span>{{ item.name ? item.name : lang.Noname }}</span>
+                <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>
@@ -303,7 +303,7 @@
               </div>
             </el-checkbox>
           </el-checkbox-group>
-          <div style="text-align: center; margin-top: 10px" v-else>{{lang.Nodata}}</div>
+          <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"
@@ -311,8 +311,8 @@
             @current-change="handleCurrentChange3"></el-pagination>
         </div>
         <span slot="footer" class="dialog-footer">
-          <el-button @click="dialogVisibleMember = false">{{ lang.Cancel }}</el-button>
-          <el-button type="primary" @click="addClassStudent">{{ lang.Confirm }}</el-button>
+          <el-button @click="dialogVisibleMember = false">取 消</el-button>
+          <el-button type="primary" @click="addClassStudent">确定</el-button>
         </span>
       </el-dialog>
     </div>
@@ -385,7 +385,7 @@
               name = element.name
             }
           });
-          return name ? name : this.lang.None
+          return name ? name : '暂无'
         }
       }
     },
@@ -463,9 +463,9 @@
         this.dialogVisibleGrade = true;
       },
       updateGrade() {
-        this.$confirm(this.lang.makechanges, this.lang.tip, {
-          confirmButtonText: this.lang.Confirm,
-          cancelButtonText: this.lang.Cancel,
+        this.$confirm("确定修改吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
           type: "warning",
         })
           .then(() => {
@@ -505,12 +505,12 @@
           .then((res) => {
             if (res.data[0] && res.data[0][0].classname == 1) {
               this.$message({
-                message: this.lang.othertypesofteaching,
+                message: "不能与其他教研室类型名称相同!",
                 type: "error",
               });
             } else {
               this.$message({
-                message:  this.lang.AddSuccessful,
+                message: "新增成功",
                 type: "success",
               });
               this.dialogVisible = false;
@@ -521,7 +521,7 @@
           })
           .catch((err) => {
             this.$message({
-              message: this.lang.Additionfailed,
+              message: "新增失败",
               type: "error",
             });
             console.error(err);
@@ -539,12 +539,12 @@
           .then((res) => {
             if (res.data[0] && res.data[0][0].classname == 1) {
               this.$message({
-                message: this.lang.nameasother,
+                message: "不能与其他教研室名称相同!",
                 type: "error",
               });
             } else {
               this.$message({
-                message: this.lang.Editsuccessful,
+                message: "修改成功",
                 type: "success",
               });
               this.dialogVisible1 = false;
@@ -555,7 +555,7 @@
           })
           .catch((err) => {
             this.$message({
-              message: this.lang.Modificationfailed,
+              message: "修改失败",
               type: "error",
             });
             console.error(err);
@@ -609,9 +609,9 @@
           id: id,
         };
         if (this.time()) {
-          this.$confirm(this.lang.Aystdtd, this.lang.tip, {
-            confirmButtonText: this.lang.Confirm,
-            cancelButtonText: this.lang.Cancel,
+          this.$confirm("确定删除此教研室吗?", "提示", {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
             type: "warning",
           })
             .then(() => {
@@ -619,7 +619,7 @@
                 .get(this.$store.state.api + "deleteClass", params)
                 .then((res) => {
                   this.$message({
-                    message: this.lang.DeleteSuccessful,
+                    message: "删除成功",
                     type: "success",
                   });
                   if (this.page != 1 && this.tableData.length == 1) {
@@ -628,7 +628,7 @@
                   this.getClass();
                 })
                 .catch((err) => {
-                  this.$message.error(this.lang.Deletefailed);
+                  this.$message.error("删除失败");
                   console.error(err);
                 });
             })
@@ -646,18 +646,18 @@
       //新增老师
       insertStudent() {
         if (this.sName === "") {
-          this.$message.error(this.lang.Teachercannotempty);
+          this.$message.error("老师姓名不能为空");
           return;
         } else if (
           this.sPhone != "" &&
           !/^[1][3,4,5,7,8][0-9]{9}$/.test(this.sPhone)
         ) {
-          this.$message.error(this.lang.phonenumberincorrect);
+          this.$message.error("手机号格式不正确");
           return;
         } else if (
           !/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)
         ) {
-          this.$message.error(this.lang.Emailformatincorrect);
+          this.$message.error("邮箱格式不正确");
           return;
         }
 
@@ -667,7 +667,7 @@
             .get(this.$store.state.api + "findMail", params)
             .then((res) => {
               if (res.data[0].length > 0) {
-                this.$message.error(this.lang.alreadybeenregistered);
+                this.$message.error("此老师账号已被注册");
               } else {
                 this.add_Student();
               }
@@ -715,7 +715,7 @@
                 console.error(err);
               });
             this.$message({
-              message: this.lang.AddSuccessful,
+              message: "新增成功",
               type: "success",
             });
             this.dialogVisibleAddStudent = false;
@@ -728,7 +728,7 @@
           .catch((err) => {
             this.isLoading = false;
             this.$message({
-              message: this.lang.Additionfailed,
+              message: "新增失败",
               type: "error",
             });
             console.error(err);
@@ -742,23 +742,23 @@
       },
       updateStudent() {
         if (this.userinfo.name === "") {
-          this.$message.error(this.lang.Teachercannotempty);
+          this.$message.error("老师姓名不能为空");
           return;
         } else if (!this.userinfo.classid) {
-          this.$message.error(this.lang.chooseateaching);
+          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(this.lang.phonenumberincorrect);
+          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(this.lang.Emailformatincorrect);
+          this.$message.error("邮箱格式不正确");
           return;
         }
 
@@ -769,7 +769,7 @@
               .get(this.$store.state.api + "findMail", params)
               .then((res) => {
                 if (res.data[0].length > 0) {
-                  this.$message.error(this.lang.alreadybeenregistered);
+                  this.$message.error("此老师账号已被注册");
                 } else {
                   this.update_Student();
                 }
@@ -797,7 +797,7 @@
           .post(this.$store.state.api + "updateStudentInfo", params)
           .then((res) => {
             this.$message({
-              message: this.lang.Editsuccessful,
+              message: "修改成功",
               type: "success",
             });
             this.dialogVisibleUpdate = false;
@@ -806,7 +806,7 @@
           .catch((err) => {
             this.isLoading = false;
             this.$message({
-              message: this.lang.Modificationfailed,
+              message: "修改失败",
               type: "error",
             });
             console.error(err);
@@ -814,9 +814,9 @@
       },
       deleteClassStudent(id) {
         let params = [{ uid: id, cid: this.cid }];
-        this.$confirm(this.lang.Aystrttfta, this.lang.tip, {
-          confirmButtonText: this.lang.Confirm,
-          cancelButtonText: this.lang.Cancel,
+        this.$confirm("确定在本教研室移除此老师吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
           type: "warning",
         })
           .then(() => {
@@ -824,13 +824,13 @@
               .post(this.$store.state.api + "deleteClassTeacher", params)
               .then((res) => {
                 this.$message({
-                  message: this.lang.OperateSuccessful,
+                  message: "操作成功",
                   type: "success",
                 });
                 this.getStudent(this.cid);
               })
               .catch((err) => {
-                this.$message.error(this.lang.operationfailed);
+                this.$message.error("操作失败");
                 console.error(err);
               });
           })
@@ -925,7 +925,7 @@
       },
       addClassStudent() {
         if (!this.checkboxList3.length) {
-          this.$message.error(this.lang.selecttheteacher);
+          this.$message.error('请选择要添加教研室的老师');
           return;
         }
         let params = [{
@@ -935,7 +935,7 @@
         this.ajax
           .post(this.$store.state.api + "addClassTeacher", params)
           .then((res) => {
-            this.$message.success(this.lang.Addedsuccessfully)
+            this.$message.success("添加成功")
             this.checkboxList3 = []
             this.dialogVisibleMember = false
             this.getStudent(this.cid)
@@ -945,9 +945,9 @@
           });
       },
       iniPassword(id) {
-        this.$confirm(this.lang.initializepasswordteacher, this.lang.tip, {
-          confirmButtonText: this.lang.Confirm,
-          cancelButtonText: this.lang.Cancel,
+        this.$confirm("确定" + "初始化" + "此老师的密码吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
           type: "warning",
         })
           .then(() => {
@@ -961,7 +961,7 @@
               .post(this.$store.state.api + "iniPassword", params)
               .then((res) => {
                 this.$message({
-                  message: this.lang.Resetsuccessful,
+                  message: "初始化密码成功!",
                   type: "success",
                 });
               })

+ 55 - 53
src/components/pages/test/add/addTest.vue

@@ -2,7 +2,15 @@
     <div class="pb_content" style="background: #F0F2F5;" v-loading="loading">
         <div class="pb_content_body" style="position: relative; margin: 0">
             <div class="right">
-                <div class="courseTop">
+                <div class="courseTop" v-if="gotype">
+                    <div
+                        class="r_pub_button_retrun"
+                        @click="retrunCourse"
+                    >
+                        返回
+                    </div>
+                </div>
+                <div class="courseTop" v-else>
                     <div class="stepsNav">
                         <el-breadcrumb separator-class="el-icon-arrow-right">
                             <el-breadcrumb-item v-if="!back" :to="{
@@ -16,17 +24,7 @@
                                     '&role=' +
                                     role,
                             }">表单管理</el-breadcrumb-item>
-                            <el-breadcrumb-item v-else-if="back=='sass'" :to="{
-                                path:
-                                    '/sassPlatform?userid=' +
-                                    userid +
-                                    '&oid=' +
-                                    oid +
-                                    '&org=' +
-                                    org +
-                                    '&role=' +
-                                    role,
-                            }">sass平台</el-breadcrumb-item>
+                            <el-breadcrumb-item v-else-if="back=='sass'" @click.stop="$router.back()">sass平台</el-breadcrumb-item>
                             <el-breadcrumb-item>
                                 <span style="color: rgb(15, 126, 255)">新建表单</span>
                             </el-breadcrumb-item>
@@ -65,7 +63,7 @@ export default {
     },
     data() {
         return {
-            gotype:sessionStorage.getItem('gotype'),
+            gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
             userid: this.$route.query.userid,
             oid: this.$route.query.oid,
             org: this.$route.query.org,
@@ -136,16 +134,17 @@ export default {
                             this.role
                         );
                         }else if(this.back == 'sass'){
-                          this.goTo(
-                            "/sassPlatform?userid=" +
-                            this.userid +
-                            "&oid=" +
-                            this.oid +
-                            "&org=" +
-                            this.org +
-                            "&role=" +
-                            this.role
-                        );
+                          this.$router.back()
+                        //   this.goTo(
+                        //     "/sassPlatform?userid=" +
+                        //     this.userid +
+                        //     "&oid=" +
+                        //     this.oid +
+                        //     "&org=" +
+                        //     this.org +
+                        //     "&role=" +
+                        //     this.role
+                        // );
                         }
                     // if (this.cid == "" || this.cid == undefined) {
                     //     if (this.title == "") {
@@ -246,16 +245,17 @@ export default {
                             this.role
                         );
                         }else if(back == 'sass'){
-                          this.goTo(
-                            "/sassPlatform?userid=" +
-                            this.userid +
-                            "&oid=" +
-                            this.oid +
-                            "&org=" +
-                            this.org +
-                            "&role=" +
-                            this.role
-                        );
+                        //   this.goTo(
+                        //     "/sassPlatform?userid=" +
+                        //     this.userid +
+                        //     "&oid=" +
+                        //     this.oid +
+                        //     "&org=" +
+                        //     this.org +
+                        //     "&role=" +
+                        //     this.role
+                        // );
+                        this.$router.back()
                         }
                     }
                     // setTimeout(() => {
@@ -321,16 +321,17 @@ export default {
                             this.role
                         );
                         }else if(this.back == 'sass'){
-                          this.goTo(
-                            "/sassPlatform?userid=" +
-                            this.userid +
-                            "&oid=" +
-                            this.oid +
-                            "&org=" +
-                            this.org +
-                            "&role=" +
-                            this.role
-                        );
+                        //   this.goTo(
+                        //     "/sassPlatform?userid=" +
+                        //     this.userid +
+                        //     "&oid=" +
+                        //     this.oid +
+                        //     "&org=" +
+                        //     this.org +
+                        //     "&role=" +
+                        //     this.role
+                        // );
+                        this.$router.back()
                         }
                     } else if (look == 4) {
                         this.$message.success("保存成功")
@@ -350,16 +351,17 @@ export default {
                             this.role
                         );
                         }else if(this.back == 'sass'){
-                          this.goTo(
-                            "/sassPlatform?userid=" +
-                            this.userid +
-                            "&oid=" +
-                            this.oid +
-                            "&org=" +
-                            this.org +
-                            "&role=" +
-                            this.role
-                        );
+                        //   this.goTo(
+                        //     "/sassPlatform?userid=" +
+                        //     this.userid +
+                        //     "&oid=" +
+                        //     this.oid +
+                        //     "&org=" +
+                        //     this.org +
+                        //     "&role=" +
+                        //     this.role
+                        // );
+                        this.$router.back()
                         }
                     }
                     setTimeout(() => {

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

@@ -245,6 +245,15 @@ export default {
             type2List:[],
             type1Value:"",
             type2Value:"",
+            liYuanOrgList:["3823a6a5-1b6e-11f0-a66a-005056924926",
+						"292e34dc-1b6e-11f0-a66a-005056924926",
+						"21d6b367-1b6e-11f0-a66a-005056924926",
+						"1a1a172d-1b6e-11f0-a66a-005056924926",
+						"1197f86b-1b6e-11f0-a66a-005056924926",
+						"f235659b-1b6d-11f0-a66a-005056924926",
+						"d87b62d3-1b6d-11f0-a66a-005056924926",
+						"c25ea59b-1b6d-11f0-a66a-005056924926",
+          ]
         }
     },
     computed: {
@@ -441,12 +450,17 @@ export default {
             let params = {
                 oid: this.oid,
             };
+            let _url = "selectTestType"
+            if(this.liYuanOrgList.includes(this.org)){
+              _url = "selectTestType_liYuan"
+            }
+
             this.ajax
-                .get(this.$store.state.api + "selectTestType", params)
+                .get(this.$store.state.api + _url, params)
                 .then((res) => {
                     this.typeArray = res.data[0];
                     let _data = res.data[0];
-                    let _type1 = _data.filter(i=>i.pid == '');
+                    let _type1 = _data.filter(i=>!i.pid);
                     _type1.forEach(i=>{
                       let _children = [];
                       _children = _data.filter(i2=>i2.pid == i.id);
@@ -468,6 +482,7 @@ export default {
                           this.typeCheck = _type1[_type1Index].children[0].id;
                         }
                       }
+                      this.typeChange2();
                     }
                     console.log("👉6",_type1)
                 })

+ 2 - 2
src/components/pages/test/aggregate/index.vue

@@ -163,9 +163,9 @@ export default {
     gotoFrom(val, uid) {
       // return console.log(val, uid);
       if(this.betaL == 'beta'){
-        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${uid}`;
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${uid}`;
       }else{
-        this.ifmUrl = `https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${uid}`;
+        this.ifmUrl = `https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${uid}`;
       }
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;

+ 5 - 3
src/components/pages/test/check/check.vue

@@ -4,7 +4,7 @@
       <div class="right">
         <div class="courseTop">
           <div class="stepsNav">
-            <el-breadcrumb separator-class="el-icon-arrow-right">
+            <el-breadcrumb separator-class="el-icon-arrow-right" v-if="!back">
               <el-breadcrumb-item
                 :to="{
                   path:
@@ -65,7 +65,7 @@
         <div class="step_box">
           <div class="edit_top">
             <div class="op_btn">
-              <el-button type="primary" size="small" @click="publish">确定批改</el-button>
+              <el-button type="primary" size="small" @click="publish" v-if="false">确定批改</el-button>
             </div>
           </div>
           <topicVue :cJson="cJson" :title="title" :brief="brief" :checktype="2" :see="see" :isTeacher="1" :name="name" ref="topicVue"></topicVue>
@@ -83,6 +83,7 @@ export default {
   },
   data() {
     return {
+      back:this.$route.query.back,
       userid: this.$route.query.userid,
       userid2: this.$route.query.userid2,
       tid: this.$route.query.tid,
@@ -105,6 +106,7 @@ export default {
   },
   methods: {
     retrunCourse() {
+      if (this.back) return this.$router.go(-1)
       if(this.type == 3){
         this.goTo(
         "/checkToTest2?uid=" +
@@ -257,4 +259,4 @@ export default {
   margin: 0 auto;
   box-sizing: border-box;
 }
-</style>
+</style>

+ 1 - 1
src/components/pages/test/check/docxTemplateDialog.vue

@@ -533,7 +533,7 @@ export default {
             );
           } else if (fieldList[i].type == "file") {
             let _text = ``;
-            if(!fieldList[i].value || !fileList[i].value.length<=0)continue;
+            if(!fieldList[i].value || !fieldList[i].value.length<=0)continue;
             // this.fieldList[i].value.forEach(async f => {
             for (let j = 0; j < fieldList[i].value.length; j++) {
               let f = fieldList[i].value[j];

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 554 - 177
src/components/pages/test/check/index.vue


+ 333 - 0
src/components/pages/test/check/returnTestDialog.vue

@@ -0,0 +1,333 @@
+<template>
+	<div>
+		<el-dialog
+			:center="true"
+			:visible.sync="show"
+			:close-on-click-modal="true"
+			:modal="true"
+			width="auto"
+			height="auto"
+      top="10vh"
+			:append-to-body="true"
+			class="dialog"
+		>
+			<div class="box">
+				<div class="b_head">
+					<span>退回表单</span>
+					<svg
+						@click="close()"
+						t="1748587270371"
+						class="icon"
+						viewBox="0 0 1024 1024"
+						version="1.1"
+						xmlns="http://www.w3.org/2000/svg"
+						p-id="5023"
+						width="200"
+						height="200"
+					>
+						<path
+							d="M0 0h1024v1024H0z"
+							fill="#FF0033"
+							fill-opacity="0"
+							p-id="5024"
+						></path>
+						<path
+							d="M240.448 168l2.346667 2.154667 289.92 289.941333 279.253333-279.253333a42.666667 42.666667 0 0 1 62.506667 58.026666l-2.133334 2.346667-279.296 279.210667 279.274667 279.253333a42.666667 42.666667 0 0 1-58.005333 62.528l-2.346667-2.176-279.253333-279.253333-289.92 289.962666a42.666667 42.666667 0 0 1-62.506667-58.005333l2.154667-2.346667 289.941333-289.962666-289.92-289.92a42.666667 42.666667 0 0 1 57.984-62.506667z"
+							fill="#fff"
+							p-id="5025"
+						></path>
+					</svg>
+				</div>
+				<div class="b_main" v-loading="loading" v-if="data">
+          <div>您将退回内容,并发送以下内容给提交人:</div>
+
+          <div>您提交的“<span>{{ title }}-{{ data.testName?data.testName:'提交记录' }}</span>”的内容已被管理员退回。点击表单链接进行修改后提交。</div>
+          <textarea placeholder="请输入" v-model="textValue"></textarea>
+				</div>
+				<div class="b_bottom">
+          <div @click="close()">取消</div>
+          <div class="b_b_submit" @click="submit()">确定</div>
+				</div>
+			</div>
+		</el-dialog>
+	</div>
+</template>
+
+<script>
+export default {
+  props:{
+    title:{
+      type:String,
+      default:""
+    }
+  },
+	data() {
+		return {
+			loading: false,
+			show: false,
+			data: null,
+      textValue:"",
+      userid:this.$route.query.userid
+		};
+	},
+	methods: {
+		open(data) {
+			this.data = JSON.parse(JSON.stringify(data));
+			this.loading = false;
+			this.show = true;
+		},
+		close() {
+			this.show = false;
+			this.init();
+		},
+		init() {
+			this.data = null;
+      this.textValue = "",
+			this.loading = false;
+		},
+    async submit(){
+      if(!this.textValue.trim()){
+        this.$message({
+          message: '请输入退回理由',
+          type: 'warning'
+        })
+        return
+      }
+
+    // 判断 window.location.href 是否包含 'beta'
+    this.loading = true;
+    let _url =""
+    let _betaUrl = "https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/"
+    let _mainUrl = "https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/"
+    let _userInfo = await this.getUserInfo(this.data.userid)
+
+    if( window.location.href.indexOf('beta') !== -1){
+      _url = `${_betaUrl}doTest?cid=${this.data.courseid}&tid=${this.data.id}&userid=${this.data.userid}&oid=${_userInfo.organizeid}&org=${_userInfo.org}&type=3&role=${_userInfo.role}`
+    }else{
+      _url = `${_mainUrl}doTest?cid=${this.data.courseid}&tid=${this.data.id}&userid=${this.data.userid}&oid=${_userInfo.organizeid}&org=${_userInfo.org}&type=3&role=${_userInfo.role}`
+    }
+
+    let content = `您提交的“<a href="${_url}" target="_blank">${ this.title }-${ this.data.testName?this.data.testName:'提交记录' }</a>”的内容已被管理员退回。点击表单链接进行修改后提交。\n\n退回理由如下:\n\n${this.textValue}`
+
+    let params = [{
+      uid:this.userid,
+      title:`${this.title}表单已被退回`,
+      status:0,
+      type:"其他通知",
+      content:JSON.stringify({text:content}),
+      redUid:this.data.userid,
+      soc:"教师发展-年度考核"
+    }]
+
+
+    let _result  = await this.returnTestFn();
+    if(_result===0)return this.$message.error("退回失败")
+
+    this.ajax.post(this.$store.state.api+"insert_noticeCenter",params).then(res=>{
+      if(res.data==1){
+        this.$message({
+          message: '退回并发送通知成功',
+          type: 'success'
+        })
+        this.reviewChangeFn()
+        this.$emit("success")
+        this.close()
+      }else{
+        this.$message.error("发送通知失败")
+      }
+      this.loading=  false;
+
+    }).catch(err=>{
+      console.log(err)
+      this.$message.error("发送通知失败")
+      this.loading =false
+    })
+
+    },
+    getUserInfo(uid) {
+      let params = {
+        uid: uid,
+      };
+      return new Promise((resolve)=>{
+        this.ajax
+        .get(this.$store.state.api + "selectTestUser", params)
+        .then((res) => {
+          resolve(res.data[0][0])
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+      })
+    },
+    //退回
+    returnTestFn(){
+      let params = [{
+        id:this.data.id,
+        type:"4"
+      }];
+
+      return new Promise((resolve)=>{
+        this.ajax.post(this.$store.state.api+"update_testCourseWorks_typeById",params).then(res=>{
+          if(res.data==1){
+            resolve(1)
+          }else{
+            resolve(0)
+          }
+        }).catch(e=>{
+          console.log(e);
+          resolve(0)
+        })
+      })
+    },
+    //审核取消
+    reviewChangeFn(){
+      let params = [{
+        id:this.data.id,
+        isReview:0
+      }]
+
+      this.ajax.post(this.$store.state.api+"update_testCourseWorks_isReviewById",params).then(res=>{
+        console.log(res);
+      }).catch(e=>{
+        console.log(e);
+      })
+      // console.log(row);
+      // this.tableWorksArray.find(i=>i.id===row.id).isReview = "1";
+      // this.$forceUpdate()
+    },
+	},
+  mounted(){
+
+  },
+};
+</script>
+
+<style scoped>
+.dialog >>> .el-dialog {
+	width: 700px !important;
+	border-radius: 8px;
+	padding: 0;
+	background-color: #fff;
+	overflow: hidden;
+}
+
+.dialog >>> .el-dialog__body {
+	width: 700px !important;
+  height: 80vh;
+	height: auto;
+	flex-shrink: 0;
+	padding: 0;
+	box-sizing: border-box;
+	overflow: auto;
+}
+
+.dialog >>> .el-dialog__header {
+	display: none !important;
+}
+
+.box {
+	width: 700px;
+	height: 380px;
+	background: #fff;
+	border-radius: 15px;
+	box-shadow: 0px 6px 30px 5px rgba(0, 0, 0, 0.05),
+		0px 16px 24px 2px rgba(0, 0, 0, 0.04), 0px 8px 10px -5px rgba(0, 0, 0, 0.08);
+
+}
+
+.b_head {
+	width: 100%;
+	height: 50px;
+	/* border-radius: 15px 15px 0 0; */
+	background: #1A1A1A;
+	display: flex;
+	align-items: center;
+	justify-content: space-between;
+	box-sizing: border-box;
+	padding: 0 20px;
+  color: #fff;
+}
+
+.b_head > span {
+	font-size: 18px;
+	font-weight: bold;
+	color: #fff;
+}
+
+.b_head > img {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_head > svg {
+	width: 20px;
+	height: 20px;
+	cursor: pointer;
+}
+
+.b_main {
+	width: 100%;
+	height: 250px;
+	background: #fff;
+	padding: 20px 20px 20px 20px;
+	box-sizing: border-box;
+  overflow: auto;
+  font-size:16px;
+}
+
+.b_bottom {
+	width: 100%;
+	height: 70px;
+	display: flex;
+	align-items: center;
+	justify-content: flex-end;
+	box-sizing: border-box;
+	padding: 0 20px;
+}
+
+.b_bottom>div{
+  padding: 10px 25px;
+  background: #fff;
+  color: #000;
+  border-radius: 4px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  border: solid 1px #EEEEEE;
+  margin-left: 15px;
+  cursor: pointer;
+  font-size: 16px;
+}
+
+.b_bottom>.b_b_submit{
+  background: #1A1A1A;
+  color: #D4D4D4;
+  border-color: #1A1A1A;
+}
+
+.b_main>div{
+  margin-top:20px;
+  font-size:16px;
+}
+.b_main>div>span{
+  color:#124BF6;
+  text-decoration:underline;
+}
+
+.b_main>textarea{
+  width: 100%;
+  height: 100px;
+  border-radius: 4px;
+  border: solid 1px #D4D4D4;
+  padding: 10px;
+  box-sizing: border-box;
+  margin-top: 20px;
+  resize: none;
+  transition: border-color 0.2s;
+}
+.b_main>textarea:focus {
+  border-color: #7AB8FF; /* 浅蓝色 */
+  outline: none;
+}
+</style>

+ 43 - 7
src/components/pages/test/checkAi/aiLeader.vue

@@ -1820,14 +1820,45 @@ ${fileText}
 
             for (let i = 0; i < works.length; i++) {
               let cJson = this.setJSON(
+              JSON.parse(JSON.stringify(JSON.parse(works[i].courseJson)))
+            );
+            console.log(cJson,'===',chapters)
+            // if (JSON.stringify(cJson) == JSON.stringify(chapters)) {
+              let _json = this.JSONSetting(
                 JSON.parse(JSON.stringify(JSON.parse(works[i].courseJson)))
               );
-              if (JSON.stringify(cJson) == JSON.stringify(chapters)) {
-                let _json = this.JSONSetting(
-                  JSON.parse(JSON.stringify(JSON.parse(works[i].courseJson)))
-                );
 
-                _json.forEach(item => {
+              let _json2 = this.JSONSetting(
+                JSON.parse(JSON.stringify(JSON.parse(JSON.stringify(chapters))))
+              );
+              // let cJson = this.setJSON(
+              //   JSON.parse(JSON.stringify(JSON.parse(works[i].courseJson)))
+              // );
+              // if (JSON.stringify(cJson) == JSON.stringify(chapters)) {
+                // let _json = this.JSONSetting(
+                //   JSON.parse(JSON.stringify(JSON.parse(works[i].courseJson)))
+                // );
+
+                // _json.forEach(item => {
+                //   if (item.type == 11) {
+                //     let cid = item.json.answer2;
+                //     let _title = [];
+                //     for (var i = 0; i < cid.length; i++) {
+                //       _title.push(courseTitles[cid[i]]);
+                //     }
+                //     item.json.answer2 = _title.length ? _title.join(",") : "";
+                //   }
+                //   if (item.type == 6) {
+                //     let courseId = item.json.answer2;
+                //     item.json.answer2 = courseTitles[courseId] || "";
+                //   }
+                // });
+
+
+                _json2.forEach(item=>{
+                let _index = _json.findIndex(i=>(i.type==item.type && i.ttype==item.ttype && i.json.title==item.json.title))
+                if(_index!=-1){
+                  item.json = _json[_index].json;
                   if (item.type == 11) {
                     let cid = item.json.answer2;
                     let _title = [];
@@ -1840,7 +1871,10 @@ ${fileText}
                     let courseId = item.json.answer2;
                     item.json.answer2 = courseTitles[courseId] || "";
                   }
-                });
+                }
+                })
+              if(JSON.stringify(_json2)==JSON.stringify(this.JSONSetting(JSON.parse(JSON.stringify(chapters)))))continue
+
                 // 更新对应的_json对象的answer2
                 array.push({
                   courseid: works[i].courseid,
@@ -1853,13 +1887,15 @@ ${fileText}
                   uteaName: works[i].uteaName,
                   courseJson: JSON.parse(works[i].courseJson)
                 });
-              }
+              // }
             }
             let obj = {
               courseId: testJson.courseId,
               name: testJson.title,
               worksArray: array
             };
+
+            console.log("表单数据=》",obj)
             // this.courseInfoList.push(obj)
             resolve(obj);
           })

+ 7 - 3
src/components/pages/test/databoard.vue

@@ -1,9 +1,10 @@
 <template>
   <div
     class="pb_content"
-    style="height: auto; width: calc(100% - 40px); margin: 0 auto;background: unset;"
+    :style="{padding : gotype ? '0 40px' : ''}"
+    style="height: auto; width: calc(100% - 40px); margin: 0 auto;background: unset;box-sizing: border-box;"
   >
-    <div style="width:100%;padding:0;box-sizing: border-box;">
+    <div style="width:100%;padding:0;box-sizing: border-box;" v-if="!gotype">
       <div class="pb_head top">
         <div style="display: flex;align-items: center;">
           <span
@@ -61,6 +62,7 @@
         </div>
       </div>
     </div>
+    <backPage style="padding-left: 0;" v-else tit="学生管理"></backPage>
     <div class="bbox_serch">
       <el-select
         v-model="selectTime"
@@ -165,15 +167,17 @@ import radarZong from "./dataCom/radarZong.vue";
 import radarTeacher from "./dataCom/radarTeacher.vue";
 
 import Cascader from "./dataCom/cascader.vue";
+import backPage from "../liyuan/components/backPage.vue";
 
 export default {
   name: "testDataBoard",
-  components: { radarZong, radarTeacher, Cascader },
+  components: { radarZong, radarTeacher, Cascader,backPage },
   data() {
     return {
       userid: this.$route.query.userid, //用户id
       oid: this.$route.query.oid, //学校id
       org: this.$route.query.org, //组织id
+      gotype: (window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       pType: 2,
       teacherName: "",
       tabLoading: false,

+ 499 - 34
src/components/pages/test/examine/conpoments/personPage.vue

@@ -20,7 +20,7 @@
         </div> -->
       </div>
       <el-table
-        :data="tableData"
+        :data="copyTableData"
         class="scoTab"
         v-loading="tabLoading"
         style="width: 100%"
@@ -63,7 +63,7 @@
           label="自评总分"
         >
         </el-table-column>
-        <el-table-column align="center" label="一级指标评分" >
+        <!-- <el-table-column align="center" label="一级指标评分" >
           <template slot-scope="scope">
             <div class= "scoreBox" v-for="item, index in scope.row.json" :key="index">
               <el-tooltip :content="item.name" placement="top" effect="dark">
@@ -80,7 +80,24 @@
           align="center"
           label="考核总分"
         >
+        </el-table-column> -->
+
+
+        <el-table-column
+          align="center"
+          label="状态"
+        >
+        <template slot-scope="scope">
+          <div class="taskArea" v-if="[0,1].includes(scope.row.isReview)">
+            <span :class="`task_${scope.row.isReview}`">{{ typeStatusList[scope.row.isReview] }}</span>
+
+          </div>
+          <span v-else>/</span>
+          <!-- <div v-if="scope.row.state == '已完成'">已完成</div>
+          <div v-else>未完成</div> -->
+        </template>
         </el-table-column>
+
         <el-table-column align="center" label="操作">
           <template slot-scope="scope">
             <div style="display: flex;justify-content: center;">
@@ -106,6 +123,7 @@
           <div class="teaLis">
             <div
               class="teal"
+              v-if="digType==2"
               @click="cutPage(2)"
               :class="[digType == 2 ? 'Tbor' : '']"
             >
@@ -114,6 +132,7 @@
             <div
               class="teal"
               @click="cutPage(1)"
+               v-if="digType == 1"
               :class="[digType == 1 ? 'Tbor' : '']"
             >
               班主任考核
@@ -129,16 +148,26 @@
               v-if="tableData.length > 0"
               style="display: flex;justify-content: space-between;width: 150px;"
             >
-              <div>
+              <div style="margin-right:10px">
                 <el-button type="primary" size="mini" @click="upTea"
                   >上一个</el-button
                 >
               </div>
-              <div>
+              <div style="margin-right:10px">
                 <el-button type="primary" size="mini" @click="nextTea"
                   >下一个</el-button
                 >
               </div>
+              <div style="margin-right:10px">
+                <el-button type="primary" size="mini" @click="saveBtn"
+                  >保存</el-button
+                >
+              </div>
+              <div style="margin-right:10px">
+                <el-button type="primary" size="mini" @click="exportExlec"
+                  >导出</el-button
+                >
+              </div>
             </div>
           </div>
           <div
@@ -160,8 +189,10 @@
               </el-tooltip>
             </div>
             <div>审核进度:{{ computedStep }}/{{ twoTarget }}</div>
-            <div>自评分数:{{ DigSelfSco }}</div>
-            <div>考核分数:{{ computedSco }}</div>
+            <div>自评分:{{ DigSelfSco }}</div>
+            <div>认定分:{{ computedSco }}</div>
+            <div v-if="formula">加权分:{{formulaScore}}</div>
+
           </div>
         </div>
         <div style="height:100%;overflow: auto;padding-bottom: 80px;">
@@ -207,11 +238,11 @@
                         <div v-else style="padding-top: 10px;">
                           <!-- {{ reverseString(k.testid.test) }} -->
                           <div
-                            v-for="(item2, index) in k.testid.test"
+                            v-for="(item2) in k.testid.test"
                             :key="item2.courseId"
                             class="orgData"
                           >
-                            <div @click="lookUserPrize(item2.courseId)">
+                            <div :style="item2.status==2?`color:red`:''" @click="lookUserPrize(item2.courseId)">
                               {{ item2.title }}:{{ item2.num }}份
                             </div>
                           </div>
@@ -233,8 +264,22 @@
                                   : ''
                               )
                             "
-                            v-model.number="k.sco2"
+                            v-model="k.sco2"
                             v-stopMousewheel
+                            @input="val => {
+                              // 只允许输入数字(整数或小数)
+                              let num = val.replace(/[^0-9.]/g, '');
+                              // 防止多个小数点
+                              num = num.replace(/\.{2,}/g, '.');
+                              num = num.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.');
+                              // 防止小数点开头
+                              if(num !== '' && num[0] === '.') num = '';
+                              // 防止小数点后多余数字
+                              if(num.split('.').length > 1 && num.split('.')[1].length > 2) {
+                                num = num.split('.')[0] + '.' + num.split('.')[1].slice(0, 2);
+                              }
+                              k.sco2 = num;
+                            }"
                           ></el-input>
                         </div>
                       </div>
@@ -352,6 +397,7 @@
 
 <script>
 import shareBox from "./shareBox/index";
+import XLSX from 'xlsx-js-style'
 export default {
   directives: {
     stopMousewheel: {
@@ -372,6 +418,14 @@ export default {
     teacherName: {
       type: String,
       default: ""
+    },
+    timeA: {
+      type:String,
+      default:""
+    },
+    timeB: {
+      type: String,
+      default:""
     }
   },
   components: {
@@ -403,9 +457,13 @@ export default {
       oid: this.$route.query.oid, //学校id
       org: this.$route.query.org, //组织id
       tableData: [],
+      copyTableData:[],
       TeachingOptions: [],
       PageBaseDataTwo: [],
-      remDig: false
+      remDig: false,
+      timeSortList:[],
+      typeStatusList:["待办","已完成",'/'],
+      formula:""
     };
   },
   watch: {
@@ -414,6 +472,16 @@ export default {
     },
     digType(newVal, oldVal) {
       this.getDataDig();
+    },
+    timeA(newVal){
+      if(newVal){
+        this.timeSortFn()
+      }
+    },
+    timeB(newVal){
+      if(newVal){
+        this.timeSortFn()
+      }
     }
   },
   computed: {
@@ -473,12 +541,181 @@ export default {
         return score;
       }
     },
+
+    formulaScore(){
+      let _result = "0.00"
+
+      if(this.formula && this.PageBaseData){
+        let scoreObj = {}
+        this.PageBaseData.forEach(i=>{
+          if(!scoreObj[i.id]){
+            scoreObj[i.id] = 0;
+          }
+
+          i.children.forEach(i2=>{
+            if(i2.sco2){
+              scoreObj[i.id]+=parseFloat(i2.sco2)
+            }
+          })
+        })
+
+        let formulaText = this.formula;
+        for (const key in scoreObj) {
+            if (scoreObj.hasOwnProperty(key)) {
+              const regex = new RegExp('\\b' + key + '\\b', 'g');
+              formulaText = formulaText.replace(regex, scoreObj[key]);
+            }
+        }
+
+        if(!formulaText)return _result;
+
+        try{
+          _result = eval(formulaText).toFixed(2)
+        }catch(e){
+          console.log(e)
+        }
+
+      }
+
+
+      return _result;
+    }
   },
   mounted() {
     this.getData();
     this.getTeaList();
   },
   methods: {
+  exportExlec(){
+    let headers = [
+      ['一级指标', '二级指标', '分值', '自评', '自评概述', '认定', '认定概述']
+    ];
+    let info = [['姓名:'+this.digUsername ,'','','','自评分:'+this.DigSelfSco,'认定分:'+this.computedSco,'加权分:'+this.formulaScore]]
+    //  var XLSX = require("xlsx");
+     let data = [
+      ...info,
+      ...headers,
+      ...this.PageBaseData.flatMap(parent =>
+        parent.children.map(child => [
+          parent.name, // 一级指标
+          child.name,  // 二级指标
+          child.score,   // 分值
+          child.sco1,   // 自评
+          child.selfSummary,   // 自评概述
+          child.sco2,   // 认定
+          child.cogSum   // 认定概述
+
+        ]))
+     ]
+    const wb = XLSX.utils.book_new(); //创建一个新的工作簿对象
+    // 创建一个Worksheet对象
+    let ws = XLSX.utils.aoa_to_sheet(data);
+
+
+
+
+//  定义通用样式(包含居中)
+const commonStyle = {
+  alignment: {
+    horizontal: "center",
+    vertical: "center",
+    wrapText: true  // 关键属性:启用自动换行
+  },
+  font: {
+    sz: 12
+  }
+};
+
+
+// 应用样式到所有单元格
+for (let r = 0; r < data.length; ++r) {
+  for (let c = 0; c < data[r].length; ++c) {
+    const cellRef = XLSX.utils.encode_cell({ r, c });
+    ws[cellRef] = ws[cellRef] || {};
+    ws[cellRef].s =  commonStyle;
+  }
+}
+
+// 设置列宽
+ws['!cols'] = [
+    { wch: 15 }, // 一级指标
+    { wch: 20 }, // 二级指标
+    { wch: 8 }, // 分值
+    { wch: 8 }, // 自评
+    { wch: 13 }, // 自评概述
+    { wch: 13 }, // 认定
+    { wch: 16 }  // 认定概述
+];
+
+// 设置行高
+ws['!rows'] = [
+    { hpx: 25 }, // 表头行
+    { hpx: 25 }, // 其他行的默认高度
+    // 根据需要继续添加行高设置
+];
+  console.log('kk',data);
+    // 合并单元格
+  ws['!merges'] = [];
+  // 设置打印参数
+ws['!page'] = {
+    orientation: 'portrait',  // 强制竖向打印
+    margins: {left:0.5, right:0.5, top:0.75, bottom:0.75}, // 单位:英寸
+    fitToPage: true,          // 启用自动缩放
+    fitToHeight: 0,           // 不限制垂直页数
+    fitToWidth: 1             // 强制缩放到1页宽度
+  };
+
+  // 可选:压缩字体提升兼容性
+  if(!ws['A1'].s) ws['A1'].s = {};
+  ws['A1'].s.font = {sz:10}; // 设置基准字体10pt
+
+  // 记录合并单元格的逻辑
+  let startRow = 2; // 数据开始行
+  let previousParentName = null;
+  let count = 0; // 计数连续相同的一级指标行
+
+  for (let index = 1; index < data.length; index++) {
+      const currentParentName = data[index][0]; // 当前行的一级指标
+
+      if (currentParentName === previousParentName) {
+          count++; // 继续计数
+      } else {
+          if (count > 0) { // 如果有连续的相同项
+              ws['!merges'].push({
+                  s: { r: startRow, c: 0 },
+                  e: { r: startRow + count, c: 0 }
+              });
+          }
+          // 更新开始行和计数
+          startRow = index; // 更新为当前行的开始行
+          count = 0; // 重置计数
+      }
+
+      previousParentName = currentParentName; // 更新前一个一级指标
+  }
+  ws['A1'].s = { alignment: { horizontal: 'left' } }
+  ws['E1'].s = { alignment: { horizontal: 'left' } }
+  ws['F1'].s = { alignment: { horizontal: 'left' } }
+  ws['G1'].s = { alignment: { horizontal: 'left' } }
+  // 检查最后一组
+  if (count > 0) {
+      ws['!merges'].push({
+          s: { r: startRow, c: 0 },
+          e: { r: startRow + count, c: 0 }
+      });
+  }
+  ws['!merges'].push( { s: { r: 0, c: 0 }, e: { r: 0, c: 3 } },  // 合并姓名部分(A1-E1)
+    // { s: { r: 0, c: 5 }, e: { r: 0, c: 6 } },  // 单独保留自评分数(G1)
+    // { s: { r: 0, c: 7 }, e: { r: 0, c: 7 } }   // 单独保留认定分数(H1));
+)
+
+      XLSX.utils.book_append_sheet(wb, ws, "sheet1"); //把sheet添加到workbook里,第三个参数是sheet名
+      XLSX.writeFile(wb, this.digUsername +'-'+ (this.digType == 1 ? '班主任考核' :'专任教师')+".xlsx");
+      this.$message({
+        message: "导出成功",
+        type: "success"
+      });
+    },
     // 禁用滚轮事件
     handleWheel(event) {
       event.preventDefault();
@@ -494,9 +731,10 @@ export default {
       };
       // console.log(params);
       this.ajax
-        .get(this.$store.state.api + "selectTestExaminePersonData", params)
-        .then(res => {
+        .get(this.$store.state.api + "selectTestExaminePersonData_filterTime", params)
+        .then(async res => {
           let data = res.data[0];
+          console.log(data)
 
           data.forEach(e => {
             e.json = JSON.parse(e.json);
@@ -532,8 +770,49 @@ export default {
             e.evaSca = e.evaSca.toFixed(2);
             e.cogSco = e.cogSco.toFixed(2);
           });
+
+          for(let i = 0;i<data.length;i++){
+            let testList = [];
+            data[i].json.forEach(i2=>{
+              if(i2.children.length>0){
+                i2.children.forEach(i3=>{
+                  if(i3.testid.test.length>0){
+                    testList.push(...i3.testid.test)
+                  }
+                })
+              }
+            })
+
+
+            if(testList.length>0){
+              let _time = data[i].timeValue?JSON.parse(data[i].timeValue):{};
+              let testData = await this.computedTest(testList,data[i].userid,_time)
+              let _isReviewNum = 0;
+              let _num = 0;
+              testData.forEach(i=>{
+                _isReviewNum+=i.isReviewNum;
+                _num+=i.num;
+
+              })
+              if(_num>0){
+                if(_num==_isReviewNum){
+                  data[i].isReview = 1;
+                }else{
+                  data[i].isReview = 0;
+                }
+              }else{
+                data[i].isReview = 2;
+              }
+
+
+            }
+          }
+
+
           this.tableData = data;
+          this.copyTableData = data;
           this.tabLoading = false;
+          this.timeSortFn()
         })
         .catch(error => {
           this.tabLoading = false;
@@ -554,6 +833,9 @@ export default {
       this.diaSco = true;
       this.digUserid = val.userid;
       this.disTeaClass = val.tea;
+      if(val.timeValue){
+        this.timeSortList = JSON.parse(val.timeValue)
+      }
       this.cutPerson();
       this.getPageBase();
     },
@@ -594,7 +876,7 @@ export default {
         });
     },
     // 撤回
-    withdraw(id) {
+    async withdraw(id) {
       let params = [
         {
           tid: id
@@ -606,11 +888,47 @@ export default {
         cancelButtonText: "取消",
         type: " info"
       })
-        .then(() => {
+        .then(async () => {
           this.ajax
             .post(this.$store.state.api + "updateExamineState", params)
-            .then(res => {
-              this.getData();
+            .then(async res => {
+              let _testList = [];
+              this.tabLoading = true;
+      let _test = this.tableData.find(i=>i.id==id);
+      _test.json.forEach(i=>{
+        if(i.children.length>0){
+          i.children.forEach(i2=>{
+            if(i2.testid.test.length>0){
+              _testList.push(...i2.testid.test)
+            }
+          })
+        }
+      })
+
+      let _time = _test.timeValue?JSON.parse(_test.timeValue):{};
+
+      let allTestData = await this.computedTest(_testList,_test.userid,_time)
+
+
+      let allTestList = []
+      allTestData.forEach(i=>{
+        if(i.testId){
+          let _sp = i.testId.split(',')
+          allTestList.push(..._sp)
+        }
+      })
+
+      let promise = []
+
+      allTestList.forEach(i=>{
+        promise.push(this.reviewChangeFn(i))
+      })
+
+      Promise.all(promise).then(res=>{
+        this.$message.success("退回成功")
+        this.getData();
+      })
+
             })
             .catch(error => {
               console.log(error);
@@ -623,6 +941,42 @@ export default {
           // });
         });
     },
+    returnTestFn(id){
+      let params = [{
+        id:id,
+        type:"4"
+      }];
+
+      return new Promise((resolve)=>{
+        this.ajax.post(this.$store.state.api+"update_testCourseWorks_typeById",params).then(res=>{
+          if(res.data==1){
+            resolve(1)
+          }else{
+            resolve(0)
+          }
+        }).catch(e=>{
+          console.log(e);
+          resolve(0)
+        })
+      })
+    },
+    reviewChangeFn(id){
+      let params = [{
+        id:id,
+        isReview:0
+      }]
+
+      return new Promise((resolve)=>{
+        this.ajax.post(this.$store.state.api+"update_testCourseWorks_isReviewById",params).then(res=>{
+          resolve(1)
+        }).catch(e=>{
+          resolve(0)
+        })
+      })
+      // console.log(row);
+      // this.tableWorksArray.find(i=>i.id===row.id).isReview = "1";
+      // this.$forceUpdate()
+    },
     recordBtn(val) {
       this.RecordList = [];
       this.recordVisible = true;
@@ -651,9 +1005,11 @@ export default {
     remindExamine() {
       this.remDig = true;
     },
+
     // 下载excel
     getExcel() {
       var res = this.tableData;
+
       // console.log('导出数据',res);
       //如果value的json字段的key值和想要的headers值不一致时,可做如下更改
       //将和下面的Object.fromEntries结合,将json字段的key值改变为要求的excel的header值
@@ -664,8 +1020,8 @@ export default {
         _json["教师账号"] = res[i].eName;
         _json["所属教研室"] = res[i].tea;
         _json["考核进度"] = `${res[i].step}/${res[i].allStep}`;
-        _json["自评分"] = res[i].evaSca;
-        _json["考核分数"] = res[i].cogSco;
+        _json["自评分"] = res[i].evaSca;
+        _json["认定分"] = res[i].cogSco;
         array.push(_json);
       }
 
@@ -765,6 +1121,8 @@ export default {
           })
         }
       ];
+
+      console.log("params",params[0])
       // return console.log(params);
       this.ajax
         .post(this.$store.state.api + "updateExamineCogDataCopy", params)
@@ -784,7 +1142,13 @@ export default {
         return this.$message.error("暂无人员提交");
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}`;
 
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${cid}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.digUserid}`;
+      if(this.timeSortList){
+        let timeValue = this.timeSortList.time
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${cid}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.digUserid}&timeLimit=${timeValue}&review=1&disableBack=true`;
+      }else{
+      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${cid}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.digUserid}&review=1&disableBack=true`;
+
+      }
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -838,25 +1202,25 @@ export default {
       this.digLoading = true;
 
       this.cutTeaNum--;
-      this.digUsername = this.tableData[this.cutTeaNum].username;
-      this.disTeaClass = this.tableData[this.cutTeaNum].tea;
-      this.digUserid = this.tableData[this.cutTeaNum].userid;
-      this.digTid = this.tableData[this.cutTeaNum].id;
+      this.digUsername = this.copyTableData[this.cutTeaNum].username;
+      this.disTeaClass = this.copyTableData[this.cutTeaNum].tea;
+      this.digUserid = this.copyTableData[this.cutTeaNum].userid;
+      this.digTid = this.copyTableData[this.cutTeaNum].id;
 
       this.getPageBase();
     },
     // 弹框切换下一个教师
     nextTea() {
       // console.log("this.tableData", this.tableData);
-      if (this.cutTeaNum + 1 >= this.tableData.length)
+      if (this.cutTeaNum + 1 >= this.copyTableData.length)
         return this.$message.error("已经是最后一个了");
       this.digLoading = true;
 
       this.cutTeaNum++;
-      this.digUsername = this.tableData[this.cutTeaNum].username;
-      this.disTeaClass = this.tableData[this.cutTeaNum].tea;
-      this.digUserid = this.tableData[this.cutTeaNum].userid;
-      this.digTid = this.tableData[this.cutTeaNum].id;
+      this.digUsername = this.copyTableData[this.cutTeaNum].username;
+      this.disTeaClass = this.copyTableData[this.cutTeaNum].tea;
+      this.digUserid = this.copyTableData[this.cutTeaNum].userid;
+      this.digTid = this.copyTableData[this.cutTeaNum].id;
 
       this.getPageBase();
     },
@@ -898,7 +1262,8 @@ export default {
         .get(this.$store.state.api + "selectTestExamineBase", params)
         .then(res => {
           // console.log("selectTestExamineBase", res.data[0][0]);
-
+          this.formula = res.data[0][0].formula?res.data[0][0].formula:"";
+          console.log("formula",this.formula)
           this.PageBaseData = JSON.parse(res.data[0][0].json);
           this.PageBaseDataTwo = JSON.parse(res.data[0][0].json);
           // 处理数据来源
@@ -922,7 +1287,9 @@ export default {
           console.log("getTestExamineByUserId", res);
 
           if (res.data[0].length > 0) {
-            let val = JSON.parse(res.data[0][0].json);
+            let _data = res.data[0].find(i=>i.id==this.digTid)
+            if(_data){
+              let val = JSON.parse(_data.json);
 
             this.PageBaseData.forEach(e => {
               val.forEach(i => {
@@ -943,6 +1310,7 @@ export default {
             this.PageBaseDataTwo = val;
             // 弹框计算自评分数,与二级指标个数
             this.getTwoRigData();
+            }
           } else {
             // 清空自评分数,与二级指标个数
             this.DigSelfSco = 0;
@@ -980,6 +1348,7 @@ export default {
     },
     // 评分关闭弹框
     handleClose(done) {
+      this.timeSortList = [];
       this.getData();
       done();
     },
@@ -1003,23 +1372,97 @@ export default {
       }
     },
     // 处理数据来源
-    computedTest(val) {
+    computedTest(val,uid='',timeSortList=this.timeSortList) {
       let params = [
         {
-          uid: this.digUserid,
+          uid: uid?uid:this.digUserid,
           testId: val.join(",")
         }
       ];
+
+
+      let _fnStr = `selectExamineTestName`
+      console.log("this.timeSortList",timeSortList)
+      if(timeSortList && timeSortList.time && timeSortList.time.length>0){
+        const timeValue = timeSortList.time;
+        params[0].startTime = timeValue[0];
+        params[0].endTime = timeValue[1];
+        _fnStr = `selectExamineTestNameFilterTime`
+      }
+
       return new Promise(resolve => {
         this.ajax
-          .post(this.$store.state.api + "selectExamineTestName", params)
+          .post(this.$store.state.api + _fnStr, params)
           .then(res => {
-            resolve(res.data[0]);
+
+            let _data = res.data[0];
+
+            _data.forEach(i=>{
+              if(i.num>0){
+                if(i.num==i.isReviewNum){
+                  i.status = 1;
+                }else{
+                  i.status = 2;
+                }
+              }else{
+                i.status = 0;
+              }
+            })
+            console.log("_data",_data)
+
+            resolve(_data);
           })
           .catch(error => {
             console.log(error);
           });
       });
+    },
+    //时间筛选
+    timeSortFn(){
+      console.log("timeSortFn",this.timeA,this.timeB)
+      if(this.pType == 1 && this.timeA){
+        this.copyTableData = this.tableData.filter(i=>i.time == this.timeA)
+      }else if(this.pType == 2 && this.timeB){
+        this.copyTableData = this.tableData.filter(i=>i.time == this.timeB)
+      }
+    },
+    //保存按钮
+    saveBtn(){
+      let PageBaseDataCopy = JSON.parse(JSON.stringify(this.PageBaseData));
+
+      for (const e of PageBaseDataCopy) {
+        for (const k of e.children) {
+          if (k.testid.test.length > 0) {
+            k.testid.test = k.testid.test.map(item => item.courseId);
+          }
+        }
+      }
+
+      let params = [
+        {
+          uid: this.userid,
+          tid: this.digTid,
+          typ: this.pType,
+          // json: JSON.stringify(PageBaseDataCopy)
+          json: JSON.stringify(PageBaseDataCopy),
+          rjson: JSON.stringify({
+            rjson: PageBaseDataCopy,
+            text: `按人员,进行修改`
+          })
+        }
+      ];
+      // return console.log(params);
+      this.ajax
+        .post(this.$store.state.api + "updateExamineCogDataCopy", params)
+        .then(res => {
+          // console.log("updateExamineCogDataCopy", res);
+          // this.CopDigSco();
+          this.getDigData();
+          this.$message.success("保存成功")
+        })
+        .catch(error => {
+          console.log(error);
+        });
     }
   }
 };
@@ -1298,6 +1741,7 @@ input[type="number"] {
 }
 .twoCon > div:nth-child(2) {
   width: 160px !important;
+  line-height: 20px;
 }
 .twoCon > div:nth-child(3) {
   width: 110px !important;
@@ -1340,4 +1784,25 @@ input[type="number"] {
   margin-left: 10px;
 }
 
+
+.taskArea{
+  display: flex;
+  justify-content: center;
+}
+
+.task_0{
+  padding: 6px 20px;
+  background: #FEF5EC;
+  border: solid 1px #FAD0A1;
+  color: #F7933B;
+  border-radius: 4px;
+}
+
+.task_1{
+  padding: 6px 20px;
+  background: #E6F9EA;
+  border: solid 1px #A6E9B6;
+  color: #21ba45;
+  border-radius: 4px;
+}
 </style>

+ 122 - 10
src/components/pages/test/examine/conpoments/targetPage.vue

@@ -34,7 +34,7 @@
                   <div v-if="!k.testid.test.length">/</div>
                   <div v-else style="padding-top: 10px;">
                     <div
-                      v-for="(item2, index) in k.testid.test"
+                      v-for="(item2) in k.testid.test"
                       :key="item2.courseId"
                       @click="lookPrize(item2.courseId)"
                       class="orgDataCss"
@@ -91,7 +91,7 @@
                   <div v-if="!k.testid.test.length">/</div>
                   <div v-else style="padding-top: 10px;">
                     <div
-                      v-for="(item2, index) in k.testid.test"
+                      v-for="(item2) in k.testid.test"
                       :key="item2.courseId"
                       @click="lookPrize(item2.courseId)"
                       class="orgDataCss"
@@ -159,6 +159,11 @@
             <div>存在分差总人数:{{ evaScoDigPerC }}</div>
           </div>
           <div class="diaScoreRight">
+
+            <el-button size="small" @click="useAiScore" type="primary"
+              >使用AI评分</el-button
+            >
+
             <el-button size="small" @click="allSubmit" type="primary"
               >保存</el-button
             >
@@ -214,7 +219,7 @@
               <div v-if="!scope.row.orgData.length">/</div>
               <div v-else style="padding-top: 10px;">
                 <div
-                  v-for="(item2, index) in scope.row.orgData"
+                  v-for="(item2) in scope.row.orgData"
                   :key="item2.courseId"
                   class="orgDataCss"
                 >
@@ -226,6 +231,19 @@
               </div>
             </template>
           </el-table-column>
+          <el-table-column
+            :show-overflow-tooltip="true"
+            align="center"
+            label="状态"
+          >
+            <template slot-scope="scope">
+             <div v-if="scope.row.numCount" class="taskArea">
+              <div v-if="scope.row.numCount == scope.row.isReviewCount" class="isComputedTask">已完成</div>
+              <div v-if="scope.row.numCount != scope.row.isReviewCount" class="waitComputedTask">代办</div>
+             </div>
+             <span v-else>/</span>
+            </template>
+          </el-table-column>
           <el-table-column
             :sortable="true"
             :sort-method="sortCogMethod"
@@ -1509,13 +1527,23 @@ export default {
           testId: val.join(",")
         }
       ];
+      let _fnStr = `selectExamineTestName`
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        params[0].startTime = timeValue[0];
+        params[0].endTime = timeValue[1];
+        _fnStr = `selectExamineTestNameFilterTime`
+      }
       return new Promise(resolve => {
         this.ajax
-          .post(this.$store.state.api + "selectExamineTestName", params)
+          .post(this.$store.state.api + _fnStr, params)
           .then(res => {
+            let _data = res.data[0];
+
+            console.log("_data",_data)
             // console.log("resresresres", res.data[0]);
             // console.log(res.data[0]);
-            resolve(res.data[0]);
+            resolve(_data);
           })
           .catch(error => {
             console.log(error);
@@ -1525,7 +1553,14 @@ export default {
 
     // 查看数据来源
     lookPrize(val) {
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0`;
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&userid=${this.userid}&type=2&role=0&disableBack=true&timeLimit=${timeValue}`;
+      }else{
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&userid=${this.userid}&type=2&role=0&disableBack=true`;
+      }
+      // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&userid=${this.userid}&type=2&role=0&disableBack=true`;
+      // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&userid=${this.userid}&type=2&role=0&disableBack=true&`;
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -1643,6 +1678,8 @@ export default {
       for (const e of this.tableData) {
         if (e.orgData.length > 0) {
           e.orgData = await this.computedScoTest(e.orgData, e.userid);
+          e.isReviewCount = e.orgData.reduce((sum, i) => sum + (i.isReviewNum || 0), 0)
+          e.numCount = e.orgData.reduce((sum, i) => sum + (i.num || 0), 0)
         }
       }
     },
@@ -1653,12 +1690,46 @@ export default {
           testId: val.join(",")
         }
       ];
+
+      let _fnStr = `selectExamineTestName`
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        params[0].startTime = timeValue[0];
+        params[0].endTime = timeValue[1];
+        _fnStr = `selectExamineTestNameFilterTime`
+      }
+
       return new Promise(resolve => {
         this.ajax
-          .post(this.$store.state.api + "selectExamineTestName", params)
+          .post(this.$store.state.api + _fnStr, params)
           .then(res => {
-            console.log("selectExamineTestName", res.data[0]);
-            resolve(res.data[0]);
+            let _data = res.data[0];
+
+            console.log('sfasfaafaf',_data)
+            _data[0].average = "";
+            let _total = 0;
+            let _num = 0;
+
+            _data.forEach(i=>{
+              let _scoreJson = [];
+              if(i.scoreJson){
+                _scoreJson = JSON.parse(i.scoreJson)
+                _scoreJson = _scoreJson.filter(i2=>i.testId && i.testId.indexOf(i2.id)!=-1);
+                i.scoreJson = _scoreJson;
+                _num += _scoreJson.length;
+                _total += _scoreJson.reduce((sum, i2) => sum + i2.sco, 0);
+                console.log(_num,_total)
+              }
+            })
+
+            if(_total>0&&_num>0){
+              _data[0].average = _total.toFixed(0)
+              // _data[0].average = (_total / _num).toFixed(0);
+            }
+
+
+            console.log("_data",_data)
+            resolve(_data);
           })
           .catch(error => {
             console.log(error);
@@ -1671,7 +1742,13 @@ export default {
       // return console.log(val);
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}`;
 
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${cid}&oid=${val.organizeid}&org=${val.org}&type=2&role=0&peopleId=${val.userid}`;
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${cid}&oid=${val.organizeid}&userid=${this.userid}&org=${val.org}&type=2&role=0&peopleId=${val.userid}&disableBack=true&timeLimit=${timeValue}&review=1`;
+      }else{
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${cid}&oid=${val.organizeid}&userid=${this.userid}&org=${val.org}&type=2&role=0&peopleId=${val.userid}&disableBack=true&review=1`;
+      }
+      // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${cid}&oid=${val.organizeid}&userid=${this.userid}&org=${val.org}&type=2&role=0&peopleId=${val.userid}&disableBack=true`;
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -1820,6 +1897,20 @@ export default {
           });
         });
     },
+
+    // 使用ai的评分数据
+    useAiScore(){
+      this.tableData.forEach(i=>{
+        if(i.orgData.length>0 && i.orgData[0].average){
+          if(parseInt(i.orgData[0].average)>i.score){
+            i.cogSco = i.score
+          }else{
+            i.cogSco = parseInt(i.orgData[0].average)
+          }
+        }
+      })
+      this.$forceUpdate();
+    },
     // 处理一键保存
     async handleAllSubmit() {
       for (const e of this.tableData) {
@@ -2152,4 +2243,25 @@ input[type="number"] {
   -webkit-appearance: none;
   margin: 0;
 }
+
+.taskArea{
+  display: flex;
+  justify-content: center;
+}
+
+.waitComputedTask{
+  padding: 10px 20px;
+  background: #FEF5EC;
+  border: solid 1px #FAD0A1;
+  color: #F7933B;
+  border-radius: 4px;
+}
+
+.isComputedTask{
+  padding: 10px 20px;
+  background: #E6F9EA;
+  border: solid 1px #A6E9B6;
+  color: #21ba45;
+  border-radius: 4px;
+}
 </style>

+ 13 - 6
src/components/pages/test/examine/index.vue

@@ -1,5 +1,7 @@
 <template>
-  <div class="testExamine">
+  <div class="testExamine" :style="{padding: gotype ? '0 90px' : '10px'}">
+    <backPage style="padding: 40px 0 0;" v-if="gotype" tit="考核审核"></backPage>
+
     <div class="testTit">
       <div class="teaLis">
         <div
@@ -26,7 +28,7 @@
           @change="selectTeaName"
           placeholder="请输入教师姓名"
         ></el-input>
-        <div style="margin: 0 20px;" v-if="timeListA.length>1 && pType == 1 && cutTable!=1">
+        <div style="margin: 0 20px;" v-if="timeListA.length>1 && pType == 1">
           <el-select v-model="timeA" placeholder="请选择">
             <el-option
               v-for="item in timeListA"
@@ -38,7 +40,7 @@
           </el-select>
         </div>
 
-        <div style="margin: 0 20px;" v-if="timeListB.length>0 && pType == 2 && cutTable!=1">
+        <div style="margin: 0 20px;" v-if="timeListB.length>0 && pType == 2">
           <el-select v-model="timeB" placeholder="请选择">
             <el-option
               v-for="item in timeListB"
@@ -61,7 +63,7 @@
           </el-select>
         </div>
         <div
-          v-if="cutTable == 1"
+          v-if="cutTable == 1 && false"
           class="remindBtn"
           style="margin-right: 20px;"
           @click="excelBtn"
@@ -79,6 +81,8 @@
         ref="child"
         :pType="pType"
         :teacherName="teacherName"
+        :timeA="timeA"
+        :timeB="timeB"
         v-if="cutTable == 1"
       ></personPage>
     </div>
@@ -88,14 +92,17 @@
 <script>
 import personPage from "./conpoments/personPage.vue";
 import targetPage from "./conpoments/targetPage";
+import backPage from "../../liyuan/components/backPage.vue";
 
 export default {
   components: {
     personPage,
-    targetPage
+    targetPage,
+    backPage
   },
   data() {
     return {
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       aArray: [],
       bArray: [],
       timeListA:[],
@@ -105,7 +112,7 @@ export default {
       oid: this.$route.query.oid,
       org: this.$route.query.org,
       pType: 2,
-      cutTable: 0,
+      cutTable: 1,
       teacherName: "",
       cutTabOpts: [
         {

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

@@ -1,5 +1,5 @@
 <template>
-    <div class="pb_content" :style="{padding: gotype ? '0 90px' :''}" style="height: auto; width: calc(100% - 40px); margin: 0 auto;background: unset;box-sizing: border-box;">
+    <div class="pb_content" :style="{padding: gotype ? '0 70px' :''}" style="height: auto; width: calc(100% - 40px); margin: 0 auto;background: unset;box-sizing: border-box;">
         <backPage style="padding: 40px 0 0;" v-if="gotype " tit="智能表单"></backPage>
 
         <div style="width:100%;padding:0;box-sizing: border-box;">
@@ -443,7 +443,7 @@ export default {
     components: { EditorBar, CourseProblem, pie1, pie2, randar1, randar2, shareBox, examine, aggregate,backPage },
     data() {
         return {
-            gotype:sessionStorage.getItem('gotype'),
+            gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
             examineData: [],
             cutNumber: 0,
             itemCount: 1,
@@ -505,6 +505,15 @@ export default {
             typeJArray: [],
             zscore: 0,
 						checkList:[],
+            liYuanOrgList:["3823a6a5-1b6e-11f0-a66a-005056924926",
+						"292e34dc-1b6e-11f0-a66a-005056924926",
+						"21d6b367-1b6e-11f0-a66a-005056924926",
+						"1a1a172d-1b6e-11f0-a66a-005056924926",
+						"1197f86b-1b6e-11f0-a66a-005056924926",
+						"f235659b-1b6d-11f0-a66a-005056924926",
+						"d87b62d3-1b6d-11f0-a66a-005056924926",
+						"c25ea59b-1b6d-11f0-a66a-005056924926",
+          ]
         };
     },
     computed: {
@@ -1199,8 +1208,13 @@ export default {
             let params = {
                 oid: this.oid,
             };
+            let _url = "selectTestType"
+            if(this.liYuanOrgList.includes(this.org)){
+              _url = "selectTestType_liYuan"
+            }
+
             this.ajax
-                .get(this.$store.state.api + "selectTestType", params)
+                .get(this.$store.state.api + _url, params)
                 .then((res) => {
                     this.typeArray = res.data[0];
                     this.getData()
@@ -1390,14 +1404,45 @@ export default {
 				}
     },
     activated() {
-        console.log(1);
-        this.selectAllType();
-        if (this.stype == 1) {
-            this.getCourse();
-        } else if (this.stype == 2) {
-            this.getCourse2();
+        // console.log(1);
+        // this.selectAllType();
+        // if (this.stype == 1) {
+        //     this.getCourse();
+        // } else if (this.stype == 2) {
+        //     this.getCourse2();
+        // }
+        // this.selectTestType();
+    },
+    //切换路由后执行 获取数据
+    beforeRouteEnter(to, from, next) {
+      // console.log("======================")
+      // console.log(to)
+      // console.log(from)
+      // console.log("======================")
+
+      next(vm=>{
+        if(from.path == '/addTest'){
+          vm.selectAllType();
+        if (vm.stype == 1) {
+            vm.getCourse();
+        } else if (vm.stype == 2) {
+            vm.getCourse2();
         }
-        this.selectTestType();
+        vm.selectTestType();
+      }
+      })
+
+      // this.$nextTick(()=>{
+      //   if(from.path == '/addTest'){
+      //   this.selectAllType();
+      //   if (this.stype == 1) {
+      //       this.getCourse();
+      //   } else if (this.stype == 2) {
+      //       this.getCourse2();
+      //   }
+      //   this.selectTestType();
+      // }
+      // })
     },
     mounted() {
         this.getPageBase()

+ 1 - 12
src/components/pages/test/smarter.vue

@@ -40,18 +40,7 @@
                             role
                         )
                         ">数据看板</span>
-                     <span class="subClick" v-if="back=='sass'" @click="
-                        goTo(
-                            '/sassPlatform?userid=' +
-                            userid +
-                            '&oid=' +
-                            oid +
-                            '&org=' +
-                            org +
-                            '&role=' +
-                            role
-                        )
-                        ">sass平台</span>
+                     <span class="subClick" v-if="back=='sass'" @click="$router.back()">sass平台</span>
                     <span class="sub_head">智能助手</span>
                 </div>
                 <!-- <div class="pb_head_t_right">

+ 95 - 29
src/components/pages/testPerson/examine/index.vue

@@ -52,7 +52,7 @@
             </el-option>
           </el-select>
         </div>
-
+        <!-- v-if="allData.type != 2" -->
         <el-button
           v-if="allData.type != 2"
           type="primary"
@@ -60,6 +60,14 @@
           @click="Submit"
           >提交</el-button
         >
+
+        <el-button
+          v-if="allData.type != 2"
+          type="primary"
+          size="mini"
+          @click="saveBtn"
+          >保存</el-button
+        >
       </div>
     </div>
     <div style="flex: 1;overflow: hidden;" class="notes">
@@ -152,18 +160,18 @@
                     <div v-else style="padding-top: 10px;">
                       <!-- {{ k.testid.test }} -->
                       <div
-                        v-for="(item2, index) in k.testid.test"
+                        v-for="(item2) in k.testid.test"
                         :key="item2.courseId"
                         class="orgData"
                       >
                         <div @click="lookPrize(item2.courseId)">
-                          {{ item2.title }}:{{ item2.num }}份
+                          <!-- {{ item2.title }} -->
+                          查看:{{ item2.num }}份
                         </div>
                         <div
-                          style="color: black;"
                           @click="goFillIn(item2.courseId)"
                         >
-                          填写
+                          填写
                         </div>
                       </div>
                     </div>
@@ -180,7 +188,12 @@
           </div>
         </div>
       </div>
+      <div class="brief" v-if="brief">
+      <span v-html="brief" style="white-space: pre-wrap;word-break: break-all;"></span>
     </div>
+    </div>
+
+
 
     <!-- 点击数据来源 -->
     <el-dialog
@@ -242,6 +255,7 @@ export default {
       timeA:"",
       timeB:"",
       testExamineBaseList:[],
+      brief:"",
     };
   },
   watch: {
@@ -256,16 +270,18 @@ export default {
     }
   },
   computed: {},
-  activated() {
-    // 当组件被激活时调用
-    this.getPageBase();
-    this.getPageBase2(1)
-    this.getPageBase2(2)
-  },
+  // activated() {
+  //   // 当组件被激活时调用
+  //   this.getPageBase();
+  //   this.getPageBase2(1)
+  //   this.getPageBase2(2)
+  // },
   mounted() {
-    this.getPageBase();
+    // this.getPageBase();
     this.getPageBase2(1)
     this.getPageBase2(2)
+    console.log('666');
+
     // console.log(JSON.stringify(this.TeaTabJson));
   },
   methods: {
@@ -393,8 +409,6 @@ export default {
         .post(this.$store.state.api + "addTestExamineWorks2", params)
         .then(res => {
           console.log("addTestExamineWorks2", res);
-          // this.getData();
-          // this.handleData();
         })
         .catch(error => {
           console.log(error);
@@ -415,10 +429,12 @@ export default {
       this.ajax
         .get(this.$store.state.api + "getTestExamineByUserId2", params)
         .then(res => {
-          console.log("getTestExamineByUserId", res);
+          // console.log("getTestExamineByUserId", res);
 
           if (res.data[0].length > 0) {
+
             this.allData = res.data[0][0];
+
             let val = JSON.parse(res.data[0][0].json);
 
             this.PageBaseData.forEach(e => {
@@ -446,12 +462,6 @@ export default {
             this.handleData();
             this.tabLoad = false;
           }
-          // this.$forceUpdate();
-          //  else {
-          //   this.allData.type = 1;
-          //   this.getPageBase();
-          //   this.tabLoad = false;
-          // }
         })
         .catch(error => {
           console.log(error);
@@ -471,13 +481,13 @@ export default {
           // console.log("resresresres", res.data[0]);
           // this.allData = res.data[0][0];
           let testExamineBaseList = res.data[0];
+          console.log("res.data[0][0]", res.data[0][0]);
+          this.brief = res.data[0][0].brief;
           this.testExamineBaseList = testExamineBaseList;
           console.log("selectTestExamineBase", res.data[0][0]);
           this.PageBaseData = JSON.parse(res.data[0][0].json);
           // 先获取基础模板,然后再获取用户又没有填写过,填写过就开始循环赋值给基础模板,最后提交基础模板
           this.getData();
-
-          // this.handleData();
         })
         .catch(error => {
           console.log(error);
@@ -527,9 +537,24 @@ export default {
           testId: val.join(",")
         }
       ];
+      let _url = "selectExamineTestName"
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        params[0].startTime = timeValue[0];
+        params[0].endTime = timeValue[1];
+        _url = `selectExamineTestNameFilterTime`
+      }
+      // console.log("this.timeSortList",timeSortList)
+      // if(timeSortList && timeSortList.time && timeSortList.time.length>0){
+      //   const timeValue = timeSortList.time;
+      //   params[0].startTime = timeValue[0];
+      //   params[0].endTime = timeValue[1];
+      //   _fnStr = `selectExamineTestNameFilterTime`
+      // }
+
       return new Promise(resolve => {
         this.ajax
-          .post(this.$store.state.api + "selectExamineTestName", params)
+          .post(this.$store.state.api + _url, params)
           .then(res => {
             resolve(res.data[0]);
           })
@@ -541,7 +566,13 @@ export default {
     // 查看数据来源
     lookPrize(val) {
       // return;
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}`;
+
+      if(this.testExamineBaseList[0].value){
+        const timeValue = JSON.parse(this.testExamineBaseList[0].value).time;
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}&timeLimit=${timeValue}`;
+      }else{
+        this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0&peopleId=${this.userid}&tType=${this.pType}&examineId=${this.testExamineBaseList[0].id}`;
+      }
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },
@@ -549,6 +580,41 @@ export default {
     handleClose(done) {
       this.getPageBase();
       done();
+    },
+    //保存按钮
+    saveBtn(){
+      this.$forceUpdate();
+      let PageBaseDataCopy = JSON.parse(JSON.stringify(this.PageBaseData));
+
+      for (const e of PageBaseDataCopy) {
+        for (const k of e.children) {
+          if (k.testid.test.length > 0) {
+            k.testid.test = k.testid.test.map(item => item.courseId);
+          }
+        }
+      }
+
+      let params = [
+        {
+          uid: this.userid,
+          oid: this.oid,
+          org: this.org,
+          type: this.pType,
+          json: JSON.stringify(PageBaseDataCopy),
+          ttype: 1,
+          tid:this.testExamineBaseList[0].id
+        }
+      ];
+      // return console.log(params);
+      this.ajax
+        .post(this.$store.state.api + "addTestExamineWorks2", params)
+        .then(res => {
+          console.log("addTestExamineWorks2", res);
+          this.$message.success("保存成功")
+        })
+        .catch(error => {
+          console.log(error);
+        });
     }
   }
 };
@@ -569,10 +635,10 @@ export default {
 	margin: 10px 0;
 	border-radius: 5px;
 }
-.tArea {
+/* .tArea { */
   /* box-sizing: border-box; */
   /* padding: 5px; */
-}
+/* } */
 .tArea > div > textarea {
   border: none;
   width: 100%;
@@ -675,9 +741,9 @@ export default {
   width: 100%;
   min-width: 1300px;
   margin: 0 auto;
-  height: 100%;
+  height: auto;
   box-sizing: border-box;
-  padding-bottom: 60px;
+  padding-bottom: 10px;
   font-size: 14px;
 }
 

+ 1 - 1
src/components/pages/testPerson/info/index.vue

@@ -134,7 +134,7 @@
 
 <script>
 import avator from "../../../../assets/icon/test/teacher.jpg";
-import infoDialog from "./infoDialog/index.vue";
+import infoDialog from "./infoDialognew/index.vue";
 export default {
   components: {
     infoDialog

+ 936 - 0
src/components/pages/testPerson/info/infoDialognew/index.vue

@@ -0,0 +1,936 @@
+<template>
+	<div>
+		<el-dialog
+			title="编辑个人信息"
+			:visible.sync="dialogVisibleInfo"
+			:append-to-body="true"
+			width="500px"
+			:before-close="handleClose"
+			class="dialog_diy"
+			:close-on-click-modal="false"
+			:close-on-press-escape="false"
+		>
+			<div style="width: 100%; height: 100%" v-loading="digLoading">
+				<div class="info_box">
+					<div class="img" v-loading="imgLoading">
+						<img :src="info.headportrait ? info.headportrait : avator" alt="" />
+						<div v-if="info.type == 1" class="mask" @click.stop="addImg($event)">
+							<img src="../../../../../assets/icon/test/camera_icon.png" alt="" />
+							<input
+								type="file"
+								accept="image/*"
+								capture="camera"
+								style="display: none"
+								@change="beforeUpload($event)"
+							/>
+						</div>
+					</div>
+					<div class="infoBar">
+						<span
+							:style="{ color: pageCut == 0 ? '#67B1FF' : '' }"
+							@click="midInfo(0)"
+							>我的资料</span
+						>
+						<span
+							:style="{ color: pageCut == 1 ? '#67B1FF' : '' }"
+							@click="midInfo(1)"
+							v-if="info.type == 1"
+							>修改密码</span
+						>
+					</div>
+					<div class="info_box" style="padding: 0" v-if="pageCut == 0">
+						<div class="info_span">
+							<span>姓名:</span>
+							<el-input
+								v-model="info.username"
+								placeholder="请输入姓名"
+							></el-input>
+						</div>					
+
+						<div class="info_span">
+							<span>性别:</span>
+							<el-radio-group v-model="info.sex">
+								<el-radio :label="0">男</el-radio>
+								<el-radio :label="1">女</el-radio>
+							</el-radio-group>
+						</div>
+                        <div
+                            class="info_span"
+                            v-for="item in teaType"
+                            :key="item.id"
+                            :class="{
+                                'error-text': !item.value.length,
+                                'error-border': !item.value.length,
+                            }"
+                        >
+                            <span>
+                                {{ item.name + ":" }}
+                            </span>
+                            <el-select
+                                v-model="item.value"
+                                multiple
+                                :placeholder="'请选择' + item.name"
+                                @change="Ochange"
+                            >
+                                <el-option
+                                    v-for="i in item.child"
+                                    :key="i.id"
+                                    :label="i.name"
+                                    :value="i.id"
+                                >
+                                </el-option>
+                            </el-select>
+                        </div>
+
+						
+
+						<div class="info_span">
+							<span>微信登录:</span>
+							<el-button
+								type="danger"
+								size="small"
+								@click="wxLogin"
+								v-if="info.thirdpartyid"
+								>取消绑定</el-button
+							>
+							<el-button type="primary" size="small" @click="wxLogin" v-else
+								>绑定微信</el-button
+							>
+						</div>
+						<span
+							v-if="pageCut == 0 && info.type == 1"
+							slot="footer"
+							class="dialog-footer"
+							style="width: 90%; display: flex; justify-content: flex-end"
+						>
+							<el-button type="primary" @click="confirm()">确 认</el-button>
+							<el-button @click="close()">关 闭</el-button>
+						</span>
+						<!-- <div class="info_span">
+							<span>简介:</span>
+							<textarea
+								v-autoHeight="68"
+								rows="2"
+								class="binfo_input binfo_textarea"
+								cols
+								v-model="info.intro"
+								placeholder="想说点什么..."
+							></textarea>
+						</div> -->
+					</div>
+					<div v-else>
+						<div class="input_box">
+							<span>原密码</span>
+							<el-input
+								class="input"
+								v-model="opassword"
+								placeholder="请输入原密码"
+							></el-input>
+						</div>
+						<div class="input_box">
+							<span>输入新密码</span>
+							<div style="position: relative">
+								<el-input
+									:type="isLook ? 'type' : 'password'"
+									class="input"
+									v-model="password"
+									placeholder="长度为8-16位,且包含大小写字母"
+								></el-input>
+								<div class="eye" @click="changeEye">
+									<img :src="isLook ? eye : eyeOff" alt="" />
+								</div>
+							</div>
+						</div>
+						<div class="input_box"> 
+							<span>再次输入新密码</span>
+							<div style="position: relative">
+								<el-input
+									:type="isLook ? 'type' : 'password'"
+									class="input"
+									v-model="password1"
+									placeholder="请再次输入修改密码"
+								></el-input>
+								<div class="eye" @click="changeEye">
+									<img :src="isLook ? eye : eyeOff" alt="" />
+								</div>
+							</div>
+						</div>
+						<div class="input_box">
+							<div
+								style="width: 100%; display: flex; justify-content: flex-end"
+							>
+								<el-button type="primary" @click="updatePassword"
+									>保存</el-button
+								>
+							</div>
+						</div>
+					</div>
+				</div>
+			</div>
+		</el-dialog>
+		<el-dialog
+			title="绑定微信"
+			:visible.sync="wechatDialogVisible"
+			:append-to-body="true"
+			width="400px"
+			:before-close="handleClose2"
+			class="dialog_diy"
+		>
+			<div class="fa_weChat">
+				<div id="QRcode" class="QRcode" ref="QRcode"></div>
+			</div>
+			<span slot="footer" class="dialog-footer">
+				<el-button @click="wechatDialogVisible = false">关 闭</el-button>
+			</span>
+		</el-dialog>
+	</div>
+</template>
+
+<script>
+import avator from '../../../../../assets/icon/test/teacher.jpg'
+
+import "@/common/wxLogin.js";
+
+export default {
+	props: {
+    dialogVisibleInfo: {
+		type: Boolean,
+			default: false
+		},
+		userid: {
+			type: String
+		},
+		oid: {
+			type: String
+		}
+	},
+	watch: {
+		dialogVisibleInfo(newVal) {
+			if (newVal) {
+				this.getTypeInfo();
+				this.monitorWechat()
+			}else{
+				if (this.messageHandler) {
+					window.removeEventListener("message", this.messageHandler);	
+				}
+			}
+		},
+	},
+	directives: {
+		autoHeight: {
+			update(el, binding) {
+				const { value } = binding;
+				if (value && typeof value === "number") {
+					el.style.height = `${value}px`;
+				} else {
+					el.style.height = "auto";
+				}
+			},
+			componentUpdated(el) {
+				el.style.height = `${el.scrollHeight + 5}px`;
+			},
+		},
+	},
+	data() {
+		return {
+			messageHandler:'',
+			avator: avator,
+			info: {},
+			imgLoading: false,
+			classJuri: [],
+			teaType: [],
+			teacherType: [],
+			allItems: [],
+			options: [],
+			typeId: "",
+			typeId2: "",
+			formLabelWidth: "100px",
+			oidArray: ["d67940a5-510c-40ea-9c9a-2631ab03013a"],
+			resultInfo: "", // 用于存储字符串
+			isClosed: false,
+			digLoading: false,
+			pageCut: 0, //0修改信息也 1修改密码页
+			wechatDialogVisible: false, //微信登录弹框
+			isLook: false, //密码眼睛
+			opassword: "",
+			password: "",
+			password1: "",
+            eyeOff: require("../../../../../assets/icon/eyeOff.png"),
+            eye: require("../../../../../assets/icon/eye.png"),
+		};
+	},
+	methods: {
+		cha() {
+			this.$forceUpdate();
+		},
+		updatePassword() {
+			const reg = /^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[A-Za-z\d]{8,16}$/;
+			if (!reg.test(this.password)) {
+				this.$message.error("密码长度为8-16位,且包含大小写字母");
+				return;
+			} else if (this.password != this.password1) {
+				this.$message.error("两次新密码不相同");
+				return;
+			}
+
+            let params = [
+                {
+                userid: this.userid,
+                opassword: this.opassword,
+                password: this.password,
+                },
+            ];
+            this.ajax
+                .post(this.$store.state.api + "updatePassword", params)
+				.then((res) => {
+					if (res.data[0] && res.data[0].success == 1) {
+						this.$message.success("修改成功");
+						this.opassword = "";
+						this.password = "";
+						this.password1 = "";
+					} else {
+						this.$message.error("修改失败,原密码不正确");
+					}
+				})
+				.catch((err) => {
+					this.$message.error("修改失败");
+					console.error(err);
+				});
+		},
+		// 密码展示与隐藏开关
+		changeEye() {
+			this.isLook = !this.isLook;
+		},
+		//切换弹框
+		midInfo(type) {
+			if (type == 0) {
+				this.pageCut = 0;
+			} else {
+				this.pageCut = 1;
+			}
+		},
+		//获取分类类名
+		getTypeInfo() {
+			this.digLoading = true;
+
+            let params = {
+                oid: this.oid
+            };
+            this.ajax
+                .get(this.$store.state.api + "selectPerInfoAllTea", params)
+				.then((res) => {
+					this.teaType = res.data[0];
+					let typeInfo = res.data[1];
+
+					this.teaType.forEach((e) => {
+						e.child = [];
+						e.value = [];
+						typeInfo.forEach((i) => {
+							if (e.id == i.parentid) {
+								e.child.push({ id: i.id, name: i.name });
+							}
+						});
+					});
+					// console.log(this.teaType, "teaType");
+					this.options = res.data[2];
+					this.getData();
+				})
+				.catch((err) => {
+					this.digLoading = false;
+					console.error(err);
+				});
+		},
+		handleClose2(done) {
+			done();
+		},
+		handleClose(done) {
+			this.typeId = "";
+			this.close();
+			done();
+		},
+		close() {
+			this.typeId = "";
+			// this.dialogVisibleInfo = false;
+			this.$emit("update:dialogVisibleInfo", false);
+		},
+		generateResultInfo() {
+			// 从 teaType 中提取所有的值
+			const selectedValues = this.teaType.flatMap((item) => item.value);
+
+			// 确保 typeId 是数组,将其添加到 selectedValues 中
+			const combinedValues = Array.isArray(this.info.teacherOffice)
+				? selectedValues.concat(this.info.teacherOffice)
+				: selectedValues.concat([this.info.teacherOffice]);
+
+			// 将合并后的数组转换为逗号分隔的字符串
+			this.resultInfo = combinedValues.join(",");
+		},
+		confirm() {
+			if (!this.panData()) {
+				this.$message.error("请完善教研室分类信息");
+				return;
+			}
+			if (!this.info.username) {
+				this.$message.error("姓名不能为空!");
+				return;
+			}
+			// let teaTypeSelections = this.teaType.map(item => ({
+			//   selectedValues: item.value.join(",")  // 如果是数组,转为逗号分隔的字符串
+			// }));
+			this.generateResultInfo();
+
+
+             let params = [{
+                userid: this.userid,
+                username: this.info.username,
+                sex: this.info.sex,
+                cclassid: this.resultInfo,
+                h: this.info.headportrait ? this.info.headportrait : "",
+            }];
+            console.log(params);
+
+            this.ajax
+                .post(this.$store.state.api + "updateliyuanUserInfo", params)
+				.then(() => {
+					this.$message.success("修改成功");
+					this.$emit("update:dialogVisibleInfo", false);
+
+				})
+				.catch((err) => {
+					this.$message.error("网络不佳");
+					this.$emit("update:dialogVisibleInfo", false);
+					console.error(err);
+				});
+		},
+		async getData() {
+			this.digLoading = true;
+			// let params = [
+			// 	{
+			// 		functionName: API_CONFIG.ajax_selectliyuanUserInfo.functionName, // 调用存储过程的名称
+			// 		uid: this.userid,
+			// 	},
+			// ];
+
+			// this.$ajax
+			// 	.post(API_CONFIG.baseUrl, params)
+
+            let params = { uid: this.userid };
+            this.ajax
+                .get(this.$store.state.api + "selectliyuanUserInfo", params)
+				.then((res) => {
+					this.info = res.data[0][0];
+					this.info.teacherOffice = [];
+					let array = [];
+					for (var i = 0; i < this.options.length; i++) {
+						array.push(this.options[i].id);
+					}
+					this.info.teacherOffice = this.arrayToArray(
+						this.info.cclassid.split(","),
+						array
+					);
+					// console.log(this.info.cclassid);
+					let count = 0;
+					this.teaType.forEach((e) => {
+						let array2 = [];
+						for (var i = 0; i < e.child.length; i++) {
+							array2.push(e.child[i].id);
+						}
+						e.value = this.arrayToArray(this.info.cclassid.split(","), array2);
+						if (e.value.length) {
+							count++;
+						}
+					});
+					if (count != this.teaType.length) {
+						this.$emit("update:dialogVisibleInfo", true);
+					}
+					if (!this.panData()) {
+						this.isClosed = false;
+					} else {
+						this.isClosed = true;
+					}
+					this.digLoading = false;
+
+					this.$forceUpdate();
+				})
+				.catch((err) => {
+					this.digLoading = false;
+
+					console.error(err);
+				});
+		},
+		panData() {
+			let count = 0;
+			this.teaType.forEach((e) => {
+				if (e.value.length) {
+					count++;
+				}
+			});
+			return count == this.teaType.length;
+		},
+		arrayToArray(arrayo, arrayt) {
+			let array1 = arrayo;
+			let array2 = arrayt;
+
+			let commonElements = [];
+
+			for (let i = 0; i < array1.length; i++) {
+				for (let j = 0; j < array2.length; j++) {
+					if (array1[i] === array2[j]) {
+						commonElements.push(array1[i]);
+					}
+				}
+			}
+			return commonElements;
+		},
+		addImg(e) {
+			var el = e.currentTarget;
+			el.getElementsByTagName("input")[0].click();
+			e.target.value = "";
+		},
+		beforeUpload(event) {
+			// const loading = this.openLoading();
+			var file = event.target.files[0];
+			var credentials = {
+				accessKeyId: "AKIATLPEDU37QV5CHLMH",
+				secretAccessKey: "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",
+			}; //秘钥形式的登录上传
+			window.AWS.config.update(credentials);
+			window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+			var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+			var imgA = [
+				"png",
+				"jpg",
+				"jpeg",
+				"bmp",
+				"gif",
+				"webp",
+				"psd",
+				"svg",
+				"tiff",
+			];
+			if (
+				imgA.indexOf(file.name.split(".")[file.name.split(".").length - 1]) ==
+				-1
+			) {
+				this.$message.error("图片格式错误");
+				return;
+			}
+			this.imgLoading = true;
+			var _this = this;
+
+			if (file) {
+				var params = {
+					Key:
+						file.name.split(".")[0] +
+						new Date().getTime() +
+						"." +
+						file.name.split(".")[file.name.split(".").length - 1],
+					ContentType: file.type,
+					Body: file,
+					"Access-Control-Allow-Credentials": "*",
+					ACL: "public-read",
+				}; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+				var options = {
+					partSize: 2048 * 1024 * 1024,
+					queueSize: 2,
+					leavePartsOnError: true,
+				};
+				bucket
+					.upload(params, options)
+					.on("httpUploadProgress", function () {
+						//这里可以写进度条
+						// console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+					})
+					.send(function (err, data) {
+						_this.imgLoading = false;
+						// loading.close();
+						if (err) {
+							_this.$message.error("上传失败");
+						} else {
+							_this.info.headportrait = data.Location;
+							_this.$forceUpdate();
+
+							console.log(_this.checkJson);
+							console.log(data.Location);
+						}
+					});
+			}
+		},
+		wxLogin() {
+			if (this.info.thirdpartyid) {
+				this.$confirm("确定取消绑定微信吗?", "提示", {
+					confirmButtonText: "确定",
+					cancelButtonText: "取消",
+					type: "warning",
+				})
+					.then(() => {
+						 this.ajax.post(this.$store.state.api + "UpdateOpenId", [
+                                { userid: this.userid, openid: '' },
+                            ]).then((res) => {
+								this.$message.success("取消绑定成功");
+								this.getData();
+							})
+							.catch((err) => {
+								this.$message.error("取消绑定失败");
+								console.error(err);
+							});
+					})
+					.catch(() => {});
+			} else {
+				this.wechatDialogVisible = true;
+				this.wechatLogin();
+			}
+		},
+		wechatLogin() {
+			setTimeout(() => {
+				const randomState = Math.random().toString(36).substring(2); // 生成随机状态
+				// eslint-disable-next-line no-undef
+				new WxLogin({
+					self_redirect: true,
+					id: "QRcode",
+					appid: "wxe9d7fff3c659445f",
+					scope: "snsapi_login",
+					redirect_uri: encodeURIComponent("https://cocorobo.cn/weixin.html"), //https://liyuan.cocorobo.cn/#/wxTest
+					state: randomState,
+					style: "black",
+					href: "data:text/css;base64,LmltcG93ZXJCb3gge2Rpc3BsYXk6IGZsZXg7fQouaW1wb3dlckJveCAucXJjb2RlIHt3aWR0aDogMjMycHg7IGhlaWdodDogMjMycHh9Ci5pbXBvd2VyQm94IC50aXRsZSB7ZGlzcGxheTogbm9uZTt9Ci5pbXBvd2VyQm94IC5pbmZvIHtkaXNwbGF5OiBub25lO30KLmxvZ2luUGFuZWx7d2lkdGg6MTAwJTtoZWlnaHQ6MTAwJTtkaXNwbGF5OmZsZXg7ZmxleC1kaXJlY3Rpb246Y29sdW1uO2FsaWduLWl0ZW1zOmNlbnRlcjtqdXN0aWZ5LWNvbnRlbnQ6Y2VudGVyO30KLnN0YXR1c19pY29uIHtkaXNwbGF5OiBub25lfQoud2ViX3FyY29kZV9wYW5lbF9hcmVhe2hlaWdodDoxMDAlO3dpZHRoOjEwMCU7ZGlzcGxheTpmbGV4O2FsaWduLWl0ZW1zOmNlbnRlcjtqdXN0aWZ5LWNvbnRlbnQ6Y2VudGVyO30K",
+					onReady: function (isReady) {
+						console.log(isReady);
+					},
+				});
+				setTimeout(() => {
+					let iframe = this.$refs.QRcode.querySelector("iframe");
+					iframe.style.width = "100%";
+					iframe.style.height = "100%";
+				}, 0);
+			}, 0);
+		},
+		monitorWechat(){
+			let _this = this;
+			this.messageHandler = function (e) {
+				// 监听 message 事件
+				console.log("userinfoA", e);
+				if (e.data && e.data.method == "getOpenId") {
+					console.log(e);
+					console.log(e.data.code);
+					console.log(_this.loginType);
+
+					if (e.data.code == 200) {
+						_this.setOpenId(e.data.data.openid);
+					} else {
+						_this.$message.error("扫码登录失败请重新扫码");
+						_this.wechatDialogVisible = false;
+						setTimeout(() => {
+							_this.wechatDialogVisible = true;
+							_this.wechatLogin();
+						}, 1000);
+					}
+				}
+			};
+
+			window.addEventListener("message", this.messageHandler);
+		},
+		addOpenid(openid) {
+			this.ajax.post(this.$store.state.api + "UpdateOpenId", [
+					{ userid: this.userid, openid: openid },
+				]).then((res) => {
+					this.$message.success("绑定成功");
+					this.wechatDialogVisible = false;
+					this.getData();
+				})
+				.catch((err) => {
+					this.$message.error("绑定失败请重新扫码");
+					console.error(err);
+				});
+		},
+		setOpenId(openid) {
+			this.ajax
+			.post(this.$store.state.api + "selectliyuanOpenid", [
+				{ pid: openid },
+			])
+			.then((res) => {
+				if (!res.data[0].length) {
+					this.addOpenid(openid);
+				} else {
+					let uname = res.data[0].map(item => item.username).join(',');
+					console.log('uname',uname);
+					
+					this.$message.error("该微信已绑定" + uname + "账号");
+					this.wechatDialogVisible = false;
+				}
+			})
+			.catch((err) => {
+				console.log("err", err);
+			});
+
+		// this.ajax.post(this.$store.state.api + "UpdateOpenId", [
+		//   { userid: this.userid, openid: openid },
+		// ]).then((res) => {
+		//   this.$message.success("绑定成功");
+		//   this.wechatDialogVisible = false;
+		//   this.getDetail();
+		// }).catch((err) => {
+		//   this.$message.error("绑定失败请重新扫码");
+		//   console.error(err);
+		// })
+		},
+		Ochange() {
+			this.$forceUpdate();
+		},
+	},
+	
+	mounted() {
+		this.$nextTick();
+		this.getTypeInfo();
+
+		// let _this = this;
+		// window.addEventListener("message", function (e) {
+		// 	// 监听 message 事件
+		// 	console.log(e);
+		// 	if (e.data && e.data.method == "getOpenId") {
+		// 		console.log(e);
+		// 		console.log(e.data.code);
+		// 		console.log(_this.loginType);
+
+		// 		if (e.data.code == 200) {
+		// 			_this.setOpenId(e.data.data.openid);
+		// 		} else {
+		// 			_this.$message.error("扫码登录失败请重新扫码");
+		// 			_this.wechatDialogVisible = false;
+		// 			setTimeout(() => {
+		// 				_this.wechatDialogVisible = true;
+		// 				_this.wechatLogin();
+		// 			}, 1000);
+		// 		}
+		// 	}
+		// });
+	},
+};
+</script>
+
+<style scoped>
+.dialog_diy >>> .el-dialog {
+	/* height: 100%; */
+	margin: 10vh auto !important;
+}
+
+.dialog_diy >>> .el-dialog__header {
+	background: #454545 !important;
+	padding: 15px 20px;
+}
+
+.dialog_diy >>> .el-dialog__body {
+	height: calc(100% - 124px);
+	box-sizing: border-box;
+	padding: 0px;
+}
+
+.dialog_diy >>> .el-dialog__title {
+	color: #fff;
+}
+
+.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;
+}
+
+.dialog_diy >>> .el-dialog__body,
+.dialog_diy >>> .el-dialog__footer {
+	background: #fafafa;
+}
+
+.info_box {
+	width: 100%;
+	display: flex;
+	flex-direction: column;
+	align-items: center;
+	padding: 30px 0;
+}
+
+.info_box > .img {
+	width: 80px;
+	height: 80px;
+	overflow: hidden;
+	border-radius: 50%;
+	position: relative;
+}
+
+.info_box > .img:hover > .mask {
+	display: flex;
+}
+
+.info_box > .img > .mask {
+	cursor: pointer;
+	position: absolute;
+	top: 0;
+	left: 0;
+	width: 100%;
+	height: 100%;
+	background: rgba(0, 0, 0, 0.5);
+	/* display: flex; */
+	align-items: center;
+	justify-content: center;
+	display: none;
+}
+
+.info_box > .img > .mask > img {
+	width: 20px;
+}
+
+.info_box > .img > img {
+	width: 100%;
+	height: 100%;
+	object-fit: cover;
+}
+
+.binfo_input {
+	width: 100%;
+	margin: 0;
+	padding: 12px 14px;
+	display: block;
+	min-width: 0;
+	outline: none;
+	box-sizing: border-box;
+	background: none;
+	border: none;
+	border-radius: 4px;
+	background: #fff;
+	font-size: 16px;
+	resize: none;
+	font-family: "Microsoft YaHei";
+	min-height: 48px;
+	/* border: 1px solid #3682fc00; */
+	border: 1px solid #c0c4cc;
+}
+
+.binfo_textarea {
+	border: 1px solid #c0c4cc;
+	font-size: 16px;
+	resize: none;
+	/* background: #f6f6f6; */
+	font-family: "Microsoft YaHei";
+	font-size: 14px;
+	color: #606266;
+}
+
+.binfo_input:focus-visible {
+	border: 1px solid #3681fc !important;
+}
+
+.binfo_textarea::-webkit-input-placeholder {
+	/* WebKit browsers */
+	color: rgb(192, 196, 204);
+}
+
+.binfo_textarea:-moz-placeholder {
+	/* Mozilla Firefox 4 to 18 */
+	color: rgb(192, 196, 204);
+}
+
+.binfo_textarea::-moz-placeholder {
+	/* Mozilla Firefox 19+ */
+	color: rgb(192, 196, 204);
+}
+
+.binfo_textarea:-ms-input-placeholder {
+	/* Internet Explorer 10+ */
+	color: rgb(192, 196, 204);
+}
+.el-form-item__label {
+	margin-left: -14px;
+}
+.elInput {
+	margin-left: 10px;
+}
+
+.info_span {
+	display: flex;
+	margin-top: 10px;
+	width: 350px;
+	align-items: center;
+}
+
+.info_span > span:nth-child(1) {
+	width: 100px;
+	min-width: 100px;
+	text-align: right;
+	line-height: 40px;
+}
+
+.info_span > div {
+	width: 250px;
+}
+
+.error-border >>> .el-input__inner {
+	border: 1px solid red; /* 红色边框 */
+}
+
+.error-text {
+	color: red; /* 红色文字 */
+}
+.infoBar {
+	width: 100%;
+	display: flex;
+	justify-content: center;
+	gap: 20px;
+	margin: 10px 0;
+}
+.infoBar span {
+	cursor: pointer;
+}
+.fa_weChat {
+	width: 300px;
+	height: 300px;
+	margin: 0 auto;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+}
+
+.fa_weChat > .QRcode {
+	width: 100%;
+	height: 100%;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	/* background-color: black; */
+}
+.input_box {
+	display: flex;
+	align-items: center;
+	justify-content: center;
+}
+.input_box span {
+	width: 100px;
+	font-size: 14px;
+	text-align: right;
+	padding: 0 12px 0 0;
+}
+.input_box .input {
+	width: 300px;
+}
+.input_box + .input_box {
+	margin-top: 20px;
+}
+.eye {
+	position: absolute;
+	right: 10px;
+	top: 8px;
+	width: 25px;
+	height: 25px;
+	cursor: pointer;
+}
+
+.eye > img {
+	width: 100%;
+	height: 100%;
+}
+</style>

+ 18 - 3
src/components/pages/testPerson/test/index.vue

@@ -274,6 +274,15 @@ export default {
       navIndex:'0-5',
       showCard:'portraitOfTeacher',
       showFormId:"",
+      liYuanOrgList:["3823a6a5-1b6e-11f0-a66a-005056924926",
+				"292e34dc-1b6e-11f0-a66a-005056924926",
+				"21d6b367-1b6e-11f0-a66a-005056924926",
+				"1a1a172d-1b6e-11f0-a66a-005056924926",
+				"1197f86b-1b6e-11f0-a66a-005056924926",
+				"f235659b-1b6d-11f0-a66a-005056924926",
+				"d87b62d3-1b6d-11f0-a66a-005056924926",
+				"c25ea59b-1b6d-11f0-a66a-005056924926",
+      ]
     };
   },
   computed: {
@@ -611,11 +620,17 @@ export default {
       let params = {
         oid: "",//this.oid
       };
+
+      let _url = "selectTestType"
+      if(this.liYuanOrgList.includes(this.org)){
+        _url = "selectTestType_liYuan"
+      }
+
       this.ajax
-        .get(this.$store.state.api + "selectTestType", params)
+        .get(this.$store.state.api + _url, params)
         .then(res => {
           let _data = res.data[0];
-          let _type1 = _data.filter(i => i.pid == "");
+          let _type1 = _data.filter(i => !i.pid);
           _type1.forEach((i,index) => {
             let _typeList = [];
             _typeList = _data.filter(i2 => i2.pid == i.id);
@@ -623,7 +638,7 @@ export default {
             let _children = [{name:"资料提交",type:"formSubmit",typeId:i.id,navIndex:`${index}-0`}]
             i.open = false;
 
-            if(i.id=='e18d88b3-e828-11ef-b508-005056924926'){
+            if(i.id=='e18d88b3-e828-11ef-b508-005056924926' || i.id == "4cdce114-8a00-11f0-9c7b-005056924926"){
               _children.push(...[
                 {name:"年度考核",type:"annualAssessment",navIndex:`${index}-1`},
                 {name:"培训活动",type:"trainingActivity",navIndex:`${index}-2`},

+ 66 - 6
src/components/pages/testPerson/test/test.vue

@@ -36,7 +36,10 @@
                         </el-tooltip>
                     </div>
                     <div class="state">
-                        <span :class="{ is: item.array.length > 0, no: !item.array.length }">{{ item.array.length > 0 ? "已完成" : "未完成" }}</span>
+                        <span :class="{ is: isOK(item.array) == '已完成', no: isOK(item.array) == '待办' }">
+                            {{ isOK(item.array) }}
+                            <!-- {{ item.array.length > 0 ? "已完成" : "未完成" }} -->
+                        </span>
                     </div>
                     <div class="time">
                         <span v-if="item.overtime" :class="{isDead: isDeadlinePassed(item.overtime)}">截止时间:{{ item.overtime }}</span>
@@ -65,20 +68,23 @@
                                 <span v-if="!test.editName && test.name">{{test.name}}</span>
                                 <el-input :ref="`changeName_${test.id}`" v-if="test.editName" v-model="test.name"  @blur="changeNameUpdate(test.courseid,test.id)" @keyup.enter.native="changeNameUpdate(test.courseid,test.id)"></el-input>
                             </div>
+                            <div class="testType">
+                              <span :class="`typeStatus_${test.type}`">{{ typeStatusList[test.type] }}</span>
+                            </div>
                             <!-- <img @click="deleteTest(test.id)" class="delete"
                                 src="../../../../assets/icon/test/delete.png" alt="" /> -->
                             <div class="utime">
                                 <span>{{ test.utime }}</span>
                             </div>
                             <div class="mask">
-                                <div @click="doTest(test.courseid, test.id)">
+                                <div @click="doTest(test.courseid, test.id)"  v-if="test.isReview != 1">
                                     <span>编辑</span>
                                 </div>
-                                <div @click="deleteTest(test.id)" class="delete">
+                                <div @click="deleteTest(test.id)" class="delete"  v-if="test.isReview != 1">
                                     <span>删除</span>
                                 </div>
 
-                                <div @click="changeName(test.courseid,test.id)">
+                                <div @click="changeName(test.courseid,test.id)"  v-if="test.isReview != 1">
                                     <span>重命名</span>
                                 </div>
                                 <!-- <div @click="checkTest(test.courseid, test.id)">
@@ -158,10 +164,30 @@ export default {
             org: this.$route.query.org,
             role: this.$route.query.role,
             loading: false,
-            checkTypeValue:""
+            checkTypeValue:"",
+            typeStatusList:["","未提交","已提交","","已退回"]
         };
     },
     computed: {
+        isOK(){
+            return function (array) {
+                // console.log('array',array);
+                let result = ''
+                if (array.length > 0) {
+                    let k = array.filter(e => e.type == 1 || e.type == 4)
+                   if (k.length) {
+                        result = '待办'
+                   }else{
+                        result = '已完成'
+                   }
+
+                }else{
+                    result = '待办'
+                }
+
+                return result;
+            };
+        },
         getNum() {
             return function (array) {
                 let _array = JSON.parse(array);
@@ -1129,7 +1155,7 @@ export default {
     font-size: 14px;
     width: 160px;
     min-width: 160px;
-    margin: 0 30px 0 auto;
+    margin: 0 30px 0 0;
 }
 .test_add_box>.test>.mask {
     display: flex;
@@ -1226,4 +1252,38 @@ export default {
 .isDead{
     color:#EE3E3E;
 }
+
+.testType{
+  width: 60px;
+  margin: 0 45px 0 auto;
+}
+
+.testType>span{
+  padding: 6px 10px;
+  border-radius: 4px;
+  border: solid 1px gray;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  font-size: 12px;
+}
+
+
+.testType>.typeStatus_2{
+  background:#F0F9F2;
+  border-color: #B5E3BF;
+  color:#5FC875;
+}
+
+.testType>.typeStatus_4{
+  background:#FEF5EC;
+  border-color: #FAD0A1;
+  color:#F7933B;
+}
+
+.testType>.typeStatus_1{
+  background:#EEF3FC;
+  border-color: #0F40F5;
+  color:#0F40F5;
+}
 </style>

+ 110 - 24
src/components/pages/testStudent/view/preview.vue

@@ -2,9 +2,13 @@
   <div class="pb_content" style="background: #F0F2F5;" v-loading="loading || isloading">
     <div class="pb_content_body" style="position: relative; margin: 0">
       <div class="right">
-        <div class="courseTop" :style="`justify-content: ${isN==1?'flex-end':'space-between'};`">
-          <div class="stepsNav" v-if="isN !=1">
-            <el-breadcrumb v-if="!gotype" separator-class="el-icon-arrow-right">
+        <div class="courseTop2" v-if="gotype">
+          <div class="r_pub_button_retrun"  @click="retrunCourse">返回</div>
+        </div>
+          
+        <div class="courseTop" v-else :style="`justify-content: ${isN==1?'flex-end':'space-between'};`">
+          <div class="stepsNav" v-if="isN !=1 && !gotype">
+            <el-breadcrumb v-if="!gotype && back!=1" separator-class="el-icon-arrow-right">
               <el-breadcrumb-item :to="{
     path:
       '/testPerson?userid=' +
@@ -15,7 +19,7 @@
       org +
       '&role=' +
       role,
-  }" v-if="type == 3 && back!=1">个人中心</el-breadcrumb-item>
+                }" v-if="type == 3">个人中心</el-breadcrumb-item>
               <el-breadcrumb-item :to="{
     path:
       '/testStudent?userid=' +
@@ -30,7 +34,7 @@
       isN +
       '&tcid=' +
       tcid ,
-  }" v-else v-show="back!=1">表单中心</el-breadcrumb-item>
+                }" v-else v-show="back!=1">表单中心</el-breadcrumb-item>
               <el-breadcrumb-item>
                 <span style="color: rgb(15, 126, 255)">{{ title }}</span>
               </el-breadcrumb-item>
@@ -45,7 +49,7 @@
 							<!-- <el-button type="primary" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="autoFill" v-if="(showAutoFillBtn && isN!=1)">智能填写</el-button> -->
               <el-button type="primary" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="refresh" v-if="isReset">刷新</el-button>
               <el-button :type="isN!=1?'primary':'info'" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="reset">重置</el-button>
-              <el-button type="primary" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="save" v-if="(type != 3 && isN!=1)">保存</el-button>
+              <el-button type="primary" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="save" v-if="isN!=1 && workType!=4">保存</el-button>
               <el-button type="primary" :style=" isN==1? 'padding: 5px 10px;' : ''" size="small" @click="publish">提交</el-button>
             </div>
           </div>
@@ -65,7 +69,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       userid: this.$route.query.userid,
       oid: this.$route.query.oid,
       org: this.$route.query.org,
@@ -89,7 +93,8 @@ export default {
       isloading: false,
       courseid: '',
       gcourseid: this.$route.query.courseid,
-      back:this.$route.query.back
+      back:this.$route.query.back,
+      workType:''
     }
   },
 	computed:{
@@ -243,6 +248,7 @@ export default {
         .then((res) => {
           // this.cJson = JSON.parse(res.data[0][0].chapters);
           if (res.data[2].length) {
+            this.workType = res.data[2][0].type;
             this.cJson = JSON.parse(res.data[2][0].courseJson)
 
             this.$forceUpdate()
@@ -519,20 +525,50 @@ export default {
         .post(this.$store.state.api + "addTestWorks", params)
         .then((res) => {
           this.$message.success('保存成功')
-          this.goTo(
-            "/testStudent?userid=" +
-            this.userid +
-            "&oid=" +
-            this.oid +
-            "&org=" +
-            this.org +
-            "&role=" +
-            this.role +
-            "&isN=" +
-            this.isN +
-            "&tcid=" +
-            this.tcid
-          );
+           if(this.back==1){
+            return this.$router.back()
+          }
+          // this.goTo(
+          //   "/testStudent?userid=" +
+          //   this.userid +
+          //   "&oid=" +
+          //   this.oid +
+          //   "&org=" +
+          //   this.org +
+          //   "&role=" +
+          //   this.role +
+          //   "&isN=" +
+          //   this.isN +
+          //   "&tcid=" +
+          //   this.tcid
+          // );
+          if (this.type == 3) {
+            this.goTo(
+              "/testPerson?userid=" +
+              this.userid +
+              "&oid=" +
+              this.oid +
+              "&org=" +
+              this.org +
+              "&role=" +
+              this.role
+            );
+          } else {
+            this.goTo(
+              "/testStudent?userid=" +
+              this.userid +
+              "&oid=" +
+              this.oid +
+              "&org=" +
+              this.org +
+              "&role=" +
+              this.role +
+              "&isN=" +
+              this.isN +
+              "&tcid=" +
+              this.tcid
+            );
+          }
         })
         .catch((err) => {
           this.$message.error("网络不佳");
@@ -559,6 +595,7 @@ export default {
       this.ajax
         .post(this.$store.state.api + ((this.tid) ? "addTestWorks2" : "addTestWorks"), params)
         .then((res) => {
+          if (this.tid) this.delTestWork()
           this.$message.success('提交成功')
           if(this.back==1){
             return this.$router.back()
@@ -620,6 +657,8 @@ export default {
       this.ajax
         .post(this.$store.state.api + ((this.tid) ? "addTestWorks2" : "addTestWorks"), params)
         .then((res) => {
+          if (this.tid) this.delTestWork()
+
           this.$message.success('保存成功')
           setTimeout(() => {
             this.isloading = false
@@ -649,6 +688,45 @@ export default {
         return false
       }
     },
+    delTestWork(){
+      let params = {
+        tid: this.cid
+      };
+      console.log('params',params);
+      
+      this.ajax
+        .get(this.$store.state.api + "getTestAiSco", params)
+        .then((res) => {
+          let data = res.data[0]
+          if (!data.length) return
+          this.uploadSCo(JSON.parse(data[0].json),data[0].cueWord)
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
+     // 上传评分
+    uploadSCo(val,cueWord){
+      // console.log('uploadSCo',val);
+      // 提交后删除评分
+      let scoArr = val.filter(e=> e.id != this.tid)
+
+      let params = [{
+        tid:this.cid,
+        uid:this.userid,
+        json:JSON.stringify(scoArr),
+        cw: cueWord
+      }]
+      console.log('params',params);
+       this.ajax
+        .post(this.$store.state.api + "addtestAiSco", params)
+        .then((res) => {
+          // console.log(res);
+        })
+        .catch((err) => {
+          console.error(err);
+        });
+    },
     deleteTest(tid) {
       let _this = this;
       let params = [
@@ -719,9 +797,17 @@ export default {
   align-items: center;
   width: calc(100% - 40px);
   margin: 0 auto;
-  padding: 10px 0;
+  padding: 10px;
+}
+.courseTop2{
+  display: flex;
+  flex-direction: row;
+  justify-content: space-between;
+  align-items: center;
+  width: calc(100% - 40px);
+  margin: 0 auto;
+  padding: 10px 40px;
 }
-
 .stepsNav {
   display: flex;
   flex-direction: row;

+ 1 - 1
src/components/pages/test_old/examine/conpoments/personPage.vue

@@ -207,7 +207,7 @@
                         <div v-else style="padding-top: 10px;">
                           <!-- {{ reverseString(k.testid.test) }} -->
                           <div
-                            v-for="(item2, index) in k.testid.test"
+                            v-for="(item2) in k.testid.test"
                             :key="item2.courseId"
                             class="orgData"
                           >

+ 4 - 4
src/components/pages/test_old/examine/conpoments/targetPage.vue

@@ -34,7 +34,7 @@
                   <div v-if="!k.testid.test.length">/</div>
                   <div v-else style="padding-top: 10px;">
                     <div
-                      v-for="(item2, index) in k.testid.test"
+                      v-for="(item2) in k.testid.test"
                       :key="item2.courseId"
                       @click="lookPrize(item2.courseId)"
                       class="orgDataCss"
@@ -91,7 +91,7 @@
                   <div v-if="!k.testid.test.length">/</div>
                   <div v-else style="padding-top: 10px;">
                     <div
-                      v-for="(item2, index) in k.testid.test"
+                      v-for="(item2) in k.testid.test"
                       :key="item2.courseId"
                       @click="lookPrize(item2.courseId)"
                       class="orgDataCss"
@@ -214,7 +214,7 @@
               <div v-if="!scope.row.orgData.length">/</div>
               <div v-else style="padding-top: 10px;">
                 <div
-                  v-for="(item2, index) in scope.row.orgData"
+                  v-for="(item2) in scope.row.orgData"
                   :key="item2.courseId"
                   class="orgDataCss"
                 >
@@ -1499,7 +1499,7 @@ export default {
 
     // 查看数据来源
     lookPrize(val) {
-      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0`;
+      this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/checkToTest?userid=${this.userid}&cid=${val}&oid=${this.oid}&org=${this.org}&type=2&role=0`;
       // this.ifmUrl = `https://beta.pbl.cocorobo.cn/pbl-teacher-table/dist/#/test?userid=${this.userid}&oid=45facc0a-1211-11ec-80ad-005056b86db5&org=&role=0`;
       this.diaIframe = true;
     },

+ 415 - 0
src/components/pages/workPage/components/choiceQuestion.vue

@@ -0,0 +1,415 @@
+<template>
+  <div class="choiceQuestion">
+    <div class="cq_title" v-if="work.testJson[showIndex]">
+      <span>{{ work.testJson[showIndex].teststitle }}</span>
+
+      <div class="cq_changeBtnArea" v-if="work.testJson.length>1">
+        <span :class="{cq_cba_disabled: showIndex == 0}" @click="changeQuestion('prev')">上一题</span>
+        <span :class="{cq_cba_disabled: showIndex == work.testJson.length - 1}" @click="changeQuestion('next')">下一题</span>
+      </div>
+    </div>
+
+
+    <img class="cq_image" v-if="work.testJson[showIndex].timuList.length>0" :src="work.testJson[showIndex].timuList[0].src" @click="$hevueImgPreview(work.testJson[showIndex].timuList[0].src)">
+
+    <div class="cq_type" v-if="work.testJson[showIndex]">
+      {{ work.testJson[showIndex].type == 1 ? "单选题" : "多选题" }}
+      <span v-if="work.testJson.length>1">({{showIndex+1}}/{{work.testJson.length}})</span>
+
+    </div>
+    <div class="cq_checkListArea">
+      <div
+        class="cq_ca_type1"
+        v-if="
+          work.testJson[showIndex] && work.testJson[showIndex].showType == '1'
+        "
+      >
+        <div
+          class="cq_ca_t1_item"
+          :class="{
+            cq_ca_t1_item_active:
+              work.testJson[showIndex].type == '1'
+                ? work.testJson[showIndex].userAnswer === index
+                : work.testJson[showIndex].userAnswer.includes(index)
+          }"
+          v-for="(item, index) in work.testJson[showIndex].checkList"
+          :key="showIndex + '_' + index"
+          @click="choiceAnswer(index)"
+        >
+          <div>
+            <span>{{ options[index] }}</span>
+          </div>
+          <img v-if="item.imgType && item.imgType=='1'" :src="item.src" @click="$hevueImgPreview(item.src)">
+          <span v-else>{{ item }}</span>
+        </div>
+      </div>
+
+      <div class="cq_ca_type2" v-if="
+          work.testJson[showIndex] && work.testJson[showIndex].showType == '2'
+        ">
+        <div
+          class="cq_ca_t2_item"
+          :class="{
+            cq_ca_t2_item_active:
+              work.testJson[showIndex].type == '1'
+                ? work.testJson[showIndex].userAnswer === index
+                : work.testJson[showIndex].userAnswer.includes(index)
+          }"
+          v-for="(item, index) in work.testJson[showIndex].checkList"
+          :key="showIndex + '_' + index"
+          @click="choiceAnswer(index)"
+        >
+          <div>
+            <span>{{ options[index] }}</span>
+          </div>
+          <img v-if="item.imgType && item.imgType=='1'" :src="item.src" @click="$hevueImgPreview(item.src)">
+          <span v-else>{{ item }}</span>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  props: {
+    workData: {
+      type: Object,
+      default: () => {
+        return {};
+      }
+    }
+  },
+
+  data() {
+    return {
+      work: {
+        testJson: []
+      },
+      showIndex: 0,
+      options: [
+        "A",
+        "B",
+        "C",
+        "D",
+        "E",
+        "F",
+        "G",
+        "H",
+        "I",
+        "J",
+        "K",
+        "L",
+        "M",
+        "N",
+        "O",
+        "P",
+        "Q",
+        "R",
+        "S",
+        "T",
+        "U",
+        "V",
+        "W",
+        "X",
+        "Y",
+        "Z"
+      ]
+    };
+  },
+  watch: {
+    work: {
+      handler(newValue) {
+        if (JSON.stringify(newValue) != JSON.stringify(this.workData.json)) {
+          this.changeWorkData(newValue);
+        }
+      },
+      deep: true
+    }
+  },
+  methods: {
+    changeWorkData(newValue) {
+      this.$emit("changeWorkData", JSON.stringify(newValue));
+    },
+    //选择题目
+    choiceAnswer(index) {
+      if (this.work.testJson[this.showIndex].type == "1") {
+        this.work.testJson[this.showIndex].userAnswer = index;
+      } else {
+        if (this.work.testJson[this.showIndex].userAnswer.includes(index)) {
+          this.work.testJson[this.showIndex].userAnswer = this.work.testJson[
+            this.showIndex
+          ].userAnswer.filter(i => i != index);
+        } else {
+          this.work.testJson[this.showIndex].userAnswer.push(index);
+        }
+      }
+    },
+    //切换题目
+    changeQuestion(type){
+      if(type == 'prev'){
+        if(this.showIndex == 0) return;
+        this.showIndex--;
+      }else{
+        if(this.showIndex == this.work.testJson.length - 1) return;
+        this.showIndex++;
+      }
+    }
+
+  },
+  mounted() {
+    this.work = JSON.parse(JSON.stringify(this.workData.json));
+    this.work.testJson.forEach(i => {
+      let maxLength = i.checkList.reduce((pre, cur) => {
+        if (pre < cur.length) return cur.length;
+        return pre;
+      }, 0);
+
+      if (maxLength <= 6 && i.checkList.length <= 4) {
+        i.showType = "1";
+      } else {
+        i.showType = "2";
+      }
+    });
+  }
+};
+</script>
+
+<style scoped>
+
+
+.choiceQuestion {
+  width: 100%;
+  height: 100%;
+  display: flex;
+  align-items: center;
+  /* justify-content: center; */
+  flex-direction: column;
+  box-sizing: border-box;
+  padding: 50px 10%;
+  overflow: auto;
+  position: relative;
+}
+
+.cq_title {
+  font-size: 35px;
+  font-weight: bold;
+  text-align: center;
+  width: 70%;
+  position: relative;
+}
+
+.cq_image{
+  width: auto;
+  height: 300px;
+  object-fit: cover;
+  margin: 20px 0;
+  cursor: pointer;
+}
+
+.cq_changeBtnArea {
+  position: absolute;
+  top: 0px;
+  right: -200px;
+  width: 200px;
+  height: auto;
+  display: flex;
+  justify-content: flex-end;
+  align-items: flex-start;
+}
+
+.cq_changeBtnArea > span{
+  width: 100px;
+  height: 40px;
+  background: #3681FC;
+  border-radius: 8px;
+  color: #fff;
+  font-size: 16px;
+  text-align: center;
+  font-weight: 500;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  cursor: pointer;
+  margin-left: 20px;
+  transition: .2s;
+}
+
+.cq_changeBtnArea > span:hover{
+  background: #5893FF;
+}
+
+.cq_cba_disabled{
+  background: #D9D9D9 !important;
+  cursor: not-allowed !important;
+}
+
+.cq_type {
+  margin: 20px 0 40px 0;
+  font-size: 22px;
+  color: #808080;
+}
+
+.cq_checkListArea {
+  width: 100%;
+  height: auto;
+  box-sizing: border-box;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.cq_ca_type1 {
+  width: auto;
+  height: auto;
+  display: grid;
+  grid-template-columns: repeat(2, 1fr);
+  grid-template-rows: repeat(2, 1fr);
+  gap: 30px; /* 可根据需要调整间距 */
+  justify-content: center;
+  align-items: center;
+  margin: 40px 20px;
+}
+
+.cq_ca_t1_item {
+  width: 100%;
+  max-width: 400px;
+  min-width: 300px;
+  height: 100px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+
+  background: #fff;
+  box-shadow: 2px 4px 20px 0px rgba(0, 0, 0, 0.2);
+  border-radius: 12px;
+  margin: auto;
+  cursor: pointer;
+  transition: 0.3s;
+  font-size: 20px;
+  color: #000;
+  user-select: none;
+  /* 不可选中 */
+  /* box-sizing: border-box;
+  padding: 20px 40px; */
+}
+
+.cq_ca_t1_item_active {
+  box-shadow: 4px 4px 14px 0px rgba(252, 207, 0, 0.5);
+}
+
+.cq_ca_t1_item > div {
+  color: #fff;
+  position: relative;
+  margin-right: 20px;
+}
+
+.cq_ca_t1_item>img{
+  width: 80px;
+  height: 80px;
+  cursor: pointer;
+  object-fit: cover;
+}
+
+.cq_ca_t1_item > div > span {
+  position: relative;
+  z-index: 2;
+  color: #fff;
+  font-size: 20px;
+}
+
+.cq_ca_t1_item > div::after {
+  content: "";
+  width: 25px;
+  height: 25px;
+  background: rgba(252, 207, 0, 1);
+  border-radius: 50%;
+  position: absolute;
+  left: 50%;
+  top: 50%;
+  transform: translate(-50%, -50%);
+  z-index: 1; /* after在内容下方 */
+  pointer-events: none;
+}
+
+.cq_ca_type2{
+  width: 100%;
+  height: auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+}
+
+.cq_ca_t2_item{
+  width: 100%;
+  height: 72px;
+  display: flex;
+  align-items: center;
+  justify-content: flex-start;
+  box-sizing: border-box;
+  padding-left: 40px;
+  padding-right: 20px;
+  margin-bottom: 20px;
+  background: #fff;
+  box-shadow: 2px 4px 20px 0px rgba(0, 0, 0, 0.2);
+  border-radius: 12px;
+  cursor: pointer;
+  transition: 0.3s;
+  font-size: 20px;
+  color: #000;
+  user-select: none;
+  overflow: auto;
+  overflow-y: hidden;
+}
+
+.cq_ca_t2_item>div{
+  color: #fff;
+  position: relative;
+  margin-right: 20px;
+}
+
+.cq_ca_t2_item>span{
+  display: flex;
+  align-items: center;
+  white-space: nowrap;
+}
+
+.cq_ca_t2_item>img{
+  width: 70px;
+  height: 70px;
+  cursor: pointer;
+  object-fit: cover;
+}
+
+
+.cq_ca_t2_item_active {
+  box-shadow: 4px 4px 14px 0px rgba(252, 207, 0, 0.5);
+}
+
+.cq_ca_t2_item > div {
+  color: #fff;
+  position: relative;
+  margin-right: 20px;
+}
+.cq_ca_t2_item > div > span {
+  position: relative;
+  z-index: 2;
+  color: #fff;
+  font-size: 20px;
+}
+
+.cq_ca_t2_item > div::after {
+  content: "";
+  width: 25px;
+  height: 25px;
+  background: rgba(252, 207, 0, 1);
+  border-radius: 50%;
+  position: absolute;
+  left: 50%;
+  top: 50%;
+  transform: translate(-50%, -50%);
+  z-index: 1; /* after在内容下方 */
+  pointer-events: none;
+}
+</style>

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 32 - 0
src/components/pages/workPage/components/questionsAndAnswers.vue


+ 343 - 0
src/components/pages/workPage/components/wangEnduit.vue

@@ -0,0 +1,343 @@
+<template lang="html">
+  <div class="editor cont">
+    <div ref="toolbar" class="toolbar">
+    </div>
+    <div ref="editor" class="text">
+    </div>
+		<slot></slot>
+    <div v-if="proVisible" class="mask">
+      <div class="progressBox">
+        <div class="lbox">
+          <img src="../../../../assets/loading.gif" />上传中,请稍后
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import E from "wangeditor";
+import "../../../../common/aws-sdk-2.235.1.min";
+// import 'wangeditor/release/wangEditor.min.css'
+export default {
+  name: "editoritem",
+  data() {
+    return {
+      // uploadPath,
+      editor: null,
+      info_: null,
+      proVisible:false,
+      progress:0
+    };
+  },
+  model: {
+    prop: "value",
+    event: "change",
+  },
+  props: {
+    value: {
+      type: String,
+      default: "",
+    },
+    isClear: {
+      type: Boolean,
+      default: false,
+    },
+    placeholder: {
+      type: String,
+      default: "请输入正文"
+    },
+		showGetTextLoading:{
+			type:Boolean,
+			default:false,
+		}
+  },
+  watch: {
+    isClear(val) {
+      // 触发清除文本域内容
+      if (val) {
+        this.editor.txt.clear();
+        this.info_ = null;
+      }
+    },
+    value: function (value) {
+      if (value !== this.editor.txt.html()) {
+        this.editor.txt.html(this.value);
+      }
+    },
+    //value为编辑框输入的内容,这里我监听了一下值,当父组件调用得时候,如果给value赋值了,子组件将会显示父组件赋给的值
+  },
+  mounted() {
+    this.seteditor();
+    this.editor.txt.html(this.value);
+  },
+  methods: {
+    seteditor() {
+      this.editor = new E(this.$refs.toolbar, this.$refs.editor);
+      // 关闭菜单栏fixed
+      this.editor.config.menuFixed = false;
+      // 普通的自定义菜单
+      this.editor.config.menus = [
+        "head", //标题
+        "bold", //加粗
+        "fontSize", //字体大小
+        // "fontName", //字体
+        // "italic", //斜体
+        // "underline", //下划线
+        // "strikeThrough", //删除线
+        "indent", //缩进
+        // "lineHeight", //行高
+        // "foreColor",
+        // "backColor",
+        // "link",
+        // "list",
+        // "todo",
+        "justify",
+        // "quote",
+        // "emoticon",
+        "image",
+        // "video",
+        "table",
+        // "code",
+        // "splitLine",
+        "undo",
+        "redo",
+      ];
+      // 带格式粘贴
+      this.editor.config.pasteFilterStyle = false;
+      //忽略粘贴内容中的图片
+      this.editor.config.pasteIgnoreImg = false;
+      this.editor.config.showLinkImg = false;
+      this.editor.config.placeholder = this.placeholder;
+      var that = this;
+      this.editor.config.customUploadImg = function (files, insert) {
+        // const loading = Loading.service({
+        //   lock: true,
+        //   background: 'rgba(0, 0, 0, 0.7)'
+        // });
+        // 图片自定义上传方法
+        var kk = 0
+        for (var i = 0; i < files.length; i++) {
+          var file = files[i];
+          var credentials = {
+            accessKeyId: "AKIATLPEDU37QV5CHLMH",
+            secretAccessKey: "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",
+          }; //秘钥形式的登录上传
+          window.AWS.config.update(credentials);
+          window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+          var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+          that.proVisible = true
+          if (file) {
+            var params = {
+              Key:
+                file.name.split(".")[0] +
+                new Date().getTime() +
+                "." +
+                file.name.split(".")[file.name.split(".").length - 1],
+              ContentType: file.type,
+              Body: file,
+              "Access-Control-Allow-Credentials": "*",
+              ACL: "public-read",
+            }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+            var options = {
+              partSize: 2048 * 1024 * 1024,
+              queueSize: 2,
+              leavePartsOnError: true,
+            };
+            bucket
+              .upload(params, options)
+              .on("httpUploadProgress", function (evt) {
+                //这里可以写进度条
+                // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+              })
+              .send(function (err, data) {
+                kk++
+                if(kk == files.length - 1 || kk > files.length - 1){
+                  that.proVisible = false
+                }
+                // loading.close();
+                if (err) {
+                  that.$message.error("上传失败");
+                } else {
+                  //上传成功处理
+                  insert(data.Location);
+                }
+              });
+          }
+        }
+      };
+      //配置 自定义处理粘贴的文本内容
+      this.editor.config.pasteTextHandle = function (content) {
+        if (content == '' && !content) return ''
+        var str = content
+        str = str.replace(/<xml>[\s\S]*?<\/xml>/ig, '')
+        str = str.replace(/<style>[\s\S]*?<\/style>/ig, '')
+        str = str.replace(/<\/?[^>]*>/g, '')
+        str = str.replace(/[ | ]*\n/g, '\n')
+        str = str.replace(/&nbsp;/ig, '')
+        // console.log('****', content)
+        // console.log('****', str)
+        return str
+      };
+      this.editor.config.onchange = (html) => {
+        this.info_ = html; // 绑定当前逐渐地值
+        this.$emit("change", this.info_); // 将内容同步到父组件中
+      };
+      // 创建富文本编辑器
+      this.editor.create();
+    },
+  },
+};
+</script>
+
+<style lang="css" scoped>
+.editor {
+   width: 100%;
+   height: calc(100%);
+   margin: 0px auto;
+   position: relative;
+   z-index: 0;
+ }
+
+ .toolbar {
+   /* border: 1px solid #ccc; */
+   border-radius: 12px 12px 0 0;
+   border-bottom: solid 2px #E7E7E7;
+   background: none;
+ }
+
+ .toolbar /deep/ .w-e-toolbar{
+  border-radius: 12px 12px 0 0;
+  background: none;
+ }
+
+ .text {
+   /* border: 1px solid #ccc; */
+   height: calc(100% - 42px);
+   overflow: auto;
+ }
+
+ .text /deep/ .w-e-text-container{
+  background: none;
+  border-radius: 0 0 12px 12px;
+ }
+
+
+ /* table 样式 */
+ .cont>>>table {
+  border-top: 1px solid #ccc;
+  border-left: 1px solid #ccc;
+}
+
+.cont>>>table td,
+.cont>>>table th {
+  border-bottom: 1px solid #ccc;
+  border-right: 1px solid #ccc;
+  /* padding: 20px 5px; */
+  padding: 5px 10px;
+  max-width: 0px;
+  height: 30px;
+  vertical-align: baseline;
+}
+
+.cont>>>table th {
+  border-bottom: 2px solid #ccc;
+  text-align: center;
+}
+
+ /* blockquote 样式 */
+ .cont>>>blockquote {
+   display: block;
+   border-left: 8px solid #d0e5f2;
+   padding: 5px 10px;
+   margin: 10px 0;
+   line-height: 1.4;
+   font-size: 100%;
+   background-color: #f1f1f1;
+ }
+
+ /* code 样式 */
+ .cont>>>code {
+   display: inline-block;
+   *display: inline;
+   *zoom: 1;
+   background-color: #f1f1f1;
+   border-radius: 3px;
+   padding: 3px 5px;
+   margin: 0 3px;
+ }
+
+ .cont>>>pre code {
+   display: block;
+ }
+
+ /* ul ol 样式 */
+ .cont>>>ul,
+ ol {
+   margin: 0 !important;
+ }
+
+ /* .cont>>>.w-e-droplist{
+  width: 80px !important;
+ } */
+
+ .mask {
+  background-color: rgb(0 0 0 / 30%);
+  /* position: fixed; */
+  position: absolute;
+  top: 0;
+  left: 0;
+  width: 100%;
+  height: 100%;
+  z-index: 99999;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.mask2 {
+  position: fixed !important;
+  z-index: 999999;
+}
+
+.progressBox {
+  width: 300px;
+  height: 150px;
+  background: #fff;
+  border-radius: 10px;
+  box-shadow: 0 0 6px 1px #bfbfbf;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  flex-direction: column;
+}
+
+.progressBox .lbox {
+  height: 100px;
+  font-size: 16px;
+  display: flex;
+  align-items: center;
+}
+
+.progressBox .lbox img {
+  width: 40px;
+  margin-right: 20px;
+}
+
+.progressBox>>>.el-progress-bar__outer {
+  background-color: #d1dfff !important;
+}
+
+.progressBox .lbox {
+  height: 100px;
+  font-size: 19px;
+  display: flex;
+  align-items: center;
+}
+
+.progressBox .lbox img {
+  width: 40px;
+  margin-right: 20px;
+}
+</style>

+ 777 - 0
src/components/pages/workPage/index.vue

@@ -0,0 +1,777 @@
+<template>
+  <div class="workPage" v-loading="loading">
+    <div class="wp_tool wp_tool15" v-if="workData && workData.type == 15">
+      <div class="wp_t15_title">{{ workData.json.answerQ }}</div>
+      <span class="wp_type">问答题</span>
+      <div class="wp_tl15_inputArea">
+        <el-input
+          type="textarea"
+          :rows="7"
+          placeholder="请在此输入您的答案..."
+          resize="none"
+          v-model="workData.json.answer"
+        >
+        </el-input>
+      </div>
+      <div class="wp_tl15_uploadFileArea">
+        <div
+          class="wp_tl_btn"
+          @click="uploadImage()"
+          v-loading="loadingUploadFile"
+        >
+          <svg
+            t="1755158440992"
+            class="icon"
+            viewBox="0 0 1024 1024"
+            version="1.1"
+            xmlns="http://www.w3.org/2000/svg"
+            p-id="8270"
+            width="200"
+            height="200"
+          >
+            <path
+              d="M924 1024H100A100 100 0 0 1 0 924V638a40 40 0 0 1 80 0v286a20 20 0 0 0 20 20h824a20 20 0 0 0 20-20V638a40 40 0 0 1 80 0v286a100 100 0 0 1-100 100zM784 352a40 40 0 0 1-28-12L512 97 268 340a40 40 0 0 1-57-57L484 12a40 40 0 0 1 57 0l271 272a40 40 0 0 1-28 68z"
+              fill="#474747"
+              p-id="8271"
+            ></path>
+            <path
+              d="M512 788a40 40 0 0 1-40-40V57a40 40 0 0 1 80 0v691a40 40 0 0 1-40 40z"
+              fill="#474747"
+              p-id="8272"
+            ></path>
+          </svg>
+          <span>上传图片</span>
+        </div>
+        <span>支持JPG、PNG格式,最大5MB</span>
+      </div>
+
+      <div class="wp_tl15_fileList">
+        <div
+          class="wp_tl15_fileList_item"
+          v-for="(item, index) in workData.json.fileList"
+          :key="index"
+        >
+          <img :src="item.url" alt="" @click="previewImage(item)" />
+          <svg
+            @click="deleteFile(index)"
+            t="1755162206922"
+            class="icon"
+            viewBox="0 0 1024 1024"
+            version="1.1"
+            xmlns="http://www.w3.org/2000/svg"
+            p-id="9357"
+            width="200"
+            height="200"
+          >
+            <path
+              d="M512 883.2A371.2 371.2 0 1 0 140.8 512 371.2 371.2 0 0 0 512 883.2z m0 64a435.2 435.2 0 1 1 435.2-435.2 435.2 435.2 0 0 1-435.2 435.2z"
+              fill="#d81e06"
+              p-id="9358"
+            ></path>
+            <path
+              d="M557.056 512l122.368 122.368a31.744 31.744 0 1 1-45.056 45.056L512 557.056l-122.368 122.368a31.744 31.744 0 1 1-45.056-45.056L466.944 512 344.576 389.632a31.744 31.744 0 1 1 45.056-45.056L512 466.944l122.368-122.368a31.744 31.744 0 1 1 45.056 45.056z"
+              fill="#d81e06"
+              p-id="9359"
+            ></path>
+          </svg>
+        </div>
+      </div>
+    </div>
+
+    <div class="wp_tool wp_tool45" v-if="workData && workData.type == 45">
+      <div class="wp_t45_title">练一练</div>
+      <div
+        class="s_b_m_toolItem"
+        v-for="(item, index) in workData.json.testJson"
+        :key="index + '_' + workData.id"
+      >
+        <div class="s_b_m_ti_title">
+          <span>{{ index + 1 }}</span>
+          <svg
+            width="16"
+            height="16"
+            viewBox="0 0 16 16"
+            fill="none"
+            xmlns="http://www.w3.org/2000/svg"
+          >
+            <path
+              d="M15.3536 8.35355C15.5488 8.15829 15.5488 7.84171 15.3536 7.64645L12.1716 4.46447C11.9763 4.2692 11.6597 4.2692 11.4645 4.46447C11.2692 4.65973 11.2692 4.97631 11.4645 5.17157L14.2929 8L11.4645 10.8284C11.2692 11.0237 11.2692 11.3403 11.4645 11.5355C11.6597 11.7308 11.9763 11.7308 12.1716 11.5355L15.3536 8.35355ZM1 8.5H15V7.5H1V8.5Z"
+              fill="#3681FC"
+            />
+          </svg>
+
+          <span
+            ><span
+              v-html="
+                renderedFormula(
+                  `<span style='color: #3681FC;''>${
+                    item.type == 1 ? '(单选题):' : '(多选题):'
+                  }</span>${item.teststitle}`
+                )
+              "
+            ></span>
+          </span>
+        </div>
+        <div
+          class="s_b_m_ti_option"
+          v-for="(item2, index2) in item.checkList"
+          @click="chooseAnswer(index, index2)"
+          :key="index + '_' + index2 + 'index2T'"
+          :class="{
+            s_b_m_ti_o_choice:
+              item.type == '1'
+                ? workData.json.testJson[index].userAnswer === index2
+                : workData.json.testJson[index].userAnswer.includes(index2)
+          }"
+        >
+          <div class="s_b_m_ti_o_btn">
+            <span class="s_b_m_ti_o_btn1" v-if="item.type == 1">
+              <span
+                v-if="workData.json.testJson[index].userAnswer === index2"
+              ></span>
+            </span>
+            <span class="s_b_m_ti_o_btn2" v-else>
+              <span
+                v-if="workData.json.testJson[index].userAnswer.includes(index2)"
+              >
+              </span>
+            </span>
+          </div>
+          <span>
+            <img
+              v-if="item2.imgType && item2.imgType === 1"
+              :src="item2.src"
+              alt=""
+              @click.stop="$hevueImgPreview(item2.src)"
+            />
+            <span v-else>{{ item2 }}</span>
+          </span>
+        </div>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import katex from "katex";
+import "katex/dist/katex.min.css";
+export default {
+  data() {
+    return {
+      id: this.$route.query.id,
+      courseid: this.$route.query.courseid,
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      role: this.$route.query.role,
+      stage: this.$route.query.stage,
+      task: this.$route.query.task,
+      tool: this.$route.query.tool,
+      type: "",
+      cid: this.$route.query.cid,
+      workData: {},
+      loadingUploadFile: false,
+      studentWork: null,
+      loading: false
+    };
+  },
+  watch: {
+    workData: {
+      deep: true,
+      handler(newValue) {
+        if (newValue) {
+          this.setWorkDataToWindow();
+        }
+      }
+    }
+  },
+  computed: {
+    renderedFormula() {
+      return function(val) {
+        try {
+          // 判断是否含有HTML标签,<tag ...>...</tag>
+          const hasTag = /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g.test(
+            val
+          );
+          if (!hasTag) {
+            val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+
+            // 纯文本,整体渲染
+            try {
+              return katex.renderToString(val.trim(), {
+                throwOnError: false,
+                strict: false,
+                output: "htmlAndMathml"
+              });
+            } catch (e) {
+              return val; // 渲染失败原样输出
+            }
+          } else {
+            // 有标签,对每个标签内容渲染
+            return val.replace(
+              /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g,
+              (match, tag, attrs, inner) => {
+                let html;
+                val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+                try {
+                  html = katex.renderToString(inner.trim(), {
+                    throwOnError: false,
+                    strict: false,
+                    output: "htmlAndMathml"
+                  });
+                } catch (e) {
+                  html = inner;
+                }
+                return `<${tag}${attrs}>${html}</${tag}>`;
+              }
+            );
+          }
+        } catch (e) {
+          console.error("KaTeX渲染错误:", e);
+          return val;
+        }
+      };
+    }
+  },
+  methods: {
+    getWorkData() {
+      if (!this.id) return console.log("无作业id");
+      let params = {
+        id: this.id
+      };
+      this.ajax
+        .get(this.$store.state.api + "select_workPageById", params)
+        .then(res => {
+          let _data = res.data[0];
+          if (_data.length) {
+            _data = _data[0];
+            _data.json = JSON.parse(_data.json);
+            if (_data.type == 15) {
+              _data.json.answer = "";
+              _data.json.fileList = [];
+            } else if (_data.type == 45) {
+              _data.json.testJson.forEach(item => {
+                if (item.type == "2") {
+                  item.userAnswer = [];
+                } else if (item.type == "1") {
+                  item.userAnswer = "";
+                }
+              });
+            }
+
+            this.workData = _data;
+            this.studentWorkToWorkData();
+          }
+        });
+    },
+    setWorkDataToWindow() {
+      if (this.workData.json) {
+        window.workData = JSON.parse(JSON.stringify(this.workData));
+      }
+    },
+    uploadImage() {
+      if (this.loadingUploadFile) return;
+      let input = document.createElement("input");
+      input.type = "file";
+      input.accept = "image/jpeg,image/png";
+      input.click();
+      input.onchange = e => {
+        let file = e.target.files[0];
+        if (file) {
+          if (file.size > 5 * 1024 * 1024) {
+            // 5MB
+            return this.$message.error("图片大小不能超过5MB");
+          }
+          let _type = file.type;
+          let _size = file.size;
+          this.loadingUploadFile = true;
+          this.uploadFile(file).then(res => {
+            let _file = {
+              name: file.name,
+              url: res.Location,
+              type: _type,
+              size: _size,
+              uploadTime: new Date().getTime()
+            };
+            if (["15"].includes(this.workData.type)) {
+              this.workData.json.fileList.push(_file);
+            }
+            this.$forceUpdate();
+            this.loadingUploadFile = false;
+          });
+        }
+      };
+    },
+    uploadFile(file) {
+      return new Promise(resolve => {
+        var credentials = {
+          accessKeyId: "AKIATLPEDU37QV5CHLMH",
+          secretAccessKey: "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"
+        }; //秘钥形式的登录上传
+        window.AWS.config.update(credentials);
+        window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+        var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+        var _this = this;
+
+        if (file) {
+          var params = {
+            Key:
+              file.name.split(".")[0] +
+              new Date().getTime() +
+              "." +
+              file.name.split(".")[file.name.split(".").length - 1],
+            ContentType: file.type,
+            Body: file,
+            "Access-Control-Allow-Credentials": "*",
+            ACL: "public-read"
+          }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+          var options = {
+            partSize: 2048 * 1024 * 1024,
+            queueSize: 2,
+            leavePartsOnError: true
+          };
+          bucket
+            .upload(params, options)
+            .on("httpUploadProgress", function(evt) {
+              //这里可以写进度条
+              // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            })
+            .send(function(err, data) {
+              if (err) {
+                _this.$message.error("上传失败");
+                resolve(null);
+              } else {
+                resolve(data);
+              }
+            });
+        }
+      });
+    },
+    //预览图片
+    previewImage(url) {
+      this.$hevueImgPreview(url);
+    },
+    deleteFile(index) {
+      this.workData.json.fileList.splice(index, 1);
+      this.$forceUpdate();
+    },
+    submitWork(task) {
+      return new Promise(resolve => {
+        let params = [];
+        if (this.workData.type == "15") {
+          //问答题
+          params.push({
+            uid: this.userid,
+            cid: this.courseid,
+            stage: 0,
+            task: task,
+            tool: 0,
+            atool: "15",
+            content: encodeURIComponent(JSON.stringify(this.workData.json)),
+            type: "3"
+          });
+        } else if (this.workData.type == "45") {
+          //选择题
+          params.push({
+            uid: this.userid,
+            cid: this.courseid,
+            stage: 0,
+            task: task,
+            tool: 0,
+            atool: "45",
+            content: encodeURIComponent(JSON.stringify(this.workData.json)),
+            type: "8"
+          });
+        }
+        if (
+          ["3", "8"].includes(params[0].type) &&
+          params[0].uid &&
+          params[0].cid
+        ) {
+          this.loading = true;
+          this.ajax
+            .post(this.$store.state.api + "addCourseWorks_workPage", params)
+            .then(res => {
+              let _data = res.data[0];
+              this.loading = false;
+              if (_data.length > 0) {
+                let _id = _data[0].id;
+                resolve(_id);
+              } else {
+                resolve("");
+              }
+            })
+            .catch(err => {
+              console.log(err);
+              resolve("");
+              this.loading = false;
+            });
+        }
+      });
+    },
+    //选择题选择
+    chooseAnswer(index, index2) {
+      if (this.workData.json.testJson[index].type == "1") {
+        this.workData.json.testJson[index].userAnswer = index2;
+      } else if (this.workData.json.testJson[index].type == "2") {
+        if (this.workData.json.testJson[index].userAnswer.includes(index2)) {
+          this.workData.json.testJson[index].userAnswer.splice(
+            this.workData.json.testJson[index].userAnswer.indexOf(index2),
+            1
+          );
+        } else {
+          this.workData.json.testJson[index].userAnswer.push(index2);
+        }
+      }
+    },
+    //获取已经提交的作业
+    getSubmitWork() {
+      if (
+        this.userid &&
+        this.courseid &&
+        this.stage &&
+        this.task &&
+        this.tool
+      ) {
+        let params = {
+          uid: this.userid,
+          cid: this.courseid,
+          stage: this.stage,
+          task: this.task,
+          tool: this.tool
+        };
+        this.loading = true;
+        this.ajax
+          .get(
+            this.$store.state.api + "select_courseWorks_workPageData",
+            params
+          )
+          .then(res => {
+            let _data = res.data[0];
+            this.loading = false;
+            if (_data.length) {
+              _data = _data[0];
+              if (["15", "45"].includes(_data.atool)) {
+                let _work = JSON.parse(decodeURIComponent(_data.content));
+                this.studentWork = _work;
+                this.studentWorkToWorkData();
+              }else{
+                console.log("工具不一致")
+              }
+            }
+          })
+          .catch(err => {
+            this.loading = false;
+            console.error(err);
+          });
+      }
+    },
+    studentWorkToWorkData() {
+      if (this.studentWork && this.workData) {
+        console.log("studentWork", this.studentWork);
+        console.log("workData", this.workData);
+
+        let _work = JSON.parse(JSON.stringify(this.studentWork));
+        if (this.workData.type == "15") {
+          this.workData.json.answer = _work.answer;
+          this.workData.json.fileList = _work.fileList;
+        } else if (this.workData.type == "45") {
+          this.workData.json.testJson.forEach((item, index) => {
+            if (
+              item.type == _work.testJson[index].type &&
+              item.teststitle == _work.testJson[index].teststitle &&
+              JSON.stringify(item.checkList) ==
+                JSON.stringify(_work.testJson[index].checkList)
+            ) {
+              this.workData.json.testJson[index].userAnswer =
+                _work.testJson[index].userAnswer;
+            }
+          });
+        }
+        this.$forceUpdate();
+      }
+    }
+  },
+  mounted() {
+    this.getWorkData();
+    this.getSubmitWork();
+    window.submitWork = this.submitWork;
+  }
+};
+</script>
+
+<style scoped>
+.workPage {
+  width: 100%;
+  height: auto;
+  min-height: 100%;
+
+  background-color: #fff;
+  overflow: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+}
+
+.wp_tool {
+  width: 100%;
+  height: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  padding: 40px 0;
+}
+
+.wp_t15_title {
+  font-size: 40px;
+  font-weight: 300;
+  margin: 20px 0;
+  max-width: 50%;
+  min-width: 300px;
+  text-align: left;
+}
+
+.wp_type {
+  margin: 20px 0;
+  font-size: 1em;
+  color: #7b7b7b;
+}
+
+.wp_tl15_inputArea {
+  width: 50%;
+  min-width: 300px;
+  margin: 20px 0;
+}
+
+.wp_tl15_inputArea >>> textarea {
+  border-color: #ececec;
+  border-radius: 10px;
+  padding: 10px 20px;
+  box-shadow: 0 0 10px #ececec;
+}
+
+.wp_tl15_inputArea >>> textarea::placeholder {
+  color: #7f7f7f;
+}
+
+.wp_tl15_uploadFileArea {
+  width: 50%;
+  min-width: 300px;
+  height: auto;
+  display: flex;
+  align-items: center;
+  margin-bottom: 10px;
+}
+
+.wp_tl_btn {
+  width: auto;
+  height: auto;
+  padding: 12px 16px;
+  background-color: #f9f9f9;
+  border-radius: 10px;
+  border: 1px dashed #e5e5e5;
+  font-size: 14px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  color: #474747;
+  cursor: pointer;
+  margin-right: 10px;
+  transition: 0.3s;
+}
+
+.wp_tl_btn:hover {
+  background-color: #ececec;
+}
+
+.wp_tl_btn > svg {
+  width: 15px;
+  height: 15px;
+  margin-right: 5px;
+}
+
+.wp_tl15_uploadFileArea > span {
+  font-size: 14px;
+  color: #686868;
+}
+
+.wp_tl15_fileList {
+  width: 50%;
+  min-width: 300px;
+  height: auto;
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+}
+
+.wp_tl15_fileList_item {
+  width: 150px;
+  height: 100px;
+  border-radius: 10px;
+  position: relative;
+  margin-right: 20px;
+}
+
+.wp_tl15_fileList_item:hover > svg {
+  display: block;
+}
+
+.wp_tl15_fileList_item > img {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+  border-radius: 10px;
+  box-shadow: 0 0 10px #ececec;
+  margin: 10px;
+  cursor: pointer;
+}
+
+.wp_tl15_fileList_item > svg {
+  width: 20px;
+  height: 20px;
+  position: absolute;
+  right: -20px;
+  top: 1px;
+  cursor: pointer;
+  display: none;
+}
+
+/* 选择题 */
+
+.wp_tool45 {
+  width: 60%;
+  height: auto;
+}
+
+.wp_t45_title {
+  font-size: 3em;
+  font-weight: 300;
+  margin: 20px 0 40px 0;
+}
+
+.s_b_m_toolItem {
+  width: 100%;
+  height: auto;
+  margin-bottom: 40px;
+}
+
+.s_b_m_ti_option {
+  width: 100%;
+  height: auto;
+  padding: 15px 15px 15px 15px;
+  display: flex;
+  /* flex-wrap: wrap; */
+  background-color: #f3f7fd;
+  border-radius: 30px;
+  margin: 10px 0 10px 0px;
+  box-sizing: border-box;
+  cursor: pointer;
+}
+
+.s_b_m_ti_option > span > img {
+  max-height: 150px;
+  border-radius: 2px;
+  cursor: pointer;
+}
+
+.s_b_m_ti_o_btn {
+  width: 20px;
+  height: 100%;
+  min-height: 20px;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  margin-right: 10px;
+}
+
+.s_b_m_ti_o_btn > span {
+  width: 20px;
+  height: 20px;
+  display: block;
+  box-sizing: border-box;
+  border: solid 1px #3681fc;
+  overflow: hidden;
+}
+
+.s_b_m_ti_o_btn > span > span {
+  width: 100%;
+  height: 100%;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  background-color: #3681fc;
+  position: relative;
+}
+
+.s_b_m_ti_o_btn1 {
+  border-radius: 50%;
+}
+
+.s_b_m_ti_o_btn1 > span::after {
+  content: "";
+  width: 8px;
+  height: 8px;
+  position: absolute;
+  background-color: #fff;
+  border-radius: 50%;
+}
+
+.s_b_m_ti_o_btn2 {
+  border-radius: 2px;
+}
+
+.s_b_m_ti_o_btn2 > span::after {
+  content: "";
+  width: 8px;
+  height: 8px;
+  position: absolute;
+  background-color: #fff;
+}
+
+.s_b_m_ti_o_choice {
+  border: solid 1px #3681fc;
+}
+
+.s_b_m_ti_title {
+  display: flex;
+  align-items: flex-start;
+}
+
+.s_b_m_ti_title > span:nth-of-type(1) {
+  font-size: 30px;
+  font-weight: bold;
+  color: #3681fc;
+  min-height: 30px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin-top: -3px;
+}
+
+.s_b_m_ti_title > svg {
+  width: 30px;
+  height: 30px;
+  min-width: 30px;
+  min-height: 30px;
+  margin: 0 10px 0 0px;
+}
+
+.s_b_m_ti_title > span:nth-of-type(2) {
+  font-size: 20px;
+  font-weight: bold;
+  display: flex;
+  flex-wrap: wrap;
+  align-items: center;
+  min-height: 30px;
+  line-height: 30px;
+  color: #1f1f1f;
+}
+
+.s_b_m_ti_title > div {
+  font-size: 30px;
+  font-weight: bold;
+}
+
+/* 选择题 */
+</style>

+ 791 - 0
src/components/pages/workPage/index_new.vue

@@ -0,0 +1,791 @@
+<template>
+  <div class="workPage" v-loading="loading">
+    <!-- <div class="wp_tool wp_tool15" v-if="workData && workData.type == 15">
+      <div class="wp_t15_title">{{ workData.json.answerQ }}</div>
+      <span class="wp_type">问答题</span>
+      <div class="wp_tl15_inputArea">
+        <el-input
+          type="textarea"
+          :rows="7"
+          placeholder="请在此输入您的答案..."
+          resize="none"
+          v-model="workData.json.answer"
+        >
+        </el-input>
+      </div>
+      <div class="wp_tl15_uploadFileArea">
+        <div
+          class="wp_tl_btn"
+          @click="uploadImage()"
+          v-loading="loadingUploadFile"
+        >
+          <svg
+            t="1755158440992"
+            class="icon"
+            viewBox="0 0 1024 1024"
+            version="1.1"
+            xmlns="http://www.w3.org/2000/svg"
+            p-id="8270"
+            width="200"
+            height="200"
+          >
+            <path
+              d="M924 1024H100A100 100 0 0 1 0 924V638a40 40 0 0 1 80 0v286a20 20 0 0 0 20 20h824a20 20 0 0 0 20-20V638a40 40 0 0 1 80 0v286a100 100 0 0 1-100 100zM784 352a40 40 0 0 1-28-12L512 97 268 340a40 40 0 0 1-57-57L484 12a40 40 0 0 1 57 0l271 272a40 40 0 0 1-28 68z"
+              fill="#474747"
+              p-id="8271"
+            ></path>
+            <path
+              d="M512 788a40 40 0 0 1-40-40V57a40 40 0 0 1 80 0v691a40 40 0 0 1-40 40z"
+              fill="#474747"
+              p-id="8272"
+            ></path>
+          </svg>
+          <span>上传图片</span>
+        </div>
+        <span>支持JPG、PNG格式,最大5MB</span>
+      </div>
+
+      <div class="wp_tl15_fileList">
+        <div
+          class="wp_tl15_fileList_item"
+          v-for="(item, index) in workData.json.fileList"
+          :key="index"
+        >
+          <img :src="item.url" alt="" @click="previewImage(item)" />
+          <svg
+            @click="deleteFile(index)"
+            t="1755162206922"
+            class="icon"
+            viewBox="0 0 1024 1024"
+            version="1.1"
+            xmlns="http://www.w3.org/2000/svg"
+            p-id="9357"
+            width="200"
+            height="200"
+          >
+            <path
+              d="M512 883.2A371.2 371.2 0 1 0 140.8 512 371.2 371.2 0 0 0 512 883.2z m0 64a435.2 435.2 0 1 1 435.2-435.2 435.2 435.2 0 0 1-435.2 435.2z"
+              fill="#d81e06"
+              p-id="9358"
+            ></path>
+            <path
+              d="M557.056 512l122.368 122.368a31.744 31.744 0 1 1-45.056 45.056L512 557.056l-122.368 122.368a31.744 31.744 0 1 1-45.056-45.056L466.944 512 344.576 389.632a31.744 31.744 0 1 1 45.056-45.056L512 466.944l122.368-122.368a31.744 31.744 0 1 1 45.056 45.056z"
+              fill="#d81e06"
+              p-id="9359"
+            ></path>
+          </svg>
+        </div>
+      </div>
+    </div>
+
+    <div class="wp_tool wp_tool45" v-if="workData && workData.type == 45">
+      <div class="wp_t45_title">练一练</div>
+      <div
+        class="s_b_m_toolItem"
+        v-for="(item, index) in workData.json.testJson"
+        :key="index + '_' + workData.id"
+      >
+        <div class="s_b_m_ti_title">
+          <span>{{ index + 1 }}</span>
+          <svg
+            width="16"
+            height="16"
+            viewBox="0 0 16 16"
+            fill="none"
+            xmlns="http://www.w3.org/2000/svg"
+          >
+            <path
+              d="M15.3536 8.35355C15.5488 8.15829 15.5488 7.84171 15.3536 7.64645L12.1716 4.46447C11.9763 4.2692 11.6597 4.2692 11.4645 4.46447C11.2692 4.65973 11.2692 4.97631 11.4645 5.17157L14.2929 8L11.4645 10.8284C11.2692 11.0237 11.2692 11.3403 11.4645 11.5355C11.6597 11.7308 11.9763 11.7308 12.1716 11.5355L15.3536 8.35355ZM1 8.5H15V7.5H1V8.5Z"
+              fill="#3681FC"
+            />
+          </svg>
+
+          <span
+            ><span
+              v-html="
+                renderedFormula(
+                  `<span style='color: #3681FC;''>${
+                    item.type == 1 ? '(单选题):' : '(多选题):'
+                  }</span>${item.teststitle}`
+                )
+              "
+            ></span>
+          </span>
+        </div>
+        <div
+          class="s_b_m_ti_option"
+          v-for="(item2, index2) in item.checkList"
+          @click="chooseAnswer(index, index2)"
+          :key="index + '_' + index2 + 'index2T'"
+          :class="{
+            s_b_m_ti_o_choice:
+              item.type == '1'
+                ? workData.json.testJson[index].userAnswer === index2
+                : workData.json.testJson[index].userAnswer.includes(index2)
+          }"
+        >
+          <div class="s_b_m_ti_o_btn">
+            <span class="s_b_m_ti_o_btn1" v-if="item.type == 1">
+              <span
+                v-if="workData.json.testJson[index].userAnswer === index2"
+              ></span>
+            </span>
+            <span class="s_b_m_ti_o_btn2" v-else>
+              <span
+                v-if="workData.json.testJson[index].userAnswer.includes(index2)"
+              >
+              </span>
+            </span>
+          </div>
+          <span>
+            <img
+              v-if="item2.imgType && item2.imgType === 1"
+              :src="item2.src"
+              alt=""
+              @click.stop="$hevueImgPreview(item2.src)"
+            />
+            <span v-else>{{ item2 }}</span>
+          </span>
+        </div>
+      </div>
+    </div> -->
+  <questionsAndAnswers ref="questionsAndAnswersRef" v-if="workData.type === '15'" :workData="workData" @changeWorkData="changeWorkData"/>
+  <choiceQuestion ref="choiceQuestionRef" v-if="workData.type === '45'" :workData="workData" @changeWorkData="changeWorkData"/>
+  </div>
+</template>
+
+<script>
+import katex from "katex";
+import "katex/dist/katex.min.css";
+import questionsAndAnswers from "./components/questionsAndAnswers.vue";
+import choiceQuestion from "./components/choiceQuestion.vue";
+export default {
+  components:{
+    questionsAndAnswers,
+    choiceQuestion
+  },
+  data() {
+    return {
+      id: this.$route.query.id,
+      courseid: this.$route.query.courseid,
+      userid: this.$route.query.userid,
+      oid: this.$route.query.oid,
+      org: this.$route.query.org,
+      role: this.$route.query.role,
+      stage: this.$route.query.stage,
+      task: this.$route.query.task,
+      tool: this.$route.query.tool,
+      type: "",
+      cid: this.$route.query.cid,
+      workData: {},
+      loadingUploadFile: false,
+      studentWork: null,
+      loading: false
+    };
+  },
+  watch: {
+    workData: {
+      deep: true,
+      handler(newValue) {
+        if (newValue) {
+          this.setWorkDataToWindow();
+        }
+      }
+    }
+  },
+  computed: {
+    renderedFormula() {
+      return function(val) {
+        try {
+          // 判断是否含有HTML标签,<tag ...>...</tag>
+          const hasTag = /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g.test(
+            val
+          );
+          if (!hasTag) {
+            val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+
+            // 纯文本,整体渲染
+            try {
+              return katex.renderToString(val.trim(), {
+                throwOnError: false,
+                strict: false,
+                output: "htmlAndMathml"
+              });
+            } catch (e) {
+              return val; // 渲染失败原样输出
+            }
+          } else {
+            // 有标签,对每个标签内容渲染
+            return val.replace(
+              /<([a-zA-Z][\w\-]*)([^>]*)>([\s\S]*?)<\/\1>/g,
+              (match, tag, attrs, inner) => {
+                let html;
+                val = val.trim().replace(/[\u200B-\u200D\uFEFF]/g, "");
+                try {
+                  html = katex.renderToString(inner.trim(), {
+                    throwOnError: false,
+                    strict: false,
+                    output: "htmlAndMathml"
+                  });
+                } catch (e) {
+                  html = inner;
+                }
+                return `<${tag}${attrs}>${html}</${tag}>`;
+              }
+            );
+          }
+        } catch (e) {
+          console.error("KaTeX渲染错误:", e);
+          return val;
+        }
+      };
+    }
+  },
+  methods: {
+    getWorkData() {
+      if (!this.id) return console.log("无作业id");
+      let params = {
+        id: this.id
+      };
+      this.ajax
+        .get(this.$store.state.api + "select_workPageById", params)
+        .then(res => {
+          let _data = res.data[0];
+          if (_data.length) {
+            _data = _data[0];
+            _data.json = JSON.parse(_data.json);
+            if (_data.type == 15) {
+              _data.json.answer = "";
+              _data.json.fileList = [];
+            } else if (_data.type == 45) {
+              _data.json.testJson.forEach(item => {
+                if (item.type == "2") {
+                  item.userAnswer = [];
+                } else if (item.type == "1") {
+                  item.userAnswer = "";
+                }
+              });
+            }
+
+            this.workData = _data;
+            this.studentWorkToWorkData();
+          }
+        });
+    },
+    setWorkDataToWindow() {
+      if (this.workData.json) {
+        window.workData = JSON.parse(JSON.stringify(this.workData));
+      }
+    },
+    uploadImage() {
+      if (this.loadingUploadFile) return;
+      let input = document.createElement("input");
+      input.type = "file";
+      input.accept = "image/jpeg,image/png";
+      input.click();
+      input.onchange = e => {
+        let file = e.target.files[0];
+        if (file) {
+          if (file.size > 5 * 1024 * 1024) {
+            // 5MB
+            return this.$message.error("图片大小不能超过5MB");
+          }
+          let _type = file.type;
+          let _size = file.size;
+          this.loadingUploadFile = true;
+          this.uploadFile(file).then(res => {
+            let _file = {
+              name: file.name,
+              url: res.Location,
+              type: _type,
+              size: _size,
+              uploadTime: new Date().getTime()
+            };
+            if (["15"].includes(this.workData.type)) {
+              this.workData.json.fileList.push(_file);
+            }
+            this.$forceUpdate();
+            this.loadingUploadFile = false;
+          });
+        }
+      };
+    },
+    uploadFile(file) {
+      return new Promise(resolve => {
+        var credentials = {
+          accessKeyId: "AKIATLPEDU37QV5CHLMH",
+          secretAccessKey: "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"
+        }; //秘钥形式的登录上传
+        window.AWS.config.update(credentials);
+        window.AWS.config.region = "cn-northwest-1"; //设置区域
+
+        var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+        var _this = this;
+
+        if (file) {
+          var params = {
+            Key:
+              file.name.split(".")[0] +
+              new Date().getTime() +
+              "." +
+              file.name.split(".")[file.name.split(".").length - 1],
+            ContentType: file.type,
+            Body: file,
+            "Access-Control-Allow-Credentials": "*",
+            ACL: "public-read"
+          }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+          var options = {
+            partSize: 2048 * 1024 * 1024,
+            queueSize: 2,
+            leavePartsOnError: true
+          };
+          bucket
+            .upload(params, options)
+            .on("httpUploadProgress", function(evt) {
+              //这里可以写进度条
+              // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            })
+            .send(function(err, data) {
+              if (err) {
+                _this.$message.error("上传失败");
+                resolve(null);
+              } else {
+                resolve(data);
+              }
+            });
+        }
+      });
+    },
+    //预览图片
+    previewImage(url) {
+      this.$hevueImgPreview(url);
+    },
+    deleteFile(index) {
+      this.workData.json.fileList.splice(index, 1);
+      this.$forceUpdate();
+    },
+    submitWork(task) {
+      return new Promise(resolve => {
+        let params = [];
+        if (this.workData.type == "15") {
+          //问答题
+          params.push({
+            uid: this.userid,
+            cid: this.courseid,
+            stage: 0,
+            task: task,
+            tool: 0,
+            atool: "15",
+            content: encodeURIComponent(JSON.stringify(this.workData.json)),
+            type: "3"
+          });
+        } else if (this.workData.type == "45") {
+          //选择题
+          params.push({
+            uid: this.userid,
+            cid: this.courseid,
+            stage: 0,
+            task: task,
+            tool: 0,
+            atool: "45",
+            content: encodeURIComponent(JSON.stringify(this.workData.json)),
+            type: "8"
+          });
+        }
+        if (
+          ["3", "8"].includes(params[0].type) &&
+          params[0].uid &&
+          params[0].cid
+        ) {
+          this.loading = true;
+          this.ajax
+            .post(this.$store.state.api + "addCourseWorks_workPage", params)
+            .then(res => {
+              let _data = res.data[0];
+              this.loading = false;
+              if (_data.length > 0) {
+                let _id = _data[0].id;
+                resolve(_id);
+              } else {
+                resolve("");
+              }
+            })
+            .catch(err => {
+              console.log(err);
+              resolve("");
+              this.loading = false;
+            });
+        }
+      });
+    },
+    //选择题选择
+    chooseAnswer(index, index2) {
+      if (this.workData.json.testJson[index].type == "1") {
+        this.workData.json.testJson[index].userAnswer = index2;
+      } else if (this.workData.json.testJson[index].type == "2") {
+        if (this.workData.json.testJson[index].userAnswer.includes(index2)) {
+          this.workData.json.testJson[index].userAnswer.splice(
+            this.workData.json.testJson[index].userAnswer.indexOf(index2),
+            1
+          );
+        } else {
+          this.workData.json.testJson[index].userAnswer.push(index2);
+        }
+      }
+    },
+    //获取已经提交的作业
+    getSubmitWork() {
+      if (
+        this.userid &&
+        this.courseid &&
+        this.stage &&
+        this.task &&
+        this.tool
+      ) {
+        let params = {
+          uid: this.userid,
+          cid: this.courseid,
+          stage: this.stage,
+          task: this.task,
+          tool: this.tool
+        };
+        this.loading = true;
+        this.ajax
+          .get(
+            this.$store.state.api + "select_courseWorks_workPageData",
+            params
+          )
+          .then(res => {
+            let _data = res.data[0];
+            this.loading = false;
+            if (_data.length) {
+              _data = _data[0];
+              if (["15", "45"].includes(_data.atool)) {
+                let _work = JSON.parse(decodeURIComponent(_data.content));
+                this.studentWork = _work;
+                this.studentWorkToWorkData();
+              }else{
+                console.log("工具不一致")
+              }
+            }
+          })
+          .catch(err => {
+            this.loading = false;
+            console.error(err);
+          });
+      }
+    },
+    studentWorkToWorkData() {
+      if (this.studentWork && this.workData) {
+        console.log("studentWork", this.studentWork);
+        console.log("workData", this.workData);
+
+        let _work = JSON.parse(JSON.stringify(this.studentWork));
+        if (this.workData.type == "15") {
+          this.workData.json.answer = _work.answer;
+          this.workData.json.fileList = _work.fileList;
+        } else if (this.workData.type == "45") {
+          this.workData.json.testJson.forEach((item, index) => {
+            if (
+              item.type == _work.testJson[index].type &&
+              item.teststitle == _work.testJson[index].teststitle &&
+              JSON.stringify(item.checkList) ==
+                JSON.stringify(_work.testJson[index].checkList)
+            ) {
+              this.workData.json.testJson[index].userAnswer =
+                _work.testJson[index].userAnswer;
+            }
+          });
+        }
+        this.$forceUpdate();
+      }
+    },
+
+    //更新workData
+    changeWorkData(newValue){
+      console.log("changeWorkData",newValue)
+      this.workData.json = JSON.parse(newValue)
+    }
+  },
+  mounted() {
+    this.getWorkData();
+    this.getSubmitWork();
+    window.submitWork = this.submitWork;
+  }
+};
+</script>
+
+<style scoped>
+.workPage {
+  width: 100%;
+  height: 100%;
+  min-height: 100%;
+
+  background-color: #fff;
+  overflow: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+}
+
+.wp_tool {
+  width: 100%;
+  height: auto;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  padding: 40px 0;
+}
+
+.wp_t15_title {
+  font-size: 40px;
+  font-weight: 300;
+  margin: 20px 0;
+  max-width: 50%;
+  min-width: 300px;
+  text-align: left;
+}
+
+.wp_type {
+  margin: 20px 0;
+  font-size: 1em;
+  color: #7b7b7b;
+}
+
+.wp_tl15_inputArea {
+  width: 50%;
+  min-width: 300px;
+  margin: 20px 0;
+}
+
+.wp_tl15_inputArea >>> textarea {
+  border-color: #ececec;
+  border-radius: 10px;
+  padding: 10px 20px;
+  box-shadow: 0 0 10px #ececec;
+}
+
+.wp_tl15_inputArea >>> textarea::placeholder {
+  color: #7f7f7f;
+}
+
+.wp_tl15_uploadFileArea {
+  width: 50%;
+  min-width: 300px;
+  height: auto;
+  display: flex;
+  align-items: center;
+  margin-bottom: 10px;
+}
+
+.wp_tl_btn {
+  width: auto;
+  height: auto;
+  padding: 12px 16px;
+  background-color: #f9f9f9;
+  border-radius: 10px;
+  border: 1px dashed #e5e5e5;
+  font-size: 14px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  color: #474747;
+  cursor: pointer;
+  margin-right: 10px;
+  transition: 0.3s;
+}
+
+.wp_tl_btn:hover {
+  background-color: #ececec;
+}
+
+.wp_tl_btn > svg {
+  width: 15px;
+  height: 15px;
+  margin-right: 5px;
+}
+
+.wp_tl15_uploadFileArea > span {
+  font-size: 14px;
+  color: #686868;
+}
+
+.wp_tl15_fileList {
+  width: 50%;
+  min-width: 300px;
+  height: auto;
+  display: flex;
+  align-items: center;
+  flex-wrap: wrap;
+}
+
+.wp_tl15_fileList_item {
+  width: 150px;
+  height: 100px;
+  border-radius: 10px;
+  position: relative;
+  margin-right: 20px;
+}
+
+.wp_tl15_fileList_item:hover > svg {
+  display: block;
+}
+
+.wp_tl15_fileList_item > img {
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+  border-radius: 10px;
+  box-shadow: 0 0 10px #ececec;
+  margin: 10px;
+  cursor: pointer;
+}
+
+.wp_tl15_fileList_item > svg {
+  width: 20px;
+  height: 20px;
+  position: absolute;
+  right: -20px;
+  top: 1px;
+  cursor: pointer;
+  display: none;
+}
+
+/* 选择题 */
+
+.wp_tool45 {
+  width: 60%;
+  height: auto;
+}
+
+.wp_t45_title {
+  font-size: 3em;
+  font-weight: 300;
+  margin: 20px 0 40px 0;
+}
+
+.s_b_m_toolItem {
+  width: 100%;
+  height: auto;
+  margin-bottom: 40px;
+}
+
+.s_b_m_ti_option {
+  width: 100%;
+  height: auto;
+  padding: 15px 15px 15px 15px;
+  display: flex;
+  /* flex-wrap: wrap; */
+  background-color: #f3f7fd;
+  border-radius: 30px;
+  margin: 10px 0 10px 0px;
+  box-sizing: border-box;
+  cursor: pointer;
+}
+
+.s_b_m_ti_option > span > img {
+  max-height: 150px;
+  border-radius: 2px;
+  cursor: pointer;
+}
+
+.s_b_m_ti_o_btn {
+  width: 20px;
+  height: 100%;
+  min-height: 20px;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  margin-right: 10px;
+}
+
+.s_b_m_ti_o_btn > span {
+  width: 20px;
+  height: 20px;
+  display: block;
+  box-sizing: border-box;
+  border: solid 1px #3681fc;
+  overflow: hidden;
+}
+
+.s_b_m_ti_o_btn > span > span {
+  width: 100%;
+  height: 100%;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  background-color: #3681fc;
+  position: relative;
+}
+
+.s_b_m_ti_o_btn1 {
+  border-radius: 50%;
+}
+
+.s_b_m_ti_o_btn1 > span::after {
+  content: "";
+  width: 8px;
+  height: 8px;
+  position: absolute;
+  background-color: #fff;
+  border-radius: 50%;
+}
+
+.s_b_m_ti_o_btn2 {
+  border-radius: 2px;
+}
+
+.s_b_m_ti_o_btn2 > span::after {
+  content: "";
+  width: 8px;
+  height: 8px;
+  position: absolute;
+  background-color: #fff;
+}
+
+.s_b_m_ti_o_choice {
+  border: solid 1px #3681fc;
+}
+
+.s_b_m_ti_title {
+  display: flex;
+  align-items: flex-start;
+}
+
+.s_b_m_ti_title > span:nth-of-type(1) {
+  font-size: 30px;
+  font-weight: bold;
+  color: #3681fc;
+  min-height: 30px;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  margin-top: -3px;
+}
+
+.s_b_m_ti_title > svg {
+  width: 30px;
+  height: 30px;
+  min-width: 30px;
+  min-height: 30px;
+  margin: 0 10px 0 0px;
+}
+
+.s_b_m_ti_title > span:nth-of-type(2) {
+  font-size: 20px;
+  font-weight: bold;
+  display: flex;
+  flex-wrap: wrap;
+  align-items: center;
+  min-height: 30px;
+  line-height: 30px;
+  color: #1f1f1f;
+}
+
+.s_b_m_ti_title > div {
+  font-size: 30px;
+  font-weight: bold;
+}
+
+/* 选择题 */
+</style>

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

@@ -552,7 +552,7 @@ export default {
   },
   data() {
     return {
-      gotype:sessionStorage.getItem('gotype'),
+      gotype:(window.topU && window.topU.gotype) ?  window.topU.gotype : '',
       worksDialog:false,
       exportW:0,
       digNum:0,

+ 3 - 2
src/components/tools/hevue-img-preview/hevue-img-preview.vue

@@ -27,7 +27,7 @@
  *                                //.-~~~-~_--~- |-------~~~~~~~~
  *                                       //.-~~~--\
  *                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- * 
+ *
  *                               神兽保佑            永无BUG
  -->
 
@@ -259,7 +259,8 @@ export default {
       if (this.keyboard) {
         document.removeEventListener('keydown', this.keyHandleDebounce)
       }
-      this.show = false
+      this.show = false;
+      this.$forceUpdate();
     },
     initImg() {
       this.mobileScale = 1

+ 293 - 0
src/components/tools/uploadFileMixin.js

@@ -0,0 +1,293 @@
+import '../../common/aws-sdk-2.235.1.min.js'
+export const uploadFileMixin = {
+  data() {
+    return {
+      bucket: "", //aws上传接口
+      bucketname: "ccrb", //桶
+      partsize: 10 * 1024 * 1024, //10MB  分片
+      uploadid: "",
+    }
+  },
+  methods: {
+    //--------------------------分断上传保证稳定性
+    //初始化上传
+    // async init(){
+    // 	const credentials = {
+    // 	    accessKeyId: "AKIATLPEDU37QV5CHLMH",
+    // 	    secretAccessKey: "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",
+    // 	}; //秘钥形式的登录上传
+    // 	window.AWS.config.update(credentials);
+    // 	window.AWS.config.region = "cn-northwest-1"; //设置区域
+    // 	//桶的设置
+    // 	bucket = new window.AWS.S3({
+    // 	    params: {
+    // 	        Bucket: this.bucketname
+    // 	    }
+    // 	});
+    // 	return bucket;
+    // },
+    // 初始化上传入口
+    async initMultipartUpload(key, file) {
+      const params = {
+        Bucket: this.bucketname,
+        Key: key,
+        ContentType: file.type,
+        ACL: "public-read",
+      };
+      //创建一个续传通道
+      const data = await this.bucket.createMultipartUpload(params).promise();
+      return data.UploadId;
+    },
+    // 上传文件的某一部分
+    async uploadPart(file, keyname, uploadid, pn, start, end) {
+      //key可以设置为桶的相对路径,Body为文件, ACL最好要设置
+      var params = {
+        Bucket: this.bucketname,
+        Key: keyname,
+        // ContentType: file.type,
+        PartNumber: pn,
+        UploadId: uploadid,
+        Body: file.slice(start, end),
+        // "Access-Control-Allow-Credentials": "*",
+        // ACL: "public-read",
+      };
+      const result = await this.bucket.uploadPart(params).promise();
+      return { ETag: result.ETag, PartNumber: pn };
+    },
+    //完成分块上传
+    async completeMultipartUpload(parts, keyname, uploadid) {
+      const params = {
+        Bucket: this.bucketname,
+        Key: keyname,
+        MultipartUpload: { Parts: parts },
+        UploadId: uploadid,
+      };
+      return await this.bucket.completeMultipartUpload(params).promise();
+    },
+    // async abortMultipartUpload(key, uploadid) {
+    //   const params = {
+    //     Bucket: this.bucketname,
+    //     Key: key,
+    //     UploadId: uploadid,
+    //   };
+    //   let data = await this.bucket.abortMultipartUpload(params).promise();
+    //   this.$emit("delUpload", { index: this.index })
+
+    // },
+    //--------------------------------下面支持断点续传
+
+    //初始化亚马逊参数
+    async init() {
+      //秘钥形式的登录上传
+      const credentials = {
+        accessKeyId: "AKIATLPEDU37QV5CHLMH",
+        secretAccessKey: "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",
+        region: "cn-northwest-1",
+      };
+      window.AWS.config.update(credentials);
+      // window.AWS.config.region = "cn-northwest-1"; //设置区域
+      //桶的设置
+      this.bucket = new window.AWS.S3({
+        params: {
+          Bucket: this.bucketname,
+        },
+      });
+      return this.bucket;
+    },
+
+    //获取当前文件是否有已上传断点信息
+    async getawscheckpoint(key) {
+      let partsinfo;
+      try {
+        const result = await this.bucket
+          .listMultipartUploads({ Bucket: this.bucketname, Prefix: key })
+          .promise();
+        //获取具体分片信息
+        if (result.Uploads.length) {
+          this.uploadid = result.Uploads[result.Uploads.length - 1].UploadId;
+          partsinfo = await this.bucket
+            .listParts({
+              Bucket: this.bucketname,
+              Key: key,
+              UploadId: this.uploadid,
+            })
+            .promise();
+        }
+      } catch (err) {
+        console.log(err);
+      }
+      return { uploadid: this.uploadid, partsinfo };
+    },
+
+    //分段上传
+    async awsuploadpart(file, uploadid, parts, key) {
+      var partarr = []; //已完成的数组
+      //已完成的分片,转化成提交格式
+      const completeparts = parts.map((_) => {
+        partarr.push(_.PartNumber);
+        return { PartNumber: _.PartNumber, ETag: _.ETag };
+      });
+      // 分块上传文件
+      // parts = [];
+      let uploadpart;
+      let start = 0;
+      let end = 0;
+      let len = Math.ceil(file.size / this.partsize); //循环的长度
+      //循环上传
+      for (let i = 0; i < len; i++) {
+        start = i * this.partsize;
+        end = (i + 1) * this.partsize;
+        if (!partarr.includes(i + 1)) {
+          uploadpart = await this.uploadPart(
+            file,
+            key,
+            uploadid,
+            i + 1,
+            start,
+            end
+          );
+          if (uploadpart.ETag != null) {
+            completeparts.push(uploadpart);
+            partarr.push(uploadpart.PartNumber);
+          } else {
+            return;
+          }
+        }
+      }
+      //提交上传成功信息
+      let data = await this.completeMultipartUpload(
+        completeparts,
+        key,
+        uploadid
+      );
+      return data;
+    },
+
+    //上传的接口
+    async awsupload({ file, path }) {
+
+      return new Promise((resolve) => {
+        if (!file) {
+          this.$message.error("请上传文件")
+          return resolve(false)
+        };
+        this.init(); //初始化桶
+
+        let key = path;
+        if (!key) {
+          key = `default/${file.name.split(".")[0] + new Date().getTime() + "." + file.name.split(".")[file.name.split(".").length - 1]}`;
+        }
+        let params = {
+          Bucket: this.bucketname,
+          Key: key,
+        };
+        console.log('awsupload', file, path)
+        try {
+          //检查文件是否已上传
+          this.bucket.headObject(params, async (err, data) => {
+            // 没有上传成功,head方法会返回失败
+            if (err) {
+              //检查是否部分上传
+              const { uploadid, partsinfo } = await this.getawscheckpoint(
+                key,
+                this.bucket
+              );
+              //如果已经部分存在,那么直接在节点续传
+              if (uploadid) {
+                //断点续传
+                let data = await this.awsuploadpart(
+                  file,
+                  uploadid,
+                  partsinfo.Parts,
+                  key
+                );
+                return resolve(data)
+              }
+              //不存在,上传新的
+              else {
+                const uploadid = await this.initMultipartUpload(key, file); //初始化文件上传
+                let data = await this.awsuploadpart(
+                  file,
+                  uploadid,
+                  [],
+                  key
+                );
+                return resolve(data)
+              }
+            }
+            //如果已经上传成功了,那么直接返回状态百分百
+            else if (data) {
+              //data存在,上传成功
+              let url = `https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/${key}`
+              resolve({
+                Key: key,
+                Location: url,
+                ETag: data.ETag,
+                size: data.ContentLength,
+                ServerSideEncryption: data.ServerSideEncryption,
+                Bucket: this.bucketname
+              })
+            }
+          });
+        } catch (e) {
+          console.log("上传文件失败", e)
+          resolve(false);
+
+        }
+      })
+    },
+
+    //正常上传
+    defaultUploadFile(file, key) {
+      // const loading = this.openLoading();
+
+      return new Promise((resolve)=>{
+        var credentials = {
+          accessKeyId: "AKIATLPEDU37QV5CHLMH",
+          secretAccessKey: "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"
+        }; //秘钥形式的登录上传
+        window.AWS.config.update(credentials);
+        window.AWS.config.region = "cn-northwest-1"; //设置区域
+  
+        var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
+        var _this = this;
+  
+        if (file) {
+          var params = {
+            Key: key,
+            ContentType: file.type,
+            Body: file,
+            "Access-Control-Allow-Credentials": "*",
+            ACL: "public-read"
+          }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
+          var options = {
+            partSize: 2048 * 1024 * 1024,
+            queueSize: 2,
+            leavePartsOnError: true
+          };
+          bucket
+            .upload(params, options)
+            .on("httpUploadProgress", function (evt) {
+              //这里可以写进度条
+              // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
+            })
+            .send(function (err, data) {
+              // loading.close();
+              if (err) {
+                // var a = _this.$refs.upload1.uploadFiles;
+                // a.splice(a.length - 1, a.length);
+                resolve("")
+              } else {
+                resolve({
+                  name: file.name,
+                  url: data.Location,
+                  uid: file.uid
+                })
+  
+              }
+            });
+        }
+      })
+    },
+  }
+};

+ 2 - 2
src/config/config.js

@@ -10,7 +10,7 @@ const store = new Vuex.Store({
         userInfo: {},
         nCount: 0,
         report:"",
-		apiM: 'https://pbl.cocorobo.cn/api/mongo/',
+		    apiM: 'https://pbl.cocorobo.cn/api/mongo/',
         api: 'https://pbl.cocorobo.cn/api/pbl/',
         // fileApi: 'http://localhost:7004/file/',
         // fileApi: 'http://10.3.16.166:7004/file/',
@@ -27,4 +27,4 @@ const store = new Vuex.Store({
     }
 })
 
-export default store
+export default store

+ 65 - 0
src/router/index.js

@@ -147,6 +147,7 @@ import knowledge from '@/components/pages/knowledge/index'
 import sassPlatform from '@/components/pages/sassPlatform/index'
 import classroomObservationTest from '@/components/pages/classroomObservation/test.vue'
 import CourseCon from '@/components/pages/liyuan/CourseCon'
+import testReview from "@/components/pages/test/examine";
 import aiOffice from '@/components/pages/liyuan/aiOffice'
 import schoolSafe from '@/components/pages/liyuan/schoolSafe'
 import lyStudentEva from '@/components/pages/liyuan/studentEva'
@@ -157,6 +158,12 @@ import portraitL from '@/components/pages/liyuan/page/portrait'
 import teadTest from '@/components/pages/liyuan/page/teadTest'
 import Listudent from '@/components/pages/liyuan/page/student'
 import safeTest from '@/components/pages/liyuan/page/safeTest'
+import workPage from '@/components/pages/workPage/index'
+import workPageNew from '@/components/pages/workPage/index_new'
+import pptEasy from '@/components/pages/pptEasy/addCourse'
+import noticeCenter from '@/components/pages/noticeCenter/index'
+import PersonnelManagement from "@/components/pages/PersonnelManagement";
+import topTalent from "@/components/pages/liyuan/topTalent";
 
 // 全局修改默认配置,点击空白处不能关闭弹窗
 ElementUI.Dialog.props.closeOnClickModal.default = false
@@ -304,6 +311,15 @@ export default new Router({
       requireAuth: '' // 是否需要判断是否登录,这里是需要判断
     }
   },
+    {
+      path: "/topTalent",
+      name: "topTalent",
+      component: topTalent,
+      meta: {
+        keepAlive: true,
+        requireAuth: "" // 是否需要判断是否登录,这里是需要判断
+      }
+    },
   {
     path: '/course/addCourseE',
     component: addCourseE,
@@ -889,6 +905,14 @@ export default new Router({
       requireAuth: '' // 不需要鉴权
     }
   },
+    {
+      path: "/PersonnelManagement",
+      name: "PersonnelManagement",
+      component: PersonnelManagement,
+      meta: {
+        requireAuth: "" // 不需要鉴权
+      }
+    },
   {
     path: '/learnAna',
     name: 'learnAna',
@@ -1280,6 +1304,13 @@ export default new Router({
       keepAlive: true,
       requireAuth: ""//不需要鉴权
     }
+  },{
+      path: "/testReview",
+      name: "testReview",
+      component: testReview,
+      meta: {
+        requireAuth: "" // 不需要鉴权
+      }
   }, {
     path: "/aiOffice",
     name: "aiOffice",
@@ -1364,5 +1395,39 @@ export default new Router({
           requireAuth: '' // 不需要鉴权
       }
   },
+  {
+    path: '/workPage',
+    name: 'workPage',
+    component: workPage,
+    meta: {
+      requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+    }
+  },
+  {
+    path: '/workPageNew',
+    name: 'workPageNew',
+    component: workPageNew,
+    meta: {
+      requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+    }
+  },
+  {
+    path:"/pptEasy",
+    name:"pptEasy",
+    component:pptEasy,
+    meta:{
+      requireAuth:''//不需要鉴权
+    }
+  },
+  {
+    path:"/noticeCenter",
+    name:"noticeCenter",
+    component:noticeCenter,
+    meta:{
+      requireAuth:''//不需要鉴权
+    }
+  },
+
+
   ]
 })

+ 33 - 0
src/router/index2.js

@@ -0,0 +1,33 @@
+import Vue from 'vue'
+import Router from 'vue-router'
+import { Dialog } from 'element-ui'
+import 'element-ui/lib/theme-chalk/index.css'
+
+// 使用路由懒加载,按需加载组件
+import workPage from '@/components/pages/workPage/index'
+import workPageNew from '@/components/pages/workPage/index_new'
+
+// 全局修改默认配置,点击空白处不能关闭弹窗
+Dialog.props.closeOnClickModal.default = false
+Vue.use(Router)
+
+export default new Router({
+  routes: [
+  {
+    path: '/workPage',
+    name: 'workPage',
+    component: workPage,
+    meta: {
+      requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+    }
+  },
+  {
+    path: '/workPageNew',
+    name: 'workPageNew',
+    component: workPageNew,
+    meta: {
+      requireAuth: '' // 是否需要判断是否登录,这里是需要判断
+    }
+  }
+  ]
+})

+ 83 - 0
src/workPage/main.js

@@ -0,0 +1,83 @@
+// workPage 优化版入口 - 只引入必需的依赖
+import Vue from 'vue'
+import App from '../App'
+import router from '../router/index2'
+import store from '../config/config'
+
+// 只引入 workPage 需要的 Element UI 组件
+import { Loading, Input, Button, Dialog } from 'element-ui'
+import 'element-ui/lib/theme-chalk/index.css'
+
+import { myMessage } from '../components/tools/message'
+import ajax from '../common/axios.config'
+import VueCookies from 'vue-cookies'
+
+// workPage 需要的基础样式
+import '../assets/css/button.css'
+import '../assets/css/dialog.css'
+
+// 按需注册 Element UI 组件
+Vue.use(Loading)
+Vue.use(Input)
+Vue.use(Button)
+Vue.use(Dialog)
+Vue.use(VueCookies)
+
+Vue.config.productionTip = false
+Vue.prototype.$store = store
+Vue.prototype.ajax = ajax
+Vue.prototype.$message = myMessage
+Vue.prototype.$loading = Loading
+Vue.prototype.openLoading = function(target) {
+    const loading = this.$loading.service({
+        lock: true,
+        background: 'rgba(255, 255, 255, 0.7)',
+        target: target ? target : document.body,
+        body: true,
+    })
+    return loading
+}
+
+/* eslint-disable no-new */
+new Vue({
+    el: '#app',
+    router,
+    components: { App },
+    template: '<App/>'
+})
+
+VueCookies.config('30d')
+
+router.beforeEach((to, from, next) => {
+    if (to.meta.title) {
+        document.title = to.meta.title
+    }
+    const requireAuth = to.meta.requireAuth
+    if (requireAuth) {
+        var isLogin = VueCookies.get('tlogin')
+        if (isLogin == "1") {
+            var userinfo = VueCookies.get('teacherInfo')
+            store.commit("update", ["isLogin", true])
+            store.commit("update", ["userInfo", userinfo])
+            store.state.luyou = store.state.luyou + 1
+            store.commit("update", ["luyou", store.state.luyou])
+            next()
+        } else {
+            const loading = Loading.service({
+                background: "rgba(255, 255, 255)",
+                target: document.querySelector("body"),
+            })
+            store.commit("update", ["isLogin", false])
+            myMessage({
+                message: '未登录,请登录',
+                type: 'warning'
+            })
+            setTimeout(() => {
+                loading.close()
+                next('/login')
+            }, 2000)
+        }
+    } else {
+        next()
+    }
+})

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