|
@@ -99,7 +99,8 @@
|
|
|
box-shadow: 0px 9px 0 0 #f2f2f2;
|
|
|
" :class="{ navLeftCss: !mlDialog }">
|
|
|
<div class="courseIndex">
|
|
|
- <div v-show="chapInfoList[courseType].chapterInfo[0].taskJson[taskCount].task">{{chapInfoList[courseType].chapterInfo[0].taskJson[taskCount].task}}</div>
|
|
|
+ <div v-show="chapInfoList[courseType].chapterInfo[0].taskJson[taskCount].task">
|
|
|
+ {{ chapInfoList[courseType].chapterInfo[0].taskJson[taskCount].task }}</div>
|
|
|
<!-- <el-tooltip effect="light" :content="chapInfoList[courseType].dyName" placement="top">
|
|
|
<div>{{ chapInfoList[courseType].dyName }}</div>
|
|
|
</el-tooltip> -->
|
|
@@ -834,7 +835,8 @@
|
|
|
<div class="bzBox">
|
|
|
<div></div>
|
|
|
<div>步骤{{ toolIndex + 1 }}</div>
|
|
|
- <div style="margin: 0 72px 0 auto;" v-if="courseDetail.userid == userid"><el-button type="primary" size="mini" @click="updateToolDetail">{{!isUpdateToolDetail ? '编辑' : '确认修改'}}</el-button>
|
|
|
+ <div style="margin: 0 72px 0 auto;" v-if="courseDetail.userid == userid"><el-button type="primary"
|
|
|
+ size="mini" @click="updateToolDetail">{{ !isUpdateToolDetail ? '编辑' : '确认修改' }}</el-button>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -1065,9 +1067,11 @@
|
|
|
</div>
|
|
|
<div class="tooldetail">
|
|
|
<!-- <div class="toolTitle">工具描述</div> -->
|
|
|
- <div style="height:100%" v-html="contentConvent(tool.toolDetail ? tool.toolDetail : '暂无描述')" v-if="!isUpdateToolDetail" @click="updateToolDetail"></div>
|
|
|
+ <div style="height:100%" v-html="contentConvent(tool.toolDetail ? tool.toolDetail : '暂无描述')"
|
|
|
+ v-if="!isUpdateToolDetail" @click="updateToolDetail"></div>
|
|
|
<div v-else>
|
|
|
- <el-input type="textarea" :rows="3" resize="none" v-model="updateToolDetailInner" placeholder="请输入任务描述"></el-input>
|
|
|
+ <el-input type="textarea" :rows="3" resize="none" v-model="updateToolDetailInner"
|
|
|
+ placeholder="请输入任务描述"></el-input>
|
|
|
</div>
|
|
|
</div>
|
|
|
<el-button type="primary" v-if="tool.tool[0] == 32" style="
|
|
@@ -1076,12 +1080,12 @@
|
|
|
transform: translateY(-130%);
|
|
|
" @click="addImg($event)">上传作业<input type="file" accept="*"
|
|
|
style="display: none" @change="beforeUpload1($event, 7, toolIndex)" /></el-button>
|
|
|
- <el-button type="primary" v-if="tool.tool[0] == 57" style="
|
|
|
+ <!-- <el-button type="primary" v-if="tool.tool[0] == 57" style="
|
|
|
position: absolute;
|
|
|
right: 30px;
|
|
|
transform: translateY(-130%);
|
|
|
" @click="addImg($event)">上传作业<input type="file" accept="*"
|
|
|
- style="display: none" @change="beforeUpload1($event, 8, toolIndex)" /></el-button>
|
|
|
+ style="display: none" @change="beforeUpload1($event, 8, toolIndex)" /></el-button> -->
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -1340,7 +1344,9 @@
|
|
|
" v-for="(w, wIndex) in worksTeacher[toolIndex]"
|
|
|
:key="wIndex" :class="w.type == 1 ? 'isTypeOne' : ''">
|
|
|
<div class="workImg">
|
|
|
- <img :src="word2" @click="downloadFile(w.works)" alt />
|
|
|
+ <img :src="word2" @click="downloadFile(w.works)" v-if="w.type == 12" alt />
|
|
|
+ <img :src="word2" @click="openCocoPi(57, toolIndex, w.userid, w.sName)" v-else-if="w.type == 15"
|
|
|
+ alt />
|
|
|
<div class="answerScore" v-if="w.score" @click.stop="openScore(w)" :class="{
|
|
|
rightW:
|
|
|
w.userid == userid ||
|
|
@@ -2587,7 +2593,9 @@
|
|
|
: worksStudent2[toolIndex].slice(0, 6)" :key="wIndex"
|
|
|
:class="w.type == 1 ? 'isTypeOne' : ''">
|
|
|
<div class="workImg">
|
|
|
- <img :src="word2" @click="downloadFile(w.works)" alt />
|
|
|
+ <img :src="word2" @click="downloadFile(w.works)" v-if="w.type == 12" alt />
|
|
|
+ <img :src="word2" @click="openCocoPi(57, toolIndex, w.userid, w.sName)" v-else-if="w.type == 15"
|
|
|
+ alt />
|
|
|
<div class="answerScore" v-if="w.score" @click.stop="openScore(w)" :class="{
|
|
|
rightW:
|
|
|
w.userid == userid ||
|
|
@@ -4331,6 +4339,11 @@
|
|
|
<img src="../../assets/icon/codeFile.png" />
|
|
|
<div>点击下载文件</div>
|
|
|
</div>
|
|
|
+ <div class="worksAnswer codeFileBox" v-if="commentDetail.works && commentDetail.type == 15"
|
|
|
+ @click="openCocoPi(15, commentIndexJson.toolIndex, commentDetail.userid, commentDetail.sName)">
|
|
|
+ <img src="../../assets/icon/codeFile.png" />
|
|
|
+ <div>点击打开CocoPi</div>
|
|
|
+ </div>
|
|
|
<div class="worksAnswer" v-if="commentDetail.works && commentDetail.type == 13">
|
|
|
<div v-html="JSON.parse(commentDetail.works).text"></div>
|
|
|
</div>
|
|
@@ -4707,6 +4720,11 @@
|
|
|
<img src="../../assets/icon/codeFile.png" />
|
|
|
<div>点击下载文件</div>
|
|
|
</div>
|
|
|
+ <div class="worksAnswer codeFileBox" v-if="commentDetail.works && commentDetail.type == 15"
|
|
|
+ @click="openCocoPi(15, commentIndexJson.toolIndex, commentDetail.userid, commentDetail.sName)">
|
|
|
+ <img src="../../assets/icon/codeFile.png" />
|
|
|
+ <div>点击打开CocoPi</div>
|
|
|
+ </div>
|
|
|
<div class="worksAnswer" v-if="commentDetail.works && commentDetail.type == 13">
|
|
|
<div v-html="JSON.parse(commentDetail.works).text"></div>
|
|
|
</div>
|
|
@@ -5851,8 +5869,8 @@ export default {
|
|
|
toolType: 0,
|
|
|
checktoolArray: [],
|
|
|
vChapterData: [],
|
|
|
- isUpdateToolDetail:false,
|
|
|
- updateToolDetailInner:''
|
|
|
+ isUpdateToolDetail: false,
|
|
|
+ updateToolDetailInner: ''
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
@@ -6405,7 +6423,7 @@ export default {
|
|
|
},
|
|
|
addCourseWorksTeacher(i) {
|
|
|
var typesql;
|
|
|
- if (this.sTool == 32 || this.sTool == 57) {
|
|
|
+ if (this.sTool == 32) {
|
|
|
this.addCourseWorksGongTeacher(this.toolindex, this.studyJuri[0].cover[0].url, this.sTool);
|
|
|
return;
|
|
|
}
|
|
@@ -7646,8 +7664,8 @@ export default {
|
|
|
}
|
|
|
this.worksStudent[i].push(_works);
|
|
|
this.isWorksS[i].push({ uid: b[j].userid, sName: b[j].name });
|
|
|
- } else if (a[i].tool[0] == 57 && b[j].atool == 57) {
|
|
|
- let _works = {
|
|
|
+ } else if (a[i].tool[0] == 57 && b[j].atool == 57 && b[j].type == 12) {
|
|
|
+ _worksStudent[i].push({
|
|
|
userid: b[j].userid,
|
|
|
ateacher: b[j].ateacher,
|
|
|
wid: b[j].id,
|
|
@@ -7661,13 +7679,24 @@ export default {
|
|
|
commentCount: commentCount,
|
|
|
isLikes: isLikes,
|
|
|
commentJson: commentJson,
|
|
|
- }
|
|
|
- if (b[j].ttype == 1) {
|
|
|
- this.worksTeacher[i].push(_works);
|
|
|
- } else {
|
|
|
- this.worksStudent2[i].push(_works);
|
|
|
- }
|
|
|
- this.worksStudent[i].push(_works);
|
|
|
+ });
|
|
|
+ this.isWorksS[i].push({ uid: b[j].userid, sName: b[j].name });
|
|
|
+ } else if (a[i].tool[0] == 57 && b[j].atool == 57 && b[j].type == 15) {
|
|
|
+ _worksStudent[i].push({
|
|
|
+ userid: b[j].userid,
|
|
|
+ ateacher: b[j].ateacher,
|
|
|
+ wid: b[j].id,
|
|
|
+ works: b[j].content,
|
|
|
+ sName: b[j].name ? b[j].name : b[j].userid,
|
|
|
+ type: 15,
|
|
|
+ time: b[j].time,
|
|
|
+ score: b[j].score,
|
|
|
+ img: b[j].img,
|
|
|
+ likesCount: likesCount,
|
|
|
+ commentCount: commentCount,
|
|
|
+ isLikes: isLikes,
|
|
|
+ commentJson: commentJson,
|
|
|
+ });
|
|
|
this.isWorksS[i].push({ uid: b[j].userid, sName: b[j].name });
|
|
|
}
|
|
|
}
|
|
@@ -10264,7 +10293,7 @@ export default {
|
|
|
if (this.tType !== "1" && this.tType !== "4") {
|
|
|
return;
|
|
|
}
|
|
|
- if (t == 16 || t == 32 || t == 57 || t == 50) {
|
|
|
+ if (t == 16 || t == 32 || t == 50) {
|
|
|
this.dialogVisibleWorks = true; //作业提交
|
|
|
} else if (t == 15) {
|
|
|
this.answerQ = this.chapInfoList[this.courseType].chapterInfo[0]
|
|
@@ -10447,7 +10476,7 @@ export default {
|
|
|
|
|
|
this.isStar = false;
|
|
|
this.studentEvalDialogVisibleTeacher = true;
|
|
|
- } else if (t == 3 || t == 1 || t == 7) {
|
|
|
+ } else if (t == 3 || t == 1 || t == 7 || t == 57) {
|
|
|
window.parent.postMessage(
|
|
|
{
|
|
|
tools: t + 'teacher',
|
|
@@ -10461,6 +10490,25 @@ export default {
|
|
|
);
|
|
|
}
|
|
|
},
|
|
|
+ openCocoPi(tool, i, uid, uname) {
|
|
|
+ let student = {
|
|
|
+ userid: uid,
|
|
|
+ student: uname,
|
|
|
+ }
|
|
|
+ if (tool == 57) {
|
|
|
+ window.parent.postMessage(
|
|
|
+ {
|
|
|
+ tools: tool + "teacher",
|
|
|
+ cid: this.id,
|
|
|
+ stage: this.courseType,
|
|
|
+ task: this.taskCount,
|
|
|
+ tool: i,
|
|
|
+ student: student,
|
|
|
+ },
|
|
|
+ "*"
|
|
|
+ );
|
|
|
+ }
|
|
|
+ },
|
|
|
setRightAnswer(s, i, j) {
|
|
|
for (var q = 0; q < this.sentenceList[i].chooseSenList.length; q++) {
|
|
|
if (
|
|
@@ -11294,18 +11342,18 @@ export default {
|
|
|
});
|
|
|
this.checktoolArray = []
|
|
|
this.getCourseDetail(2)
|
|
|
- this.checkBz(this.chapInfoList[this.courseType].chapterInfo[0].taskJson[this.taskCount].toolChoose.length-1)
|
|
|
+ this.checkBz(this.chapInfoList[this.courseType].chapterInfo[0].taskJson[this.taskCount].toolChoose.length - 1)
|
|
|
this.$forceUpdate()
|
|
|
})
|
|
|
.catch((err) => {
|
|
|
console.error(err);
|
|
|
});
|
|
|
},
|
|
|
- updateToolDetail(){
|
|
|
- if(!this.isUpdateToolDetail){
|
|
|
+ updateToolDetail() {
|
|
|
+ if (!this.isUpdateToolDetail) {
|
|
|
this.isUpdateToolDetail = true
|
|
|
this.updateToolDetailInner = JSON.parse(JSON.stringify(this.tool.toolDetail))
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.chapInfoList[this.courseType].chapterInfo[0].taskJson[this.taskCount].toolChoose[this.toolIndex].toolDetail = JSON.parse(JSON.stringify(this.updateToolDetailInner))
|
|
|
let params = [
|
|
|
{
|
|
@@ -11331,7 +11379,7 @@ export default {
|
|
|
console.error(err);
|
|
|
});
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
},
|
|
|
directives: {
|
|
@@ -14913,6 +14961,7 @@ export default {
|
|
|
width: 20px;
|
|
|
height: 20px;
|
|
|
}
|
|
|
+
|
|
|
/* code 样式 */
|
|
|
.cont {
|
|
|
/* -webkit-user-modify: read-write; */
|
|
@@ -14973,5 +15022,4 @@ export default {
|
|
|
.cont>>>ul,
|
|
|
ol {
|
|
|
margin: 10px 0 10px 20px;
|
|
|
-}
|
|
|
-</style>
|
|
|
+}</style>
|