|
@@ -481,12 +481,7 @@
|
|
|
<div v-if="unitJson.length > 1" @click="deleteUnit(unitIndex)"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div style="
|
|
|
- margin: 50px 0px 10px;
|
|
|
- font-size: 1.5em;
|
|
|
- font-weight: 700;
|
|
|
- color: #0f7eff;
|
|
|
- ">
|
|
|
+ <div class="task_add_title">
|
|
|
添加任务
|
|
|
</div>
|
|
|
<div class="taskBorder" v-for="(itemTask, itemTaskIndex) in item.taskJson" :key="itemTaskIndex">
|
|
@@ -549,8 +544,8 @@
|
|
|
<el-select v-model="unitJson[unitIndex].chapterInfo[0].taskJson[
|
|
|
itemTaskIndex
|
|
|
].people" placeholder="请选择负责人" clearable filterable>
|
|
|
- <el-option v-for="item in ManAarray" :key="item.userid" :label="item.name"
|
|
|
- :value="item.userid">
|
|
|
+ <el-option v-for="item in ManAarray" :key="item.userid"
|
|
|
+ :label="item.name + (item.type == 1 ? '(老师)' : '(学生)')" :value="item.userid">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</div>
|
|
@@ -590,16 +585,17 @@
|
|
|
<div class="line"></div>
|
|
|
</div>
|
|
|
<div>
|
|
|
- <editor-bar style="width: 90% !important; margin: 0;height: 500px;" class="ed_s" placeholder="请输入任务描述" v-model="
|
|
|
- unitJson[unitIndex].chapterInfo[0].taskJson[
|
|
|
- itemTaskIndex
|
|
|
- ].taskDetail
|
|
|
- " @change="change"></editor-bar>
|
|
|
+ <editor-bar style="width: 90% !important; margin: 0;height: 500px;" class="ed_s"
|
|
|
+ placeholder="请输入任务描述" v-model="
|
|
|
+ unitJson[unitIndex].chapterInfo[0].taskJson[
|
|
|
+ itemTaskIndex
|
|
|
+ ].taskDetail
|
|
|
+ " @change="change"></editor-bar>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
- <div class="basic_box" v-if="false" style="
|
|
|
+ <div class="basic_box" style="
|
|
|
margin: 0;
|
|
|
min-height: 0;
|
|
|
width: 90% !important;
|
|
@@ -803,31 +799,42 @@
|
|
|
v-model="itemTool.toolDetail"></textarea>
|
|
|
</div>
|
|
|
<div style="margin-top:10px">
|
|
|
- <div class="tool">
|
|
|
- <div class="whiteBIcon" v-if="itemTool.tool == 1"
|
|
|
- @click="openToolFun(1, itemTaskIndex, toolIndex)">
|
|
|
+ <div class="tool" v-if="itemTool.tool == 1">
|
|
|
+ <div class="whiteBIcon" @click="openToolFun(1, itemTaskIndex, toolIndex)">
|
|
|
<img src="../../../assets/icon/secondToolList/whiteBoard.png" alt />
|
|
|
<div style="margin: 5px 0">电子白板</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="tool">
|
|
|
- <div class="whiteBIcon" v-if="itemTool.tool == 6"
|
|
|
- @click="openToolFun(6, itemTaskIndex, toolIndex)">
|
|
|
+ <div class="tool" v-if="itemTool.tool == 6">
|
|
|
+ <div class="whiteBIcon" @click="openToolFun(6, itemTaskIndex, toolIndex)">
|
|
|
<img src="../../../assets/icon/secondToolList/doc.png" alt />
|
|
|
<div style="margin: 5px 0">协同文档</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="tool">
|
|
|
- <div class="whiteBIcon" v-if="itemTool.tool == 3"
|
|
|
- @click="openToolFun(3, itemTaskIndex, toolIndex)">
|
|
|
+ <div class="tool" v-if="itemTool.tool == 3">
|
|
|
+ <div class="whiteBIcon" @click="openToolFun(3, itemTaskIndex, toolIndex)">
|
|
|
<img src="../../../assets/icon/secondToolList/mindMapping.png" alt />
|
|
|
<div style="margin: 5px 0">思维导图</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div v-if="itemTool.toolPhoto" style="margin-top:10px">
|
|
|
- <div class="toolimg">
|
|
|
- <img :src="itemTool.toolPhoto" alt="" @click="previewImg(itemTool.toolPhoto)">
|
|
|
+ <div v-if="itemTool.toolPhoto.length" style="margin-top:10px" class="toolimg_box">
|
|
|
+ <div class="toolimg" v-for="(photo, pIndex) in itemTool.toolPhoto" :key="pIndex">
|
|
|
+ <img :src="photo.content" alt="" @click="previewImg(photo.content)">
|
|
|
+ <img
|
|
|
+ class="deleteImg"
|
|
|
+ src="../../../assets/deleteworks.png"
|
|
|
+ v-if="
|
|
|
+ photo.userid == userid
|
|
|
+ "
|
|
|
+ @click.stop="deleteWorks(photo.id)"
|
|
|
+ alt
|
|
|
+ />
|
|
|
+ <div class="comment">
|
|
|
+ <div class="worksName">
|
|
|
+ <div>{{photo.username}}</div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -2270,9 +2277,9 @@ export default {
|
|
|
return;
|
|
|
} else {
|
|
|
this.addWork();
|
|
|
- if(this.type != 2){
|
|
|
+ if (this.type != 2) {
|
|
|
this.steps = 5
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.steps++;
|
|
|
}
|
|
|
}
|
|
@@ -2281,9 +2288,9 @@ export default {
|
|
|
this.$message.error("请将信息填写完整");
|
|
|
return;
|
|
|
} else {
|
|
|
- if(this.type != 2){
|
|
|
+ if (this.type != 2) {
|
|
|
this.steps = 5
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.steps++;
|
|
|
}
|
|
|
if (this.userid != this.courseUserid) {
|
|
@@ -2293,7 +2300,7 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- }else if (this.steps == 4) {
|
|
|
+ } else if (this.steps == 4) {
|
|
|
if (this.userid != this.courseUserid) {
|
|
|
this.updateWork2();
|
|
|
} else {
|
|
@@ -2335,9 +2342,9 @@ export default {
|
|
|
return;
|
|
|
} else {
|
|
|
this.addWork();
|
|
|
- if(this.type != 2){
|
|
|
+ if (this.type != 2) {
|
|
|
this.steps = 5
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.steps++;
|
|
|
}
|
|
|
}
|
|
@@ -2346,9 +2353,9 @@ export default {
|
|
|
this.$message.error("请将信息填写完整");
|
|
|
return;
|
|
|
} else {
|
|
|
- if(this.type != 2){
|
|
|
+ if (this.type != 2) {
|
|
|
this.steps = 5
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.steps++;
|
|
|
}
|
|
|
if (this.userid != this.courseUserid) {
|
|
@@ -2358,7 +2365,7 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- }else if (this.steps == 4) {
|
|
|
+ } else if (this.steps == 4) {
|
|
|
if (this.userid != this.courseUserid) {
|
|
|
this.updateWork2();
|
|
|
} else {
|
|
@@ -3384,9 +3391,9 @@ export default {
|
|
|
}
|
|
|
if (cPan == 2) {
|
|
|
if (this.steps != 3) {
|
|
|
- if(this.type == 2 && this.steps == 5){
|
|
|
+ if (this.type == 2 && this.steps == 5) {
|
|
|
this.steps == 3;
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
this.steps--;
|
|
|
}
|
|
|
}
|
|
@@ -4576,17 +4583,21 @@ export default {
|
|
|
var tool = task[j].toolArray
|
|
|
for (var z = 0; z < tool.length; z++) {
|
|
|
let _tool = tool[z]
|
|
|
- _tool.toolPhoto = ""
|
|
|
+ _tool.toolPhoto = []
|
|
|
+
|
|
|
for (var k = 0; k < works.length; k++) {
|
|
|
let _work = works[k]
|
|
|
if (_work.stage == i && _work.task == j && _work.tool == z && _work.atool == _tool.tool) {
|
|
|
- _tool.toolPhoto = _work.content;
|
|
|
- break;
|
|
|
+ _tool.toolPhoto.push(_work);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ if(this.timer){
|
|
|
+ clearTimeout(this.timer)
|
|
|
+ this.timer = null
|
|
|
+ }
|
|
|
this.timer = setTimeout(() => {
|
|
|
this.seleteCourseUpdate();
|
|
|
}, 1000);
|
|
@@ -4977,6 +4988,34 @@ export default {
|
|
|
this.addTools(49, this.taskCount, this.toolIndex);
|
|
|
}
|
|
|
},
|
|
|
+ deleteWorks(id) {
|
|
|
+ this.$confirm("确定删除此作业吗?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ let params = [
|
|
|
+ {
|
|
|
+ id: id,
|
|
|
+ },
|
|
|
+ ];
|
|
|
+ this.ajax
|
|
|
+ .post(this.$store.state.api + "deleteCourseWorkS", params)
|
|
|
+ .then((res) => {
|
|
|
+ this.$message({
|
|
|
+ message: "删除成功",
|
|
|
+ type: "success",
|
|
|
+ });
|
|
|
+ this.seleteCourseUpdate();
|
|
|
+ })
|
|
|
+ .catch((err) => {
|
|
|
+ this.$message.error("网络异常");
|
|
|
+ console.error(err);
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {});
|
|
|
+ },
|
|
|
},
|
|
|
beforeDestroy() {
|
|
|
clearTimeout(this.timer);
|
|
@@ -6520,6 +6559,22 @@ ol {
|
|
|
color: #dbdbdb;
|
|
|
}
|
|
|
|
|
|
+.task_add_title {
|
|
|
+ margin: 50px 0px 10px;
|
|
|
+ font-size: 1.5em;
|
|
|
+ font-weight: 700;
|
|
|
+ color: #0f7eff;
|
|
|
+}
|
|
|
+
|
|
|
+.task_add_title::after {
|
|
|
+ content: "提示:建议不要多账户同时编辑同一个任务";
|
|
|
+ font-size: 14px;
|
|
|
+ margin-left: 5px;
|
|
|
+ font-weight: 400;
|
|
|
+ color: #ff3a3a;
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
.funBlock {
|
|
|
display: flex;
|
|
|
padding: 15px 0;
|
|
@@ -7554,15 +7609,16 @@ ol {
|
|
|
|
|
|
.toolimg {
|
|
|
width: 200px;
|
|
|
- height: 105px;
|
|
|
- border-radius: 5px;
|
|
|
+ border-radius: 10px;
|
|
|
box-shadow: rgb(223 218 218) 0px 0px 6px 1px;
|
|
|
cursor: pointer;
|
|
|
+ overflow: hidden;
|
|
|
+ position: relative;
|
|
|
}
|
|
|
|
|
|
.toolimg>img {
|
|
|
- height: 100%;
|
|
|
- width: 100%;
|
|
|
+ width: 100%;
|
|
|
+ height: 105px;
|
|
|
object-fit: contain;
|
|
|
}
|
|
|
|
|
@@ -7585,7 +7641,55 @@ ol {
|
|
|
width: 17px;
|
|
|
}
|
|
|
|
|
|
-.ed_s >>> .text{
|
|
|
+.ed_s>>>.text {
|
|
|
height: calc(100% - 42px);
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
+.toolimg_box {
|
|
|
+ display: flex;
|
|
|
+ flex-wrap: wrap;
|
|
|
+}
|
|
|
+
|
|
|
+.toolimg {
|
|
|
+ margin-right: 20px;
|
|
|
+}
|
|
|
+
|
|
|
+.comment {
|
|
|
+ background: #f5f5f5;
|
|
|
+ /* border-radius: 0 0 15px 15px; */
|
|
|
+ display: flex;
|
|
|
+ flex-direction: row;
|
|
|
+ flex-wrap: nowrap;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: flex-end;
|
|
|
+ height: 35px;
|
|
|
+}
|
|
|
+
|
|
|
+.worksName {
|
|
|
+ display: flex;
|
|
|
+ width: 92%;
|
|
|
+ flex-direction: row;
|
|
|
+ flex-wrap: nowrap;
|
|
|
+ justify-content: space-between;
|
|
|
+ align-items: center;
|
|
|
+ margin: 0 10px;
|
|
|
+}
|
|
|
+
|
|
|
+.worksName>div:nth-child(1) {
|
|
|
+ width: 48px;
|
|
|
+ white-space: nowrap;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+}
|
|
|
+
|
|
|
+.deleteImg {
|
|
|
+ width: 25px !important;
|
|
|
+ height: 25px !important;
|
|
|
+ cursor: pointer;
|
|
|
+ position: absolute;
|
|
|
+ top: 10px;
|
|
|
+ right: 10px;
|
|
|
+}
|
|
|
+
|
|
|
</style>
|