视频循环调用接口进行限制

This commit is contained in:
zhangsir
2024-08-15 20:15:18 +08:00
parent 66d2a905a5
commit 34c9864fe5

View File

@@ -369,6 +369,7 @@
}, },
data() { data() {
return { return {
tentative: false,
isContentTypeTwo: null, isContentTypeTwo: null,
isContentType: null, isContentType: null,
activeId: '', activeId: '',
@@ -658,7 +659,7 @@
}, },
//替换播放区域 //替换播放区域
changePlayRes(r,item){ changePlayRes(r,item){
this.tentative = false;
if(this.appendStudyOtherHandle!=null){ if(this.appendStudyOtherHandle!=null){
window.clearTimeout(this.appendStudyOtherHandle); window.clearTimeout(this.appendStudyOtherHandle);
} }
@@ -1454,6 +1455,7 @@
}); });
}, },
saveStudyInfo() { saveStudyInfo() {
this.tentative = true
if(this.isContentType){ if(this.isContentType){
if(this.isContentType != this.contentData.contentType){ if(this.isContentType != this.contentData.contentType){
//定时器产生的,不记录 //定时器产生的,不记录
@@ -1647,7 +1649,7 @@
finishStudyItem() { //设置完成学习的内容,针对于音视频的内容 finishStudyItem() { //设置完成学习的内容,针对于音视频的内容
if (!this.contentData.studyItemId) { if (!this.contentData.studyItemId) {
//这种可能没有不过这里也是为了万中那个1 //这种可能没有不过这里也是为了万中那个1
this.saveStudyInfo(); !this.tentative && this.saveStudyInfo();
} else { } else {
let params = { let params = {
itemId: this.contentData.studyItemId, itemId: this.contentData.studyItemId,