Selaa lähdekoodia

Merge branch 'beta'

lsc 2 viikkoa sitten
vanhempi
commit
09758810f4

+ 1 - 1
dist/index.html

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

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


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/app.85f86278c7b962c3cc7c181d0ba98cc9.css.map


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


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


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/manifest.3eade43afd174522bb8a.js.map


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

@@ -1825,7 +1825,7 @@ ${message}`;
             content: `帮一下内容想一个名字命名作为word文档的名字,仅输出字符串即可 内容:${str}`
           }
         ],
-        stream: true,
+        stream: false,
         uid: this.userid,
         mind_map_question: ""
       });

+ 3 - 1
src/components/pages/aiEasy/evaList.vue

@@ -232,6 +232,8 @@ export default {
             let fileid = _this.knowFileids.length ? [..._this.knowFileids] : []
             let taskDetail = _this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].taskDetail ? _this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].taskDetail.replaceAll('\n', ' ') : ''
             let tool = _this.toolsData[_this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].toolChoose[_this.toolIndex].tool[0]].name
+            let toolindex = _this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].toolChoose[_this.toolIndex].tool[0]
+            let appJson = _this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].toolChoose[_this.toolIndex].appJson
             let toolDetail = _this.unitJson[0].chapterInfo[0].taskJson[_this.itemTaskIndex].toolChoose[_this.toolIndex].toolDetail.replaceAll('\n', ' ')
             let messages = `
 Language: ${this.getLang()}
@@ -259,7 +261,7 @@ Language: ${this.getLang()}
 #目标#
 你需要完成以下六个步骤:
 1.检索并学习上传文件的指定章节(高中(高一至高三)课程标准中的“学科核心素养与课程目标”章节,义务教育阶段(一年级至九年级)课程标准中的“课程目标”章节,《跨学科素养(参考)》文件),提取学科的核心素养并学习学科目标。
-2.你要参考第一步学习的学科目标,结合<任务描述:${taskDetail}><工具名称:${tool}>和<工具描述:${toolDetail}>生成适合当前作业的评价标准。评价标准用于评估学生的能力。
+2.你要参考第一步学习的学科目标,结合<任务描述:${taskDetail}><工具名称:${tool}>和<工具描述:${toolDetail}>${toolindex == 72 && appJson && appJson.name && `和<应用名称:${appJson.name}>`}${toolindex == 72 && appJson && appJson.detail && `和<应用描述:${appJson.detail}>`}生成适合当前作业的评价标准。评价标准用于评估学生的能力。
 3.你要精准地将评价标准匹配上传文件的核心素养和课程目标内容。第二步的评价标准是根据课程目标生成的,你要将这些评价标准与第一步提取的学科核心素养一一匹配。注意:所有的核心素养信息必须以上传文件的内容为依据,不可以使用其他的默认信息或者模版!避免使用上传文件中未出现的素养。
 4.只有当上传的文件包含《跨学科素养(参考)》时,执行该步骤。如果生成的评价标准难以与具体某个学科(如“语文”“英语”“劳动”)的国家课程标准匹配时,你可以将评价标准匹配该文件中提到的跨学科素养,如“合作能力”“认知能力”“创新能力”等。
 5.你要根据第一步生成的评价标准制定每一条标准的六级评价细则,这个评价细则将用于对学生能力的打分。

+ 25 - 6
src/components/pages/classroomObservation/components/analysisItem.vue

@@ -408,16 +408,35 @@ export default {
 
         // console.log('👇')
         // return console.log(_msg)
+        // let parm = {
+        //   assistant_id:
+        //     type == 0
+        //       ? assistant.agentid
+        //       : "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
+        //   message: type == 0 ? _msg : tips,
+        //   session_name: uuidv4(),
+        //   userId: this.userId,
+        //   file_ids: this.fileId ? [this.fileId] : "",
+        //   model: "gpt-4o-2024-11-20"
+        //   // model: "gpt-4o-mini"
+        // };
+
         let parm = {
-          assistant_id:
+          id:
             type == 0
               ? assistant.agentid
               : "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
           message: type == 0 ? _msg : tips,
           session_name: uuidv4(),
           userId: this.userId,
-          file_ids: this.fileId ? [this.fileId] : "",
-          model: "gpt-4o-2024-11-20"
+          file_ids: this.fileId ? [this.fileId] : [],
+          model: "gpt-4o-2024-11-20",
+          sound_url:"",
+          temperature:0.2,
+          top_p:1,
+          max_completion_tokens:4096,
+          stream:false,
+          uid:uuidv4()
           // model: "gpt-4o-mini"
         };
 
@@ -432,7 +451,7 @@ export default {
         // 	uid: _uid,
         // 	file_ids: this.fileId ? [this.fileId] : [],
         // };
-        if (!parm.assistant_id) {
+        if (!parm.id) {
           this.loading = false;
           this.loadNum = 2;
           return this.$message.error("未找到对应的AI助手");
@@ -452,9 +471,9 @@ export default {
         // 👆
 
         this.ajax
-          .post("https://gpt4.cocorobo.cn/ai_agent_park_chat", parm)
+          .post("https://appapi.cocorobo.cn/api/agentchats/ai_agent_chat", parm)
           .then(res => {
-            let _data = res.data.FunctionResponse;
+            let _data = res.data;
             // if (
             // 	!_data.message ||
             // 	_data.message.indexOf("由于我无法直接访问您上传的文件内容") > -1

+ 41 - 19
src/components/pages/classroomObservation/components/analysisSpecialItem.vue

@@ -632,7 +632,7 @@ export default {
 
       if (type == 1) {
         let _msg = `
-## 任务 
+## 任务
 请你结合 FIAS 相关的知识,根据以下提供给你的课堂原始数据(包含S和t的数据),请你具体描述整个课堂S行为与T行为的持续性与变化性。比如,课堂一开始老师占比主导,大约5分钟之后,进入到学生为主的小组讨论环节。在整个课堂之中,老师与学生的互动比较频繁,老师会频繁询问学生问题,引导学生思考。之后是授课时间与问答时间。等等。
 ## 输出要求 请使用自然语言进行描述,使用不超过5句完整的话进行整体性、概括性的描述,不要包含具体的时长信息。总结性概括之后,使用1句话对整个课堂的教师引导行为进行鼓励和评价,再使用1句话给出相应的优化建议。
 ## 你的知识库 定义与目的:S-T图,即学生-教师(Student-Teacher)图,主要用于记录和分析课堂上的学生行为(S)与教师行为(T)的时间分布。这种图形能够帮助教育专家和教师可视化课堂互动的流程,从而判断课堂的教学型态,如练习型、对话型、讲授型或混合型。 绘制方法:S-T图的绘制开始于教学的起始时刻,纵轴表示学生行为(S),横轴表示教师行为(T)。实际课堂观察或录像回放中,按照固定时间间隔(通常每30秒)采样,将对应的行为按时间顺序标记在相应的轴上。通过这种方法,可以清晰看到课堂上教师行为与学生行为的交替模式及其随时间的变化。 应用场景:例如,一个典型的应用是在分析不同类型课堂活动时使用S-T图。在讲授型课堂中,教师行为的时间占比会较高,S-T图显示较长的横轴(T行为)延续;而在练习型或对话型课堂中,学生行为的时间占比增高,显示为较长的纵轴(S行为)。
@@ -759,8 +759,8 @@ ${JSON.stringify(_dataList)}
 
       if (type == 1) {
         let _msg = `## 任务
-根据FIAS(弗兰德斯互动分析系统)理论,计算获得某一节课的RT和CH值。请你结合FIAS相关知识进行分析,使用3句完整的话对整个课堂进行分析,需注意包含这些内容:分析该课堂所属的教学模型,描述课堂的整体表现与特征,肯定老师做出的努力,以及给出相应的建议。 
-## 你的知识 
+根据FIAS(弗兰德斯互动分析系统)理论,计算获得某一节课的RT和CH值。请你结合FIAS相关知识进行分析,使用3句完整的话对整个课堂进行分析,需注意包含这些内容:分析该课堂所属的教学模型,描述课堂的整体表现与特征,肯定老师做出的努力,以及给出相应的建议。
+## 你的知识
 根据RT和CH的值,教学模式通常被分为以下几种类型: 练习型:RT ≤ 0.3,表示学生行为占主导,教师行为较少。 讲授型:RT ≥ 0.7,表示教师行为占主导,学生参与较少。 对话型:CH ≥ 0.4,表示师生之间有较多的互动和转换。 混合型:0.3 < RT < 0.7,CH < 0.4,表示教学中既有教师讲授也有学生参与,但两者都不占绝对优势。
 ## 数据
 RT:${_RT}
@@ -782,19 +782,34 @@ CH:${_CH}
       this.loading = false;
     },
     getAiContent(_msg) {
+      // let parm = {
+      //   assistant_id: "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
+      //   message: _msg,
+      //   session_name: uuidv4(),
+      //   userId: this.userId,
+      //   file_ids: "",
+      //   model: "gpt-4o-2024-11-20"
+      // };
+
       let parm = {
-        assistant_id: "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
-        message: _msg,
-        session_name: uuidv4(),
-        userId: this.userId,
-        file_ids: "",
-        model: "gpt-4o-2024-11-20"
+          id:"f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
+          message: _msg,
+          session_name: uuidv4(),
+          userId: this.userId,
+          file_ids: this.fileId ? [this.fileId] : [],
+          model: "gpt-4o-2024-11-20",
+          sound_url:"",
+          temperature:0.2,
+          top_p:1,
+          max_completion_tokens:4096,
+          stream:false,
+          uid:uuidv4()
       };
 
       this.ajax
-        .post("https://gpt4.cocorobo.cn/ai_agent_park_chat", parm)
+        .post("https://appapi.cocorobo.cn/api/agentchats/ai_agent_chat", parm)
         .then(res => {
-          let _data = res.data.FunctionResponse;
+          let _data = res.data;
           let _copyData = JSON.parse(JSON.stringify(this.data));
           _copyData.jsonData.content = _data.message;
           // _copyData.jsonData.dataFileList = [];
@@ -1016,15 +1031,21 @@ CH:${_CH}
         // console.log('👇')
         // return console.log(_msg)
         let parm = {
-          assistant_id:
+          id:
             type == 0
               ? assistant.agentid
               : "f8e1ebb2-2e0d-11ef-8bf4-12e77c4cb76b",
           message: type == 0 ? _msg : assistant.tips,
           session_name: uuidv4(),
           userId: this.userId,
-          file_ids: this.fileId ? [this.fileId] : "",
-          model: "gpt-4o-2024-11-20"
+          file_ids: this.fileId ? [this.fileId] : [],
+          model: "gpt-4o-2024-11-20",
+          sound_url:"",
+          temperature:0.2,
+          top_p:1,
+          max_completion_tokens:4096,
+          stream:false,
+          uid:uuidv4()
 					// model: "gpt-4o-mini"
         };
 
@@ -1039,7 +1060,7 @@ CH:${_CH}
         // 	uid: _uid,
         // 	file_ids: this.fileId ? [this.fileId] : [],
         // };
-        if (!parm.assistant_id) {
+        if (!parm.id) {
           this.loading = false;
           this.loadNum = 2;
           return this.$message.error("未找到对应的AI助手");
@@ -1059,9 +1080,10 @@ CH:${_CH}
         // 👆
 
         this.ajax
-          .post("https://gpt4.cocorobo.cn/ai_agent_park_chat", parm)
+          // .post("https://gpt4.cocorobo.cn/ai_agent_park_chat", parm)
+          .post("https://appapi.cocorobo.cn/api/agentchats/ai_agent_chat", parm)
           .then(res => {
-            let _data = res.data.FunctionResponse;
+            let _data = res.data;
             // if (
             // 	!_data.message ||
             // 	_data.message.indexOf("由于我无法直接访问您上传的文件内容") > -1
@@ -1089,7 +1111,7 @@ CH:${_CH}
             this.changeShowIndex(1);
             this.loading = false;
 						this.$nextTick(()=>{
-							
+
 							this.editEcharts(true);
 						})
           })
@@ -1153,7 +1175,7 @@ CH:${_CH}
 					}else if(this.$parent.$parent.$refs[`analysis_${i.value}`][0].$refs.dragBoxRefBottom){
 						this.dragBoxList.push(this.$parent.$parent.$refs[`analysis_${i.value}`][0].$refs.dragBoxRefBottom);
 					}
-          
+
         });
         // 禁用页面文本选择
         document.body.style.userSelect = "none";

+ 11 - 11
src/components/pages/course.vue

@@ -166,7 +166,7 @@
           </div>
         </div>
       </div>
-      <div class="student_table">
+      <div class="student_table" v-loading="isLoading">
         <div class="course_box">
           <div class="out_box" v-for="(item, index) in course" :key="index">
             <!-- <div class="myCourse" v-if="item.isCourseType == 1 && groupA == 0">
@@ -1129,11 +1129,11 @@ export default {
       this.getCourse();
     },
     getCourse() {
-      if (!this.loading) {
-        this.loading = this.openLoading(
-          document.querySelector(".student_table")
-        );
-      }
+      // if (!this.loading) {
+      //   this.loading = this.openLoading(
+      //     document.querySelector(".student_table")
+      //   );
+      // }
       // var typeE = [];
       // var typea, typeb, typec, typed;
       // if (this.isChoose == 1) {
@@ -1182,8 +1182,8 @@ export default {
       this.ajax
         .get(this.$store.state.api + "selectCourseNew2", params)
         .then((res) => {
-          this.loading.close();
-          this.loading = "";
+          // this.loading.close();
+          // this.loading = "";
           this.isLoading = false;
           this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
           this.course = res.data[0];
@@ -1225,9 +1225,9 @@ export default {
         type: "warning",
       })
         .then(() => {
-          const loading = this.openLoading(
-            document.querySelector(".student_table")
-          );
+          // const loading = this.openLoading(
+          //   document.querySelector(".student_table")
+          // );
           this.isLoading = true;
           let params = {
             cid: cid,

+ 6 - 7
src/components/pages/data.vue

@@ -173,7 +173,7 @@
                 :type="isLook ? 'type' : 'password'"
                 class="input"
                 v-model="password"
-                placeholder="请输入修改密码,长度为6-16位"
+                placeholder="长度为8-16位,且包含大小写字母"
               ></el-input>
               <div class="eye" @click="changeEye">
                 <img :src="isLook ? eye : eyeOff" alt="" />
@@ -187,7 +187,7 @@
                 :type="isLook ? 'type' : 'password'"
                 class="input"
                 v-model="password1"
-                placeholder="请再次输入修改密码,长度为6-16位"
+                placeholder="请再次输入修改密码"
               ></el-input>
               <div class="eye" @click="changeEye">
                 <img :src="isLook ? eye : eyeOff" alt="" />
@@ -402,11 +402,9 @@ export default {
         });
     },
     updatePassword() {
-      if (this.password.length < 6) {
-        this.$message.error("密码长度不少于6位");
-        return;
-      } else if (this.password.length > 16) {
-        this.$message.error("密码长度不能大于16位");
+      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("两次新密码不相同");
@@ -426,6 +424,7 @@ export default {
             this.$message.success("修改成功");
             this.opassword = "";
             this.password = "";
+            this.password1 = "";
           } else {
             this.$message.error("修改失败,原密码不正确");
           }

+ 3 - 3
src/components/pages/sz/teacher.vue

@@ -587,7 +587,7 @@ export default {
       if(/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)){
         mail = this.sMail;
       }else{
-        mail = this.sMail + "@" + this.userSuffix
+        mail = this.sMail + this.userSuffix
       }
       
       if (this.time()) {
@@ -621,7 +621,7 @@ export default {
       if(/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(this.sMail)){
         mail = this.sMail;
       }else{
-        mail = this.sMail + "@" + this.userSuffix
+        mail = this.sMail + this.userSuffix
       }
       let params = [
         {
@@ -888,7 +888,7 @@ export default {
             if(/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/.test(v["教师账号"])){
               obj.mail = v["教师账号"];
             }else{
-              obj.mail = v["教师账号"] + "@" + _this.userSuffix
+              obj.mail = v["教师账号"] + _this.userSuffix
             }
             obj.school = v["学校"];
             arr.push(obj);

+ 102 - 28
src/components/pages/test/add/components/timeBox/time.vue

@@ -1,10 +1,10 @@
 <template>
   <div class="c_box">
     <div class="mask" v-if="!isOpen"></div>
-    <div class="choice_box">
+    <div class="timeBox">
       <div class="title" style="display: flex;">
         <span @click.stop="updateTitle()" v-if="!updateList.title">{{
-          cJson.title
+          cJson.title?cJson.title:"输入问题"
         }}</span>
         <input
           v-if="updateList.title"
@@ -13,7 +13,7 @@
           v-model="checkJson.title"
           @blur="save"
           @keyup.enter="save"
-          placeholder="请填写标题"
+          placeholder="输入问题"
         />
       </div>
       <div
@@ -33,6 +33,46 @@
         @keyup.enter="save"
         placeholder="请填写描述"
       />
+
+      <div class="setting">
+        自定义筛选
+      </div>
+      <div v-for="(item, index) in checkJson.timeSort" :key="index">
+        <div
+          v-if="!updateList.timeSort[index]"
+          class="timeSortTitle"
+          @click.stop="updateTimeSortTitle(index)"
+        >
+          {{ item.title ? item.title : "筛选名称" }}
+        </div>
+        <input
+          v-if="updateList.timeSort[index]"
+          :ref="`timeSortTitle-${index}`"
+          class="editInput"
+          v-model="checkJson.timeSort[index].title"
+          @blur="save"
+          style="margin-top: 20px;"
+          @keyup.enter="save"
+          placeholder="请填写筛选名称"
+        />
+        <el-date-picker
+          style="margin-top: 10px;"
+          v-model="checkJson.timeSort[index].time"
+          type="datetimerange"
+          @blur="save"
+          range-separator="至"
+          start-placeholder="开始日期"
+          end-placeholder="结束日期"
+        >
+        </el-date-picker>
+
+      </div>
+      <el-button
+        size="mini"
+        icon="el-icon-plus"
+        style="margin-top: 20px;"
+        @click.stop="addTimeSort"
+      ></el-button>
     </div>
   </div>
 </template>
@@ -64,7 +104,8 @@ export default {
       checkJson: {},
       updateList: {
         title: false,
-        detail: false
+        detail: false,
+        timeSort: []
       }
     };
   },
@@ -73,22 +114,23 @@ export default {
       handler(newVal) {
         // console.log("测试测试保存",newVal)
         this.$emit("setJson", newVal, this.index);
+        this.$forceUpdate();
         console.log("gapW", this.cJson);
       },
       deep: true
     },
-		isOpen(newValue) {
-      if (newValue) {
-        if (!this.cJson2 || Object.keys(this.cJson2).length == 0) {
-          this.checkJson = {
-            title: "标题",
-            type: 1,
-            answer: ""
-          };
-        } else {
-          this.checkJson = this.depthCopy(this.cJson2);
-        }
-      }
+    isOpen(newValue) {
+      // if (newValue) {
+      //   if (!this.cJson2 || Object.keys(this.cJson2).length == 0) {
+      //     this.checkJson = {
+      //       title: "标题",
+      //       type: 1,
+      //       answer: ""
+      //     };
+      //   } else {
+      //     this.checkJson = this.depthCopy(this.cJson2);
+      //   }
+      // }
     }
   },
   methods: {
@@ -109,30 +151,51 @@ export default {
         this.$refs["detailRef"].focus();
       });
     },
+    updateTimeSortTitle(index) {
+      this.updateList.timeSort[index] = true;
+      this.$forceUpdate();
+      this.$nextTick(() => {
+        // 聚焦到输入框
+        // console.log(this.$refs[`timeSortTitle-${index}`])
+        this.$refs[`timeSortTitle-${index}`][0].focus();
+      });
+    },
     save() {
       for (let key in this.updateList) {
-        this.updateList[key] = false;
+        if ((key = "timeSort")) {
+          this.updateList.timeSort = [];
+        } else {
+          this.updateList[key] = false;
+        }
       }
+      this.$forceUpdate();
+    },
+    addTimeSort() {
+      if (!this.checkJson.timeSort) this.checkJson.timeSort = [];
+      this.checkJson.timeSort.push({ title: "", time: [] });
+      this.$forceUpdate();
     }
   },
   mounted() {
-    // if (!this.cJson || Object.keys(this.cJson).length == 0) {
-    //   this.checkJson = {
-    //     title: "标题",
-    //     detail: ""
-    //   };
-    // } else {
-    //   this.$nextTick(() => {
-    //     this.checkJson = this.depthCopy(this.cJson2);
-    //   });
-    // }
+    if (!this.cJson || Object.keys(this.cJson).length == 0) {
+      this.checkJson = {
+        title: "标题",
+        detail: "",
+        timeSort: []
+      };
+    } else {
+      this.$nextTick(() => {
+        this.checkJson = this.depthCopy(this.cJson);
+        if (!this.checkJson.timeSort) this.checkJson.timeSort = [];
+      });
+    }
   }
 };
 </script>
 
 <style scoped>
 @import "../../global_styles.css";
-.choice_box > .choices {
+.timeBox > .choices {
   margin-top: 10px;
 }
 
@@ -167,4 +230,15 @@ export default {
   color: rgb(124, 124, 124);
   border-radius: 5px;
 }
+
+.setting {
+  margin-top: 20px;
+}
+
+.timeSortTitle {
+  margin-top: 20px;
+}
+.detail{
+  margin-top: 10px;
+}
 </style>

+ 29 - 3
src/components/pages/test/check/index.vue

@@ -1240,6 +1240,7 @@
                         @change="tableDataPickerChange"
                         type="daterange"
                         range-separator="▼"
+                        :picker-options="pickerOptions(item.json.timeSort)"
                       >
                       </el-date-picker>
                     </div>
@@ -2101,6 +2102,28 @@ export default {
           value: child.id
         })) : null;
       };
+    },
+    pickerOptions(){
+      return (dataList)=>{
+        let _result = {
+          // shortcuts:[]
+        }
+        if(dataList && dataList.length>0){
+          _result.shortcuts = [];
+          for(let i = 0;i<dataList.length;i++){
+            if(dataList[i].time.length<=0)continue;
+            _result.shortcuts.push({
+              text:dataList[i].title?dataList[i].title:"-",
+              onClick(picker){
+                let startTime = dataList[i].time[0];
+                let endTime = dataList[i].time[1]
+                picker.$emit('pick', [startTime, endTime]);
+              }
+            })
+          }
+        }
+        return _result;
+      }
     }
   },
   methods: {
@@ -2711,7 +2734,8 @@ export default {
               delete item2.json.answer2;
               delete item2.json.score2;
               delete item2.json.file;
-              delete item2.json.codeScanningTime
+              delete item2.json.codeScanningTime;
+              delete item2.json.timeSort;
             }
             if (item2.array) {
               item2.array = item2.array.filter((item3) => {
@@ -2719,7 +2743,8 @@ export default {
                   delete item3.json.answer2;
                   delete item3.json.score2;
                   delete item3.json.file;
-                  delete item3.json.codeScanningTime
+                  delete item3.json.codeScanningTime;
+                  delete item3.json.timeSort;
                 }
                 return item3;
               });
@@ -2730,7 +2755,8 @@ export default {
           delete item.json.answer2;
           delete item.json.score2;
           delete item.json.file;
-          delete item.json.codeScanningTime
+          delete item.json.codeScanningTime;
+          delete item.json.timeSort;
         }
         return item;
         console.log(item.array);

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