This commit is contained in:
zhaofang
2022-09-27 20:41:03 +08:00
parent 88c2061094
commit 0ce81064e8

View File

@@ -232,6 +232,7 @@ export default {
return;
}
this.mynoteData.courseId = this.courseId;
this.mynoteData.courseName = this.data.name;
if(this.isEdit) {
apiNote.update(this.mynoteData).then(res=>{
if(res.status == 200) {
@@ -244,9 +245,9 @@ export default {
type: 1, //我发布的是1 我导入的是2
content: '',
playTime: '',
courseId: '',// 课程id
contentId: '',//课程内容id
courseName: '',// 课程名称
// courseId: '',// 课程id
// contentId: '',//课程内容id
// courseName: '',// 课程名称
openType: 1,// 1表不公开 9表完全公开
};
}, 2000)
@@ -261,6 +262,22 @@ export default {
if(this.mynoteData.openType != 9){
return
}
setTimeout(() => {
localStorage.setItem("NOTE_TEXT", '');
// clearInterval(this.autoSave);
this.getMyNote();
this.notetabType(2);
this.mynoteData = {
type: 1, //我发布的是1 我导入的是2
content: '',
playTime: '',
// courseId: '',// 课程id
// contentId: '',//课程内容id
// courseName: '',// 课程名称
openType: 1,// 1表不公开 9表完全公开
};
}, 2000)
// 是编辑新增
let event = {
key: "PublishNote",//后台的事件key
@@ -276,26 +293,10 @@ export default {
}
this.$store.dispatch("userTrigger", event);
}
setTimeout(() => {
localStorage.setItem("NOTE_TEXT", '');
// clearInterval(this.autoSave);
this.getMyNote();
this.notetabType(2);
this.mynoteData = {
type: 1, //我发布的是1 我导入的是2
content: '',
playTime: '',
courseId: '',// 课程id
contentId: '',//课程内容id
courseName: '',// 课程名称
openType: 1,// 1表不公开 9表完全公开
};
}, 2000)
}
})
}
console.log(this.mynoteData,'this.mynoteData');
}
},
beforeDestroy() {