学习园地

dev
LiuJiaNan 2024-05-23 15:40:03 +08:00
parent 168ff70e22
commit 7f54df0235
1 changed files with 14 additions and 14 deletions

View File

@ -150,7 +150,7 @@ export default {
this.CLASSCURRICULUM_ID = options.CLASSCURRICULUM_ID;
this.CLASS_ID = options.CLASS_ID;
this.STUDENT_ID = options.STUDENT_ID;
this.ISFACE = options.ISFACE;
this.ISFACE = '0';
this.fnInit();
},
onReady() {
@ -379,7 +379,7 @@ export default {
this.videoContext = uni.createVideoContext("video");
}
this.videoContext.play();
this.serverVideoPlayTime !== 0 && videoContext.seek(this.serverVideoPlayTime);
this.serverVideoPlayTime !== 0 && this.videoContext.seek(this.serverVideoPlayTime);
},
fnTimeUpdate(event) {
this.throttle(async () => {
@ -389,18 +389,18 @@ export default {
return;
}
//appbug10退
if(currentTime !== 0 && Math.abs(currentTime - this.serverVideoPlayTime) > 10) {
this.videoContext.pause();
uni.showModal({
title: "提示",
content: "app开发环境问题偶现当前视频进度获取不准确为了防止进度被覆盖请退出重新进入",
showCancel:false,
success: (res) => {
uni.navigateBack();
return;
},
});
}
// if(currentTime !== 0 && Math.abs(currentTime - this.serverVideoPlayTime) > 10) {
// this.videoContext.pause();
// uni.showModal({
// title: "",
// content: "app退",
// showCancel:false,
// success: (res) => {
// uni.navigateBack();
// return;
// },
// });
// }
this.changeVideoPlayTime = currentTime;
if (currentTime - this.serverVideoPlayTime >= 5) {
this.serverVideoPlayTime = currentTime;