|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div class="pb_content" style="background: #f0f2f5" v-loading="loading">
|
|
|
+ <div class="pb_content" style="background: #f0f2f5" v-loading="loading" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<div class="pb_content_body" style="position: relative; margin: 0">
|
|
|
<div class="right" :style="{width:istemplate == 1 ? 'calc(100% - 300px)' : '100%'}">
|
|
|
<div class="courseTop">
|
|
@@ -358,7 +358,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="whiteBg" style="background: #fff; margin: 0 0 10px;padding: 0 0 15px;" v-loading="textLoading">
|
|
|
+ <div class="whiteBg" style="background: #fff; margin: 0 0 10px;padding: 0 0 15px;" v-loading="textLoading" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<div class="whiteBg" style="border-radius: 0; margin-top: 15px">
|
|
|
<div class="c_info_title">
|
|
|
课程简要描述
|
|
@@ -407,7 +407,7 @@
|
|
|
<div class="add_info_box" style="margin: 0 0 0 auto">
|
|
|
<button class="c_pub_button_add pub_btn_add_img" @click="addImg($event)">
|
|
|
上传补充资料
|
|
|
- <input type="file" accept=".docx,.doc,.ppt,.pptx,.md,.txt" style="display: none" v-if="inputShow" @change="
|
|
|
+ <input type="file" accept=".docx,.doc,.ppt,.pptx,.md,.txt,.pdf" style="display: none" v-if="inputShow" @change="
|
|
|
beforeUploadInfo2(
|
|
|
$event,
|
|
|
13
|
|
@@ -667,7 +667,7 @@
|
|
|
<input type="text" placeholder="输入任务名称" class="binfo_input" style="border-radius: 4px"
|
|
|
v-model="item.task" />
|
|
|
</div>
|
|
|
- <div class="outline_detail" v-loading="taskDetailLoading.indexOf('task-' + index) !== -1">
|
|
|
+ <div class="outline_detail" v-loading="taskDetailLoading.indexOf('task-' + index) !== -1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols
|
|
|
placeholder="请输入任务描述" v-model="item.taskDetail2"></textarea>
|
|
|
<div class="op_box">
|
|
@@ -689,7 +689,7 @@
|
|
|
概念群
|
|
|
</div>
|
|
|
<div class="task_outline">
|
|
|
- <div class="outline_detail" v-loading="cpoteLoading.cpote1">
|
|
|
+ <div class="outline_detail" v-loading="cpoteLoading.cpote1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols placeholder="请输入概念群"
|
|
|
v-model="cpote.cpote1" v-if="cpote.cpote1s"></textarea>
|
|
|
<div class="markBox vditor-reset" v-html="MarkdownT(cpote.cpote1)" v-else></div>
|
|
@@ -714,7 +714,7 @@
|
|
|
问题链
|
|
|
</div>
|
|
|
<div class="task_outline">
|
|
|
- <div class="outline_detail" v-loading="cpoteLoading.cpote2">
|
|
|
+ <div class="outline_detail" v-loading="cpoteLoading.cpote2" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols placeholder="请输入问题链"
|
|
|
v-model="cpote.cpote2" v-if="cpote.cpote2s"></textarea>
|
|
|
<div class="markBox vditor-reset" v-html="MarkdownT(cpote.cpote2)" v-else></div>
|
|
@@ -739,7 +739,7 @@
|
|
|
目标层
|
|
|
</div>
|
|
|
<div class="task_outline">
|
|
|
- <div class="outline_detail" v-loading="cpoteLoading.cpote3">
|
|
|
+ <div class="outline_detail" v-loading="cpoteLoading.cpote3" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols placeholder="请输入目标层"
|
|
|
v-model="cpote.cpote3" v-if="cpote.cpote3s"></textarea>
|
|
|
<div class="markBox vditor-reset" v-html="MarkdownT(cpote.cpote3)" v-else></div>
|
|
@@ -764,7 +764,7 @@
|
|
|
任务簇
|
|
|
</div>
|
|
|
<div class="task_outline">
|
|
|
- <div class="outline_detail" v-loading="cpoteLoading.cpote4">
|
|
|
+ <div class="outline_detail" v-loading="cpoteLoading.cpote4" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols placeholder="请输入任务簇"
|
|
|
v-model="cpote.cpote4" v-if="cpote.cpote4s"></textarea>
|
|
|
<div class="markBox vditor-reset" v-html="MarkdownT(cpote.cpote4)" v-else></div>
|
|
@@ -801,7 +801,7 @@
|
|
|
<input type="text" placeholder="输入任务名称" class="binfo_input" style="border-radius: 4px"
|
|
|
v-model="item.task" />
|
|
|
</div>
|
|
|
- <div class="outline_detail" v-loading="taskDetailLoading5.indexOf('task-' + index) !== -1">
|
|
|
+ <div class="outline_detail" v-loading="taskDetailLoading5.indexOf('task-' + index) !== -1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea v-autoHeight="100" rows="4" class="binfo_input binfo_textarea" cols placeholder="请输入教案"
|
|
|
v-model="item.taskDetail3" v-if="item.isTask3"></textarea>
|
|
|
<div class="markBox vditor-reset" v-html="MarkdownT(item.taskDetail3)" v-else></div>
|
|
@@ -1659,7 +1659,7 @@
|
|
|
easyArray.indexOf(unitJson[unitIndex].easy) ==
|
|
|
-1
|
|
|
" style="margin-top: 20px" class="op_task_box"
|
|
|
- v-loading="taskDetailLoading2.indexOf('task-' + itemTaskIndex) !== -1">
|
|
|
+ v-loading="taskDetailLoading2.indexOf('task-' + itemTaskIndex) !== -1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<!-- <editor-bar class="addEditor" style="margin: 0" placeholder="请输入任务描述" v-model="unitJson[unitIndex].chapterInfo[0].taskJson[
|
|
|
itemTaskIndex
|
|
|
].taskDetail
|
|
@@ -3332,7 +3332,7 @@
|
|
|
</div>
|
|
|
<!-- v-show="!itemTool.isFold3" -->
|
|
|
<div class="op_tool_box"
|
|
|
- v-loading="taskDetailLoading3.indexOf('task-' + itemTaskIndex + toolIndex) !== -1">
|
|
|
+ v-loading="taskDetailLoading3.indexOf('task-' + itemTaskIndex + toolIndex) !== -1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<textarea rows="2" v-autoHeight="70" type="text" placeholder="添加工具描述"
|
|
|
class="binfo_input" style="
|
|
|
margin: 0 0 20px 0;
|
|
@@ -3632,7 +3632,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="elist_css" v-if="!(unitJson[unitJson.length - 1].easy == 4)"
|
|
|
- v-loading="taskDetailLoading4.indexOf('task-' + itemTaskIndex) !== -1">
|
|
|
+ v-loading="taskDetailLoading4.indexOf('task-' + itemTaskIndex) !== -1" element-loading-text="小可正在努力生成中,请稍等...">
|
|
|
<div class="elist_title">
|
|
|
<div style="
|
|
|
display: flex;
|
|
@@ -5282,6 +5282,12 @@ import { v4 as uuidv4 } from "uuid";
|
|
|
import MarkdownIt from "markdown-it";
|
|
|
import aiCreateDialog from './aiCreateDialog.vue'
|
|
|
import aiCreateVideoDialog from './aiCreateVideoDialog.vue'
|
|
|
+var OpenCC = require("opencc-js");
|
|
|
+let converter = OpenCC.Converter({
|
|
|
+ from:'hk',
|
|
|
+ to:'cn'
|
|
|
+})
|
|
|
+
|
|
|
|
|
|
export default {
|
|
|
components: {
|
|
@@ -5543,7 +5549,7 @@ export default {
|
|
|
imageloading2: false,
|
|
|
searchImageValue: "",
|
|
|
ppage: 1,
|
|
|
- toolsData: toolsData,
|
|
|
+ toolsData: JSON.parse(converter(JSON.stringify(toolsData))),
|
|
|
oldIndex: 0,
|
|
|
dragType: "",
|
|
|
oldUnitIndex: 0,
|
|
@@ -7610,7 +7616,7 @@ export default {
|
|
|
|
|
|
var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
|
|
|
var _this = this;
|
|
|
- var xianObj = ['DOCX','DOC','PPT','PPTX','MD','TXT']
|
|
|
+ var xianObj = ['DOCX','DOC','PPT','PPTX','MD','TXT','PDF']
|
|
|
if (
|
|
|
xianObj.indexOf(
|
|
|
file.name
|
|
@@ -7618,7 +7624,7 @@ export default {
|
|
|
[file.name.split(".").length - 1].toLocaleUpperCase()
|
|
|
) == -1
|
|
|
) {
|
|
|
- this.$message.error("请上传.doc,.docx,.ppt,.pptx,.md,.txt文件!");
|
|
|
+ this.$message.error("请上传.doc,.docx,.ppt,.pptx,.md,.txt,.pdf文件!");
|
|
|
this.inputShow = true;
|
|
|
// var a = _this.$refs.upload1.uploadFiles;
|
|
|
// a.splice(a.length - 1, a.length);
|
|
@@ -11038,7 +11044,7 @@ export default {
|
|
|
.then((res) => {
|
|
|
let _unitJson = JSON.parse(res.data[0][0].chapters);
|
|
|
let fileInfo = []
|
|
|
- var xianObj = ['DOCX','DOC','PPT','PPTX','MD','TXT']
|
|
|
+ var xianObj = ['DOCX','DOC','PPT','PPTX','MD','TXT','PDF']
|
|
|
|
|
|
for(var i = 0; i < _unitJson.length; i++){
|
|
|
let tasks = _unitJson[i].chapterInfo[0].taskJson
|
|
@@ -13205,8 +13211,7 @@ Instruction: Based on the context, follow "Format example", write content.
|
|
|
|
|
|
# Context
|
|
|
## 要求
|
|
|
-${msg} 以及##参考资料,
|
|
|
-然后根据Format example的要求返回要以数组的格式
|
|
|
+${msg} 以及##参考资料
|
|
|
|
|
|
## 参考资料
|
|
|
课程名字:${this.courseName}
|
|
@@ -13245,7 +13250,7 @@ Instruction: Based on the context, follow "Format example", write content.
|
|
|
|
|
|
# Context
|
|
|
## 要求
|
|
|
-${msg} 以及#教学任务教案 内容要求参考#格式要求, 然后根据Format example的要求返回要以数组的格式
|
|
|
+${msg} 以及#教学任务教案 内容要求参考#格式要求
|
|
|
|
|
|
## 教学任务教案
|
|
|
${_text}
|
|
@@ -13253,15 +13258,14 @@ ${_text}
|
|
|
${this.templateid == "4480d65a-1e48-11ef-bee5-005056b86db5" ? '#目标层\n'+this.cpote.cpote3.replaceAll('#','').replaceAll('*','').replaceAll('-','').replaceAll('\n','')+'\n\n#任务簇\n'+this.cpote.cpote4.replaceAll('#','').replaceAll('*','').replaceAll('-','').replaceAll('\n','') : ''}
|
|
|
|
|
|
## 格式要求
|
|
|
-任务名:
|
|
|
-任务描述:该描述是教师给与学生的指示(用于指导学生如何进行每个教学活动),对应到学生活动,你应该用友好,但是又清晰明确的口吻来撰写。
|
|
|
+任务数量:${this.teacherText.length}个
|
|
|
+任务描述:用老师的身份以友好,但是又清晰明确的口吻来撰写该描述,该描述教师给与学生的指示(用于指导学生如何进行每个教学活动),对应到学生活动
|
|
|
评价标准:至少3条评价标准,这个评价是教师用来评价学生表现的,需要包含评价维度,以及该维度中教师期待学生的表现,句式为学生应该能....
|
|
|
-平台工具:
|
|
|
-工具名:从工具列表中选择0~2个工具用于学生阶段性成果提交,工具列表:[电子白板,文档,思维导图,表格,作业提交,问答,选择题],仅在这几个工具里选择
|
|
|
-工具指引:以友好,明确的口吻告诉学生该如何使用该工具
|
|
|
+工具名:从工具列表中选择0~2个工具用于学生阶段性成果提交:工具列表:电子白板,文档,思维导图,表格,作业提交,问答,选择题,只在这几个工具里选
|
|
|
+工具描述:用同学的方式以友好亲切,明确的口吻告诉学生该如何使用该工具
|
|
|
|
|
|
# Format example
|
|
|
-[{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[{"tool":"电子白板","detail":"工具描述"},{"tool":"思维大图","detail":"工具描述"}]},{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[]},{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[{"tool":"文档","detail":"工具描述"}]}]`
|
|
|
+[{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[{"tool":"工具名","detail":"工具描述"},{"tool":"工具名","detail":"工具描述"}]},{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[]},{"detail":"面向学生的任务描述","elist":[{"value":"评价名字1","detail":"评价维度1","score":5},{"value":"评价名字2","detail":"评价维度2","score":5},{"value":"评价名字3","detail":"评价维度3","score":5}],"toolChoose":[{"tool":"工具名","detail":"工具描述"}]}]`
|
|
|
this.loading = true
|
|
|
this.aiGet3(message, this.aiCallBack)
|
|
|
} else if (this.aitype == "aiDetail1") {
|
|
@@ -13297,7 +13301,7 @@ Instruction: Based on the context, follow "Format example", write content.
|
|
|
|
|
|
# Context
|
|
|
## 要求
|
|
|
-${msg} 以及${this.templateid != "4480d65a-1e48-11ef-bee5-005056b86db5" ? '##任务大纲' : '##目标层,##任务簇'}, 然后根据Format example的要求返回要以数组的格式
|
|
|
+${msg} 以及${this.templateid != "4480d65a-1e48-11ef-bee5-005056b86db5" ? '##任务大纲' : '##目标层,##任务簇'}
|
|
|
|
|
|
${this.templateid != "4480d65a-1e48-11ef-bee5-005056b86db5" ? '## 任务大纲\n'+_text : ''}
|
|
|
|
|
@@ -13451,7 +13455,7 @@ ${message} 以及##参考资料 以文本格式输出项目概况,驱动性问
|
|
|
// if (data.choices && data.choices.length && data.choices[0].message) {
|
|
|
// _this.courseText = data.choices[0].message.content
|
|
|
// }
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|
|
@@ -13880,18 +13884,18 @@ ${message} 以及##参考资料 以文本格式输出项目概况,驱动性问
|
|
|
if (_task.toolChoose.length) {
|
|
|
for (var j = 0; j < _task.toolChoose.length; j++) {
|
|
|
let _json = {
|
|
|
- tool: toolsJson[_task.toolChoose[j].tool] ? [toolsJson[_task.toolChoose[j].tool].tool] : [],
|
|
|
+ tool: toolsJson[_task.toolChoose[j].tool] ? [toolsJson[_task.toolChoose[j].tool].tool] : [16],
|
|
|
toolDetail: _task.toolChoose[j].detail,
|
|
|
- toolType: toolsJson[_task.toolChoose[j].tool] ? toolsJson[_task.toolChoose[j].tool].type : 0,
|
|
|
+ toolType: toolsJson[_task.toolChoose[j].tool] ? toolsJson[_task.toolChoose[j].tool].type : 2,
|
|
|
askCount: 1,
|
|
|
askTitle: "",
|
|
|
askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
|
|
|
}
|
|
|
|
|
|
- if(_task.toolChoose[j].tool == '问答'){
|
|
|
+ if(converter(_task.toolChoose[j].tool) == converter('问答')){
|
|
|
let answerQ = await _this.aiCreateQuestion(15, i)
|
|
|
_json.answerQ = answerQ.answerQ
|
|
|
- }else if(_task.toolChoose[j].tool == '选择题'){
|
|
|
+ }else if(converter(_task.toolChoose[j].tool) == converter('选择题')){
|
|
|
let testJson = await _this.aiCreateQuestion(45, i)
|
|
|
_json.testJson = {"testCount":testJson.length,"testTitle":"","testJson":testJson}
|
|
|
}
|
|
@@ -13975,7 +13979,7 @@ ${mclass.length ? '面向年级:' + mclass.join(",") : ''}
|
|
|
## 教案
|
|
|
${this.teacherText[task].detail.replaceAll('#','').replaceAll('*','').replaceAll('-','').replaceAll('\n','')}
|
|
|
|
|
|
-# formate example
|
|
|
+# Format example
|
|
|
{answerQ:"问题"}
|
|
|
`
|
|
|
}else if(type == 45){
|
|
@@ -13987,7 +13991,7 @@ Instruction: Based on the context, follow "Format example", write content.
|
|
|
|
|
|
# Context
|
|
|
## 任务
|
|
|
-根据本任务的#教案,在考虑到面向学生年级(<面向年级>)以及相对应的学科(<课程学科>)的基础上生成5道单选题。题目的意义是测试学生对本教学任务知识点的掌握情况,你的题目应当是有意义的。然后根据Format example的要求返回要以数组的格式
|
|
|
+根据本任务的#教案,在考虑到面向学生年级(<面向年级>)以及相对应的学科(<课程学科>)的基础上生成5道单选题。题目的意义是测试学生对本教学任务知识点的掌握情况,你的题目应当是有意义的。
|
|
|
|
|
|
## 限制
|
|
|
- 生成题目禁止重复。
|
|
@@ -14004,7 +14008,7 @@ ${mclass.length ? '面向年级:' + mclass.join(",") : ''}
|
|
|
## 教案
|
|
|
${this.teacherText[task].detail.replaceAll('#','').replaceAll('*','').replaceAll('-','').replaceAll('\n','')}
|
|
|
|
|
|
-# formate example
|
|
|
+# Format example
|
|
|
[{"teststitle":"题目内容","testItem":4,"checkList":["选项1","选项2","选项3","选项4"],"timuList":[],"answer":0,"type":"1"},{"teststitle":"题目内容","testItem":"选项数量(数字)","checkList":["选项1","选项2","选项3","选项4"],"timuList":[],"answer":"答案(数字)","type":"1"}]
|
|
|
`
|
|
|
}
|
|
@@ -14389,7 +14393,7 @@ ${msg} 及#教学任务描述 以文本格式输出任务设计和评价标准
|
|
|
// _this.$forceUpdate()
|
|
|
// }
|
|
|
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|
|
@@ -14527,7 +14531,7 @@ ${msg}
|
|
|
// _this.$forceUpdate()
|
|
|
// }
|
|
|
// _this.taskDetailLoading2.splice(_this.taskDetailLoading.indexOf(_tindex), 1)
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|
|
@@ -14665,7 +14669,7 @@ ${msg} 输出格式和内容要求参考#格式与要求
|
|
|
// _this.$forceUpdate()
|
|
|
// }
|
|
|
// _this.taskDetailLoading3.splice(_this.taskDetailLoading3.indexOf(_tindex), 1)
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|
|
@@ -14949,7 +14953,7 @@ ${_text2}`
|
|
|
// _this.$forceUpdate()
|
|
|
// }
|
|
|
// _this.taskDetailLoading2.splice(_this.taskDetailLoading.indexOf(_tindex), 1)
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|
|
@@ -15109,7 +15113,7 @@ ${this.aitype == 'aiCpote4' ? '## 目标层\n'+this.cpote['cpote3'] : ''}`
|
|
|
// _this.$forceUpdate()
|
|
|
// }
|
|
|
// _this.taskDetailLoading2.splice(_this.taskDetailLoading.indexOf(_tindex), 1)
|
|
|
- if (response.data.FunctionResponse.result == "发送成功") {
|
|
|
+ if (converter(response.data.FunctionResponse.result) == converter("发送成功")) {
|
|
|
} else {
|
|
|
this.$message.warning(response.data.FunctionResponse.result);
|
|
|
}
|