SanHQin 5 kuukautta sitten
vanhempi
commit
05119d6535

Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/index.html


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 1 - 1
dist/report.html


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-03851ecf.9bbe621b.css


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-1738a278.ab580cb5.css


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-236ce05a.aca7f5f3.css


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-69694896.3f5d2bfe.css


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-75189236.5731fa68.css


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/css/chunk-c5533740.4dccc1e6.css


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


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-03851ecf.cd8d8610.js


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-1738a278.e5663b80.js


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-236ce05a.3b75ee9b.js


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


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-6ad98842.808bd219.js


Tiedoston diff-näkymää rajattu, sillä se on liian suuri
+ 0 - 0
dist/static/js/chunk-6ad98842.f22926cf.js


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


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


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


+ 18 - 12
src/views/appStore/index.vue

@@ -3,7 +3,7 @@
     <div class="as_header">
       <div class="as_h_top">
         <span>应用管理</span>
-        <el-button class="addBtn" type="primary" size="mini" @click="addAppFn">添加应用</el-button>
+        <!-- <el-button class="addBtn" type="primary" size="mini" @click="addAppFn">添加应用</el-button> -->
       </div>
       <div class="as_h_bottom">
         <el-input v-model="searchText" style="width:40%" placeholder="请输入应用名称" size="mini"></el-input>
@@ -37,6 +37,7 @@
               p-id="4275"
               width="200"
               height="200"
+							v-if="!item.json.icon"
             >
               <path
                 d="M179.2 153.6a51.2 51.2 0 0 0-51.2 51.2v128a51.2 51.2 0 0 0 51.2 51.2h128a51.2 51.2 0 0 0 51.2-51.2V204.8a51.2 51.2 0 0 0-51.2-51.2H179.2z m0-102.4h128a153.6 153.6 0 0 1 153.6 153.6v128a153.6 153.6 0 0 1-153.6 153.6H179.2a153.6 153.6 0 0 1-153.6-153.6V204.8a153.6 153.6 0 0 1 153.6-153.6z m0 614.4a51.2 51.2 0 0 0-51.2 51.2v128a51.2 51.2 0 0 0 51.2 51.2h128a51.2 51.2 0 0 0 51.2-51.2V716.8a51.2 51.2 0 0 0-51.2-51.2H179.2z m0-102.4h128a153.6 153.6 0 0 1 153.6 153.6v128a153.6 153.6 0 0 1-153.6 153.6H179.2a153.6 153.6 0 0 1-153.6-153.6V716.8a153.6 153.6 0 0 1 153.6-153.6z m611.84-403.4048a51.2 51.2 0 0 0-72.3968 0L646.144 232.2432a51.2 51.2 0 0 0 0 72.3968l72.448 72.3968a51.2 51.2 0 0 0 72.3968 0l72.3968-72.3968a51.2 51.2 0 0 0 0-72.3968L791.04 159.744z m72.3968-72.3968l72.3968 72.3968a153.6 153.6 0 0 1 0 217.2416l-72.3968 72.3968a153.6 153.6 0 0 1-217.2416 0l-72.3968-72.3968a153.6 153.6 0 0 1 0-217.2416l72.3968-72.3968a153.6 153.6 0 0 1 217.2416 0zM699.7504 896a51.2 51.2 0 0 1 0 102.4A162.1504 162.1504 0 0 1 537.6 836.2496v-110.8992A162.1504 162.1504 0 0 1 699.7504 563.2h110.8992a162.1504 162.1504 0 0 1 162.1504 162.1504v8.448a51.2 51.2 0 0 1-102.4 0v-8.448c0-33.024-26.7264-59.7504-59.7504-59.7504h-110.8992c-33.024 0-59.7504 26.7264-59.7504 59.7504v110.8992c0 33.024 26.7264 59.7504 59.7504 59.7504z"
@@ -49,6 +50,7 @@
                 p-id="4277"
               ></path>
             </svg>
+						<img :src="item.json.icon" alt="" v-else>
           </div>
           <div class="as_c_i_t_message">
             <div>{{ item.name }}</div>
@@ -59,14 +61,6 @@
 						<div class="popoverBox" v-if="showCardId===item.id">
 							<span @click="editAppFn(item)">编辑</span>
 						</div>
-						<!-- <van-popover trigger="click" placement="bottom-end">
-							<div class="as_c_i_t_p_content">
-								<span>编辑</span>
-							</div>
-							<template #reference>
-
-							</template>
-						</van-popover> -->
 					</div>
         </div>
         <div class="as_c_i_bottom">
@@ -122,7 +116,7 @@ export default {
       typeList: [],
       showType: '',
       searchText: '',
-      selectJuri: 1,
+      selectJuri: 3,
       selectList: [
         { index: 1, label: '我的' },
         { index: 2, label: '组织' },
@@ -151,6 +145,12 @@ export default {
         .then(res => {
           let _data = res[0]
           if (_data.length > 0) {
+						_data.forEach(i=>{
+							if(i.json){
+								i.json = JSON.parse(i.json)
+							}
+						})
+
             this.dataList = _data
           } else {
             this.dataList = []
@@ -287,12 +287,13 @@ export default {
 
 <style lang="scss" scoped>
 .appStore {
-  width: 100%;
+  width: 100vw;
   height: 100%;
   box-sizing: border-box;
   // padding: 5px;
   background-color: #f2f4f7;
   display: flex;
+	overflow: auto;
   flex-direction: column;
 }
 
@@ -324,6 +325,7 @@ export default {
   width: 100%;
   height: auto;
   padding: 10px 10px;
+	box-sizing: border-box;
 }
 
 .as_h_typeList {
@@ -350,7 +352,6 @@ export default {
   height: calc(100% - 100px);
   overflow: auto;
   box-sizing: border-box;
-  padding: 10px 5px 20px 5px;
   padding: 10px;
 }
 
@@ -392,6 +393,11 @@ export default {
   height: 100%;
 }
 
+.as_c_i_t_icon > img {
+  width: 100%;
+  height: 100%;
+}
+
 .as_c_i_t_name {
   width: calc(100% - 60px);
   height: 50px;

+ 3 - 3
src/views/classObserve/addTel.vue

@@ -11,8 +11,8 @@
       <div :class="[showIndex == 2 ? 'sl_active' : '']" @click.stop="showIndex = 2">扩展</div>
     </div>
     <div class="stencilList">
-      <div style="margin-bottom: 15px;" v-for="(item, index) in showDataList" :key="item.value+index">
-        <addStencil :data="item" :isChoice="choiceList.includes(item.value)"></addStencil>
+      <div style="margin-bottom: 15px;" v-for="(item, index) in showDataList" :key="item.id+'_'+index">
+        <addStencil :data="item" :isChoice="choiceList.includes(item.id)"></addStencil>
       </div>
     </div>
     <!-- <div class="stencilList">
@@ -52,7 +52,7 @@ export default {
     showDataList() {
       let result = []
       result = this.data.filter(i => {
-        return i.type == this.showIndex && i.title.indexOf(this.selectValue) != -1
+        return i.type == this.showIndex && i.name.indexOf(this.selectValue) != -1
       })
       return result
     }

+ 4 - 4
src/views/classObserve/components/addStencil.vue

@@ -1,16 +1,16 @@
 <template>
-    <div class="stencilledCon" @click.stop="$parent.addChoice(data.value)">
+    <div class="stencilledCon" @click.stop="$parent.addChoice(data.id)">
       <div class="top">
-        <div class="tit" v-text="data.title"></div>
+        <div class="tit" v-text="data.name"></div>
         <div class="btn">
           <img src="../../../assets/images/classObserve/Selected.png" alt="" v-if="isChoice"/>
         </div>
       </div>
-      <div class="con" v-text="data.brief">
+      <div class="con" v-text="data.detail">
         
       </div>
       <div class="bom">
-        <div>{{data.sum}}人已使用</div>
+        <div>{{data.count}}人已使用</div>
       </div>
     </div>
   </template>

+ 32 - 8
src/views/classObserve/components/analysisItem.vue

@@ -91,6 +91,10 @@ export default {
 		fileId:{
 			type:String,
 			default:""
+		},
+		dataList:{
+			type:Array,
+			default:()=>[]
 		}
   },
   components: {
@@ -144,28 +148,48 @@ export default {
     optimize() {
       this.show = false;
 			this.status = 1;
-			let assistant = this.analysisList.find(
-					(i) => i.title == this.data.jsonData.name
-				);
-			if (!assistant.value) {
+			let type = 0;//用angentId  1:用提示词   3:啥也没有
+			let tips = ""
+			// let assistant = this.analysisList.find((i) => i.title == this.data.jsonData.name);
+			let assistant = this.analysisList.find(i=>i.id==this.data.jsonData.mId) || this.analysisList.find(i=>i.name == this.data.jsonData.name)
+			if (!assistant) {
 					this.status = 2;
 					return this.$toast.fail("未找到对应的AI助手");
 				}
 			let _msg = `使用文件检索的方式完整的去分析文件内容,并请完全按照要求输出。`
 
-			if(['st1','st2','st3'].includes(assistant.value))return this.optimize2(assistant.value)
+			// if(['st1','st2','st3'].includes(assistant.value))return this.optimize2(assistant.value)
+
+			if(assistant.tips){
+				type = 1;
+				let analysisData = ``;
+				for(let i = 0;i<this.dataList.length;i++){
+					let _json = this.dataList[i].jsonData;
+					analysisData += `###${_json.anotherName ? _json.anotherName : _json.name}\n`
+					analysisData += `${_json.content}\n`
+				}
+				tips = assistant.tips.replaceAll("{analysisData}",analysisData)
+			}else if(assistant.agentid){
+				type = 0;
+			}else{
+				this.loading = false;
+				this.loadNum = 2;
+				type = 3;
+				return this.$toast.fail("未找到对应的AI助手");
+			}
+
 			if(assistant.value=='6b4a9650-48be-11ef-936b-12e77c4cb76b'){
 					_msg  = `使用文件检索的方式完整的去分析文件内容,并基于以下的课堂基本内容,使用cpote课程设计模型改编一堂同主题的课程。
 课堂名称:${this.bmData.courseName}  搜课年级:${this.bmData.grade}  授课科目:${this.bmData.subject}`
 					
 				}
 				let params = {
-					assistant_id: assistant?assistant.value:null,
-					message:_msg,
+					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-08-06",
+					model: "gpt-4o-2024-11-20",
 				};
 				chatRequest(params).then(res=>{
 					let _data = res.FunctionResponse;

+ 1 - 1
src/views/classObserve/homePage.vue

@@ -1435,7 +1435,7 @@ export default {
   .editorBarData {
     min-height: 100px;
     // max-height: 10vh;
-    height:100%;
+    height:calc(100% + 95px);
     position: relative;
     .ebd_save {
       right: 0;

+ 268 - 316
src/views/classObserve/index.vue

@@ -10,7 +10,7 @@
       :tid="tid"
       :bmData="bmData"
       :imageList="imageList"
-			:actionTypesMap="actionTypesMap"
+      :actionTypesMap="actionTypesMap"
     ></homePage>
     <bindFrom
       ref="bindFromRef"
@@ -29,7 +29,13 @@
       :bmData="bmData"
       :imageList="imageList"
     ></classInfo>
-    <stencilled ref="stencilledRef" @cutPage="cutPage" :page="page" :analysisList="analysisList" v-if="page == 5 && userId"></stencilled>
+    <stencilled
+      ref="stencilledRef"
+      @cutPage="cutPage"
+      :page="page"
+      :analysisList="analysisList"
+      v-if="page == 5 && userId"
+    ></stencilled>
     <editTel ref="editTelRef" @cutPage="cutPage" :dataList="dataList" :page="page" v-if="page == 6"></editTel>
     <!-- <addTel ref="addTelRef" @cutPage="cutPage" :page="page" v-if="page == 7"></addTel> -->
     <outcome
@@ -39,12 +45,13 @@
       v-show="page == 8"
       :bmData="bmData"
       :loading="[currencyLoading, scienceLoading, extendLoading]"
+      :dialogTagList="dialogTagList"
       :analysisList="analysisList"
       :fileId="fileId"
       :dataList="dataList"
       :tid="tid"
     />
-		<aiChat ref="aiChatRef" @cutPage="cutPage" :fileId="fileId" :tid="tid" v-if="page==9"/>
+    <aiChat ref="aiChatRef" @cutPage="cutPage" :fileId="fileId" :tid="tid" v-if="page == 9" />
   </div>
 </template>
 
@@ -59,6 +66,7 @@ import outcome from './outcome.vue'
 import aiChat from './aiChat.vue'
 import { v4 as uuidv4 } from 'uuid'
 import _ from 'lodash'
+import { mapGetters } from 'vuex'
 import {
   updateObsRequest,
   getCourseListRequest,
@@ -67,11 +75,12 @@ import {
   delObsRequest,
   getClassroomDefaultRequest,
   insertNewClassRoomRequest,
-  insertNewObsRequest
+  insertNewObsRequest,
+  getSModelList
 } from '@/api/classObserve'
 
 export default {
-  components: { homePage, bindFrom, classInfo, stencilled, editTel, addTel, outcome,aiChat },
+  components: { homePage, bindFrom, classInfo, stencilled, editTel, addTel, outcome, aiChat },
   data() {
     return {
       userId: this.$store.state.user.id,
@@ -109,221 +118,17 @@ export default {
       fileId: '',
       fileIdId: '',
       actionTypesMap: {},
-      analysisList: [
-        {
-          title: 'OMO智慧课堂分析',
-          brief: '多维度分析课堂整体情况',
-          value: '4cc367c1-0076-11ef-aaca-12e77c4cb76b',
-          type: 0,
-          sum: 157
-        },
-        {
-          title: '教学阶段九事件分析',
-          brief: '使用加涅九事件分析教学环节',
-          value: '5e0466b3-0075-11ef-aaca-12e77c4cb76b',
-          type: 0,
-          sum: 540
-        },
-        {
-          title: '布鲁姆问题分类',
-          brief: '不同认知层次问题分布情况',
-          value: 'eac63117-00a7-11ef-aaca-12e77c4cb76b',
-          type: 0,
-          sum: 405
-        },
-        {
-          title: '麦卡锡问题分类',
-          brief: '不同类型问题分布情况',
-          value: '18545cf7-0125-11ef-aaca-12e77c4cb76b',
-          type: 0,
-          sum: 360
-        },
-        {
-          title: '学生回答情况',
-          brief: '学生回答情况分析',
-          value: '2c6ede88-0125-11ef-aaca-12e77c4cb76b',
-          type: 0,
-          sum: 206
-        },
-        {
-          title: 'S-T分析:课堂时间分配',
-          brief: '多维度分析课堂整体情况',
-          value: 'st1',
-          type: 0,
-          sum: 451
-        },
-        {
-          title: 'S-T分析:师生互动分析',
-          brief: '多维度分析课堂整体情况',
-          value: 'st2',
-          type: 0,
-          sum: 342
-        },
-        {
-          title: 'S-T分析:教学模式分析',
-          brief: '多维度分析课堂整体情况',
-          value: 'st3',
-          type: 0,
-          sum: 143
-        },
-        {
-          title: '课堂活动类型',
-          brief: '识别特定的课堂活动类型',
-          value: '41d2d2d4-0125-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 430
-        },
-        {
-          title: '学科核心素养发展',
-          brief: '分析与学科核心素养的匹配情况',
-          value: 'a6c0b92b-06de-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 234
-        },
-        {
-          title: '科学教育目标分析',
-          brief: '分析四类科学教育目标的情况',
-          value: 'd6cd48ab-0125-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 513
-        },
-        {
-          title: 'PORTAAL课堂观察',
-          brief: '使用PORTAAL框架分析科学课堂',
-          value: '8ab07d41-e143-11ee-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 173
-        },
-        {
-          title: 'UTOP课堂观察',
-          brief: '使用UTOP框架分析科学课堂',
-          value: '8e3a389b-014f-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 329
-        },
-        {
-          title: 'L-PST模型',
-          brief: '使用L-PST框架分析科学课堂',
-          value: 'e649112e-0150-11ef-aaca-12e77c4cb76b', //e649112e-0150-11ef-aaca-12e77c4cb76b  7daa4c3f-016f-11ef-aaca-12e77c4cb76b
-          subject: '科学',
-          type: 1,
-          sum: 421
-        },
-        // {
-        // 	title: "RST模型",
-        // 	brief: "多维度分析课堂整体情况",
-        // 	value: "e649112e-0150-11ef-aaca-12e77c4cb76b",
-        // 	type: 1,
-        // },
-        {
-          title: 'RTOP课堂观察',
-          brief: '使用RTOP框架分析科学课堂',
-          value: '68265b18-0151-11ef-aaca-12e77c4cb76b', //a7107221-f7f5-11ee-aaca-12e77c4cb76b   bc254ab9-0142-11ef-aaca-12e77c4cb76b    c912ece9-0148-11ef-aaca-12e77c4cb76b  68265b18-0151-11ef-aaca-12e77c4cb76b  2ace7ff6-0154-11ef-aaca-12e77c4cb76b
-          subject: '科学',
-          type: 1,
-          sum: 527
-        },
-        {
-          title: '课程质量评价',
-          brief: '多维度分析课堂整体情况',
-          value: '25e53379-0152-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 391
-        },
-        {
-          title: 'SCOP课堂观察',
-          brief: '使用SCOP框架分析科学课堂',
-          value: 'd0c76d35-0152-11ef-aaca-12e77c4cb76b',
-          subject: '科学',
-          type: 1,
-          sum: 407
-        },
-        {
-          title: 'KWL教学策略',
-          brief: '分析课前、课中、课后的教学成果',
-          value: 'a5d8664b-1748-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 135
-        },
-        {
-          title: 'LICC课堂观察',
-          brief: '崔允漷教授团队的观察框架',
-          value: '9e8e6356-1769-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 614
-        },
-        {
-          title: '读思达教学法',
-          brief: '分析课堂阅读、思考、表达的情况',
-          value: 'd139ed78-176c-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 346
-        },
-        {
-          title: '教学内容分析',
-          brief: '从教学内容角度观课评教',
-          value: '9e8e6356-1769-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 527
-        },
-        {
-          title: '提问策略分析',
-          brief: '基于提问观察表分析课堂提问',
-          value: 'eb815b01-1769-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 389
-        },
-        {
-          title: '教师反馈分析',
-          brief: '分析语文课堂师生言语互动行为',
-          value: '55ae5176-176a-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 319
-        },
-        {
-          title: '师生互动分析',
-          brief: '分析语文课堂四种不同的互动状态',
-          value: '8e4b6b48-176a-11ef-aaca-12e77c4cb76b',
-          subject: '语文',
-          type: 1,
-          sum: 191
-        },
-        {
-          title: '5E课程改编',
-          brief: '基于5E教学模型设计一堂课',
-          value: 'f757826e-0125-11ef-aaca-12e77c4cb76b',
-          type: 2,
-          sum: 510
-        },
-        {
-          title: '5EX课程改编',
-          brief: '基于5EX教学模型设计一堂课',
-          value: '0b6b08b7-0126-11ef-aaca-12e77c4cb76b',
-          type: 2,
-          sum: 611
-        },
-        {
-          title: 'C-POTE课程改编',
-          brief: 'C-POTE课程改编',
-          value: '6b4a9650-48be-11ef-936b-12e77c4cb76b',
-          type: 2,
-          sum: 165
-        }
+      analysisList: [],
+      dialogTagList: [
+        { value: 0, name: '通用课堂分析', loading: false },
+        { value: 1, name: '学科课堂分析', loading: false },
+        { value: 2, name: '扩展分析', loading: false }
       ]
     }
   },
+  computed: {
+    ...mapGetters(['userinfo'])
+  },
   methods: {
     cutPage(val) {
       this.page = val
@@ -381,9 +186,9 @@ export default {
       let _flag = this.tid !== newTid
       this.tid = newTid
       if (_flag) {
-        this.getData().then(_=>{
-					this.$refs.homePageRef.init();
-				})
+        this.getData().then(_ => {
+          this.$refs.homePageRef.init()
+        })
       }
       // 获取fileId
       this.getFileIdId()
@@ -495,121 +300,258 @@ export default {
       })
     },
     //获取通用分析与基本信息
-    getCurrencyAndBaseMessageData() {
-      return new Promise(resolve => {
-        if (!this.tid) return
-        this.loading = true
-        this.currencyLoading = true
-        this.baseMessageLoading = true
-        getObsRequest({ tid: this.tid, type: '0' })
-          .then(res => {
-            let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
-            let _bmData = _data.find(i => i.tIndex == 0)
-            // 基础信息
-            _bmData.jsonData = JSON.parse(_bmData.jsonData)
-            _bmData.jsonData.time ? '' : (_bmData.jsonData.time = '')
-            _bmData.jsonData.editorBarData ? '' : (_bmData.jsonData.editorBarData = { type: '0', content: '', url: '' })
-            _bmData.jsonData.transcriptionData ? '' : (_bmData.jsonData.transcriptionData = '')
-            // 图片
-            let _imageList = _data.find(i => i.tIndex == 1)
-            _imageList.jsonData = JSON.parse(_imageList.jsonData)
+    // getCurrencyAndBaseMessageData() {
+    //   return new Promise(resolve => {
+    //     if (!this.tid) return
+    //     this.loading = true
+    //     this.currencyLoading = true
+    //     this.baseMessageLoading = true
+    //     getObsRequest({ tid: this.tid, type: '0' })
+    //       .then(res => {
+    //         let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
+    //         let _bmData = _data.find(i => i.tIndex == 0)
+    //         // 基础信息
+    //         _bmData.jsonData = JSON.parse(_bmData.jsonData)
+    //         _bmData.jsonData.time ? '' : (_bmData.jsonData.time = '')
+    //         _bmData.jsonData.editorBarData ? '' : (_bmData.jsonData.editorBarData = { type: '0', content: '', url: '' })
+    //         _bmData.jsonData.transcriptionData ? '' : (_bmData.jsonData.transcriptionData = '')
+    //         // 图片
+    //         let _imageList = _data.find(i => i.tIndex == 1)
+    //         _imageList.jsonData = JSON.parse(_imageList.jsonData)
 
-            if (!_imageList.jsonData.videoList) {
-              _imageList.jsonData.videoList = []
-            }
-            if (!_imageList.jsonData.NephogramList) {
-              _imageList.jsonData.NephogramList = []
-            }
+    //         if (!_imageList.jsonData.videoList) {
+    //           _imageList.jsonData.videoList = []
+    //         }
+    //         if (!_imageList.jsonData.NephogramList) {
+    //           _imageList.jsonData.NephogramList = []
+    //         }
 
-            let currency = []
-            for (let i = 2; i < _data.length; i++) {
-              let _currency = _data[i]
-              _currency.jsonData = JSON.parse(_currency.jsonData)
-              currency.push(_currency)
-            }
-            // 赋值
-            this.dataList.push(...currency)
-            this.bmData = _bmData
-            this.imageList = _imageList
+    //         let currency = []
+    //         for (let i = 2; i < _data.length; i++) {
+    //           let _currency = _data[i]
+    //           _currency.jsonData = JSON.parse(_currency.jsonData)
+    //           currency.push(_currency)
+    //         }
+    //         // 赋值
+    //         this.dataList.push(...currency)
+    //         this.bmData = _bmData
+    //         this.imageList = _imageList
 
-            this.baseMessageLoading = false
-            this.currencyLoading = false
-            this.loading = false
-            resolve()
-          })
-          .catch(e => {
-            console.log(e)
-            this.$toast.fail('获取通用分析失败')
-            resolve()
-          })
-      })
-    },
-    //获取学科分析
-    getScienceData() {
+    //         this.baseMessageLoading = false
+    //         this.currencyLoading = false
+    //         this.loading = false
+    //         resolve()
+    //       })
+    //       .catch(e => {
+    //         console.log(e)
+    //         this.$toast.fail('获取通用分析失败')
+    //         resolve()
+    //       })
+    //   })
+    // },
+    // //获取学科分析
+    // getScienceData() {
+    //   return new Promise(resolve => {
+    //     if (!this.tid) return
+    //     this.scienceLoading = true
+    //     getObsRequest({ tid: this.tid, type: '1' })
+    //       .then(res => {
+    //         let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
+    //         if (_data.length == 0) {
+    //           return (this.scienceLoading = false)
+    //         }
+    //         let science = []
+    //         for (let i = 0; i < _data.length; i++) {
+    //           let _science = _data[i]
+    //           _science.jsonData = JSON.parse(_science.jsonData)
+    //           science.push(_science)
+    //         }
+    //         this.dataList.push(...science)
+    //         this.scienceLoading = false
+    //         resolve()
+    //       })
+    //       .catch(e => {
+    //         console.log(e)
+    //         this.$toast.fail('获取科学分析失败')
+    //         resolve()
+    //       })
+    //   })
+    // },
+    // //获取扩展分析
+    // getExtendData() {
+    //   return new Promise(resolve => {
+    //     if (!this.tid) return
+    //     this.extendLoading = true
+    //     getObsRequest({ tid: this.tid, type: '2' })
+    //       .then(res => {
+    //         let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
+    //         if (_data.length == 0) {
+    //           return (this.extendLoading = false)
+    //         }
+    //         let extent = []
+    //         for (let i = 0; i < _data.length; i++) {
+    //           let _extent = _data[i]
+    //           _extent.jsonData = JSON.parse(_extent.jsonData)
+    //           extent.push(_extent)
+    //         }
+    //         this.dataList.push(...extent)
+    //         this.extendLoading = false
+    //         resolve()
+    //       })
+    //       .catch(e => {
+    //         console.log(e)
+    //         this.$toast('获取扩展分析失败')
+    //         resolve()
+    //       })
+    //   })
+    // },
+    getAnalysisData(type) {
+      if (!this.tid) return
+      let _copyTid = this.tid
       return new Promise(resolve => {
-        if (!this.tid) return
-        this.scienceLoading = true
-        getObsRequest({ tid: this.tid, type: '1' })
-          .then(res => {
-            let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
-            if (_data.length == 0) {
-              return (this.scienceLoading = false)
-            }
-            let science = []
-            for (let i = 0; i < _data.length; i++) {
-              let _science = _data[i]
-              _science.jsonData = JSON.parse(_science.jsonData)
-              science.push(_science)
+        let params = {
+          tid: this.tid,
+          type: type
+        }
+        this.dialogTagList.find(i => i.value == type)
+          ? (this.dialogTagList.find(i => i.value == type).loading = true)
+          : ''
+        if (type == 0) {
+          this.baseMessageLoading = true
+          this.bmData = {
+            id: '',
+            tId: this.tid,
+            tIndex: 0,
+            jsonData: {
+              activity_methods: '',
+              activity_structure: '',
+              classroom_resources: '',
+              courseName: '',
+              name: '',
+              studentNum: 0,
+              subject: '',
+              textbook: '',
+							editorBarData:{
+								type: '0',
+								content: '',
+								url: ''
+							},
+							transcriptionData:"",
             }
-            this.dataList.push(...science)
-            this.scienceLoading = false
-            resolve()
-          })
-          .catch(e => {
-            console.log(e)
-            this.$toast.fail('获取科学分析失败')
-            resolve()
-          })
-      })
-    },
-    //获取扩展分析
-    getExtendData() {
-      return new Promise(resolve => {
-        if (!this.tid) return
-        this.extendLoading = true
-        getObsRequest({ tid: this.tid, type: '2' })
+          }
+          this.imageList = {}
+          this.dataList = []
+          this.dialogTagList = [
+            { value: 0, name: '通用课堂分析', loading: true },
+            { value: 1, name: '学科课堂分析', loading: true },
+            { value: 2, name: '扩展分析', loading: true }
+          ]
+        }
+        getObsRequest(params)
           .then(res => {
+            if (_copyTid != this.tid) return
             let _data = res.FunctionResponse.result.length ? JSON.parse(res.FunctionResponse.result) : []
             if (_data.length == 0) {
-              return (this.extendLoading = false)
+              return (this.dialogTagList.find(i => i.value == type).loading = false)
             }
-            let extent = []
-            for (let i = 0; i < _data.length; i++) {
-              let _extent = _data[i]
-              _extent.jsonData = JSON.parse(_extent.jsonData)
-              extent.push(_extent)
+
+            if (type == 0) {
+              //第一个分析
+              let _bmData = _data.find(i => i.tIndex == 0)
+              let _dialogTagList = []
+              _bmData.jsonData = JSON.parse(_bmData.jsonData)
+              _bmData.jsonData.time ? '' : (_bmData.jsonData.time = '');
+              _bmData.jsonData.editorBarData? '': (_bmData.jsonData.editorBarData = { type: '0', content: '', url: '' });
+              _bmData.jsonData.transcriptionData ? '' : (_bmData.jsonData.transcriptionData = '');
+              _dialogTagList = _bmData.jsonData.dialogTagList || [
+                { value: 0, name: '通用课堂分析', loading: false },
+                { value: 1, name: '学科课堂分析', loading: false },
+                { value: 2, name: '扩展分析', loading: false }
+              ]
+              let _imageList = _data.find(i => i.tIndex == 1)
+              _imageList.jsonData = JSON.parse(_imageList.jsonData)
+              if (_imageList.jsonData.videoList) {
+                _imageList.jsonData.videoList = []
+              }
+              if (_imageList.jsonData.NephogramList) {
+                _imageList.jsonData.NephogramList = []
+              }
+
+              let currency = []
+              for (let i = 2; i < _data.length; i++) {
+                let _currency = _data[i]
+                _currency.jsonData = JSON.parse(_currency.jsonData)
+                currency.push(_currency)
+              }
+
+              this.dataList.push(...currency)
+              this.bmData = _bmData
+              this.dialogTagList = _dialogTagList
+              this.baseMessageLoading = false
+              this.dialogTagList.find(i => i.value == type)
+                ? (this.dialogTagList.find(i => i.value == type).loading = false)
+                : ''
+              resolve()
+            } else {
+              if (_data.length == 0) {
+                return (this.dialogTagList.find(i => i.value == type).loading = false)
+              }
+              let _analysisData = []
+              for (let i = 0; i < _data.length; i++) {
+                let _analysis = _data[i]
+                _analysis.jsonData = JSON.parse(_analysis.jsonData)
+                _analysisData.push(_analysis)
+              }
+              this.dataList.push(..._analysisData)
+              this.dialogTagList.find(i => i.value == type)
+                ? (this.dialogTagList.find(i => i.value == type).loading = false)
+                : ''
+              resolve()
             }
-            this.dataList.push(...extent)
-            this.extendLoading = false
-            resolve()
           })
           .catch(e => {
             console.log(e)
-            this.$toast('获取扩展分析失败')
+            this.$message.error('获取分析列表失败')
             resolve()
           })
       })
     },
     //获取全部的数据
-    getData() {
-      this.dataList = []
-      this.imageList = {}
+    getData(arr = []) {
       return new Promise(resolve => {
-        Promise.all([this.getCurrencyAndBaseMessageData(), this.getScienceData(), this.getExtendData()]).then(_ => {
-          console.log('所有分析获取完成')
-          resolve()
-        })
+        this.dataList = []
+        this.$forceUpdate()
+        this.loading = true
+        if (this.tid) {
+          return this.getAnalysisData(0).then(_ => {
+            this.$nextTick(() => {
+              let promises = []
+							this.loading = false;
+              this.$nextTick(() => {
+                let forData = arr.length ? arr : this.dialogTagList
+                this.dialogTagList = forData
+                forData.forEach(i => {
+                  if (i.value == 0) return
+                  promises.push(this.getAnalysisData(i.value))
+                })
+                Promise.all(promises).then(_ => {
+                  this.dataList.sort((a, b) => a.tIndex - b.tIndex)
+                  this.dataList.sort((a, b) => a.Type - b.Type)
+                  
+                  resolve()
+                })
+              })
+            })
+          })
+        }
       })
+
+      // return new Promise(resolve => {
+      //   Promise.all([this.getCurrencyAndBaseMessageData(), this.getScienceData(), this.getExtendData()]).then(_ => {
+      //     console.log('所有分析获取完成')
+      //     resolve()
+      //   })
+      // })
     },
     //删除分析
     delAnalysis(item) {
@@ -866,7 +808,7 @@ export default {
           this.saveData(this.bmData).then(_ => {
             console.log('转录问稿已保存')
             this.loading = false
-						resolve();
+            resolve()
           })
           // // TODO 不同板块用id做key
           this.actionTypesMap.jsonData['default'] = _actionTypes
@@ -902,6 +844,15 @@ export default {
         console.error(e)
         this.$toast(e)
       }
+    },
+    getDialogTagDataList() {
+      let params = {
+        uid: this.userinfo.userid
+      }
+
+      getSModelList(params).then(res => {
+        this.analysisList = res[0]
+      })
     }
   },
   mounted() {
@@ -911,6 +862,7 @@ export default {
       // }
       // this.getData()
     })
+    this.getDialogTagDataList()
     // console.log(getClassList)
   }
 }

+ 66 - 15
src/views/classObserve/outcome.vue

@@ -1,14 +1,37 @@
 <template>
   <div class="outcome" v-loading="saveLoading">
     <bar @cutPage="cutPage(1)" :tit="'分析结果'" :backPage="0"></bar>
-    <div class="sortList">
-      <div :class="[showIndex == 0 ? 'sortActive' : '']" @click.stop="changeShowIndex(0)">通用</div>
-      <div :class="[showIndex == 1 ? 'sortActive' : '']" @click.stop="changeShowIndex(1)">学科</div>
-      <div :class="[showIndex == 2 ? 'sortActive' : '']" @click.stop="changeShowIndex(2)">扩展</div>
+
+		<div class="o_content">
+			<van-tabs color="#409EFF" style="width:100%;height: 100%;display: flex;flex-direction: column;" v-model="showIndex" swipeable animated scrollspy @click="changeShowIndex" swipe-threshold="3">
+				<van-tab v-for="(item,index) in dialogTagList" :name="item.value" :title="item.name" :key="item.value">
+					<div class="o_c_item">
+						<analysisItem
+      			  ref="analysisItemRef"
+      			  v-for="(item, index) in dataList"
+      			  :key="item.id"
+      			  :data="item"
+      			  v-show="showIndex === item.Type"
+      			  v-if="!(item.Type == 0 && item.tIndex == 2)"
+      			  :analysisList="analysisList"
+      			  :bmData="bmData"
+      			  :fileId="fileId"
+							:dataList="dataList"
+      			/>
+					</div>
+				</van-tab>
+			</van-tabs>
+		</div>
+    <!-- <div class="sortList">
+      <div>
+				<div :class="[showIndex == 0 ? 'sortActive' : '']" @click.stop="changeShowIndex(0)">通用</div>
+      	<div :class="[showIndex == 1 ? 'sortActive' : '']" @click.stop="changeShowIndex(1)">学科</div>
+      	<div :class="[showIndex == 2 ? 'sortActive' : '']" @click.stop="changeShowIndex(2)">扩展</div>
+			</div>
       <span @click.stop="addAnalysis">+</span>
     </div>
 
-    <div class="stencilList" v-loading="loading[showIndex]">
+    <div class="stencilList">
       <analysisItem
         ref="analysisItemRef"
         v-for="(item, index) in dataList"
@@ -19,8 +42,9 @@
         :analysisList="analysisList"
         :bmData="bmData"
         :fileId="fileId"
+				:dataList="dataList"
       />
-    </div>
+    </div> -->
 
     <div class="botBtn">
       <div class="shareBtn" @click.stop="share()">
@@ -126,10 +150,10 @@ export default {
       type: Array,
       default: () => []
     },
-    loading: {
-      type: Array,
-      default: () => [true, true, true]
-    },
+		dialogTagList:{
+			type:Array,
+			default:()=>[]
+		},
     analysisList: {
       type: Array,
       default: () => []
@@ -162,6 +186,7 @@ export default {
         subject: '',
         pre: false
       },
+			menuList:[],
       subjectList: [
         { value: '1', label: '语文' },
         { value: '2', label: '数学' },
@@ -325,7 +350,7 @@ export default {
 						from:'hk',
 						to:'cn'
 				})
-        let assistant = this.analysisList.find(i => i.value == id)
+        let assistant = this.analysisList.find(i => i.id == id)
         let newIndexData = this.dataList
           .filter(i => i.Type == assistant.type)
           .sort((a, b) => new Date(a.createtime) - new Date(b.createtime))
@@ -335,8 +360,11 @@ export default {
           index: newIndex+index,
           userid: this.userId,
           json_data: JSON.stringify({
-            name: assistant.title,
-            result: '',
+            name: assistant.name,
+						anotherName:assistant.name,
+            result: assistant.detail,
+						mId: assistant.id,
+						echartsType: assistant.echartsType,
             fileList: [],
             dataFileList: [],
             content: ''
@@ -379,15 +407,17 @@ export default {
   justify-content: space-between;
   box-sizing: border-box;
 }
-.sortList {
+/*
+	.sortList {
   width: 100%;
+	max-width: calc(100% - 15px);
   display: flex;
   box-sizing: border-box;
   justify-content: space-between;
   margin-top: 55px;
   height: auto;
-  // padding: 15px;
   border-bottom: 0.5px rgba(231, 231, 231, 1) solid;
+	background-color: red;
   span {
     display: flex;
     justify-content: center;
@@ -439,6 +469,23 @@ export default {
     padding: 0 10px;
   }
 }
+*/
+.o_content{
+	width: 100%;
+	flex:1;
+	margin-top: 55px;
+	height: auto;
+	// background-color: red;
+	.o_c_item{
+		width: 100%;
+		height: calc(100vh - 164px);
+		flex: 1;
+		overflow: auto;
+		box-sizing: border-box;
+		padding: 10px;
+		// background:yellow;
+	}
+}
 .botBtn {
   background-color: #fff;
   width: 100%;
@@ -534,6 +581,10 @@ export default {
   z-index: 1999 !important;
 }
 
+/deep/.vant-tabs__content{
+		flex: 1;
+}
+
 /deep/.van-popup {
   z-index: 2000 !important;
 }

+ 10 - 4
src/views/classObserve/stencilled.vue

@@ -547,14 +547,17 @@ export default {
 		addAnalysisByList(data){
 			this.templateShow = true;
 			this.$refs.addTelRef.close();
-			let _list = this.analysisList.filter(i=>data.includes(i.value));
-			console.log(_list);
+			let _list = this.analysisList.filter(i=>data.includes(i.id));
+
 			_list.forEach(i=>{
 				this.analysisDetail.tips.push({
 					id: "",
 				jsonData: {
-					name: i.title,
-					result: i.brief,
+					name: i.name,
+					result: i.detail,
+					anotherName:i.name,
+					echartsType:i.echartsType,
+					mId:"",
 					fileList: [],
 					dataFileList: [],
 					wordNum: "",
@@ -572,6 +575,9 @@ export default {
 				isdel: 0,
 				})
 			})
+
+			console.log(_list);
+			
 			console.log(this.analysisDetail)
 			
 			console.log("上")

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