This commit is contained in:
zhangsir
2024-07-05 10:37:40 +08:00
parent af05be5f81
commit bbb8f44983

View File

@@ -369,6 +369,8 @@
}, },
data() { data() {
return { return {
isContentTypeTwo: null,
isContentType: null,
activeId: '', activeId: '',
isFalse: false, isFalse: false,
defaultOpeneds: [], defaultOpeneds: [],
@@ -751,7 +753,8 @@
// this.contentData.status = 2; //进行中 // this.contentData.status = 2; //进行中
if(r.contentType != 61&&r.contentType != 20 && r.contentType != 10){ if(r.contentType != 61&&r.contentType != 20 && r.contentType != 10){
setTimeout(() => { setTimeout(() => {
this.contentData.status = 2; this.isContentTypeTwo = r.contentType
$this.isShowTime()
}, 2000); }, 2000);
} }
} }
@@ -782,6 +785,7 @@
$this.appendStudyOtherTime(); $this.appendStudyOtherTime();
}, 15000); //非音视频课程学习,十五秒后记录 }, 15000); //非音视频课程学习,十五秒后记录
//this.appendStudyTime(); //this.appendStudyTime();
this.isContentType = this.contentData.contentType
if (this.contentData.contentType != 50) { if (this.contentData.contentType != 50) {
this.handleTimeout = setTimeout(function(){ this.handleTimeout = setTimeout(function(){
$this.saveStudyInfo(); $this.saveStudyInfo();
@@ -810,6 +814,12 @@
//console.log(h,$this.controlHeight,'$this.controlHeight'); //console.log(h,$this.controlHeight,'$this.controlHeight');
}) })
}, },
isShowTime(){
if(this.isContentTypeTwo != this.contentData.contentType){
return
}
this.contentData.status = 2;
},
showRes(r, i, index,item) { //i:子节下标index:章下标 showRes(r, i, index,item) { //i:子节下标index:章下标
// 无权限查看不能点击 // 无权限查看不能点击
if(!this.isCrowd){ if(!this.isCrowd){
@@ -1443,6 +1453,10 @@
}); });
}, },
saveStudyInfo() { saveStudyInfo() {
if(this.isContentType != this.contentData.contentType){
//定时器产生的,不记录
return
}
//记录课件学习信息 //记录课件学习信息
if (this.contentData.contentType >= 60) { if (this.contentData.contentType >= 60) {
//只有在课件页面停留超过5秒才会记录 //只有在课件页面停留超过5秒才会记录