mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-19 07:46:43 +08:00
提交音频的时间控制修改
This commit is contained in:
@@ -520,10 +520,10 @@ export default {
|
|||||||
//判断是否完成
|
//判断是否完成
|
||||||
let completeType=this.curriculumData.completeSetup;
|
let completeType=this.curriculumData.completeSetup;
|
||||||
let completeSecond=this.curriculumData.second;
|
let completeSecond=this.curriculumData.second;
|
||||||
if(!completeSecond){
|
if(!completeSecond || completeType=0){
|
||||||
completeSecond=5;//如果没有就采用默认的时间了
|
completeSecond=5;//如果没有就采用默认的时间了
|
||||||
}
|
}
|
||||||
if(completeType>0 && this.contentData.status<9){ //因为1按进度,2按时长都是计算时间,所以这里直接大于0处理
|
if(this.contentData.status<9){ //因为1按进度,2按时长都是计算时间,所以这里直接大于0处理
|
||||||
if(completeType==1){
|
if(completeType==1){
|
||||||
let finishPercent=this.curriculumData.setupTage;
|
let finishPercent=this.curriculumData.setupTage;
|
||||||
let videDuration=this.contentData.duration;
|
let videDuration=this.contentData.duration;
|
||||||
@@ -531,7 +531,7 @@ export default {
|
|||||||
if(percent>=finishPercent){
|
if(percent>=finishPercent){
|
||||||
this.finishStudyItem();
|
this.finishStudyItem();
|
||||||
}
|
}
|
||||||
}else if(completeType==2){
|
}else{
|
||||||
if(intTime>=completeSecond){
|
if(intTime>=completeSecond){
|
||||||
this.finishStudyItem();
|
this.finishStudyItem();
|
||||||
}
|
}
|
||||||
@@ -556,16 +556,16 @@ export default {
|
|||||||
audioPlay() {
|
audioPlay() {
|
||||||
//console.log("开始播放");
|
//console.log("开始播放");
|
||||||
let $this=this;
|
let $this=this;
|
||||||
if(this.contentData.status!=9){
|
// if(this.contentData.status!=9){
|
||||||
let completeType=this.curriculumData.completeSetup;
|
// let completeType=this.curriculumData.completeSetup;
|
||||||
if(completeType==0){
|
// if(completeType==0){
|
||||||
//默认5秒后学习完成.
|
// //默认5秒后学习完成.
|
||||||
$this.handleTimeout= setTimeout(function() {$this.saveStudyInfo();}, 5000); //5秒后记录学习完成
|
// $this.handleTimeout= setTimeout(function() {$this.saveStudyInfo();}, 5000); //5秒后记录学习完成
|
||||||
}else{
|
// }else{
|
||||||
//先记录进行中的学习内容
|
// //先记录进行中的学习内容
|
||||||
this.saveStudyItem();
|
// this.saveStudyItem();
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
},
|
},
|
||||||
audioPause() {
|
audioPause() {
|
||||||
//console.log("暂停");
|
//console.log("暂停");
|
||||||
|
|||||||
Reference in New Issue
Block a user