Commit bcf7c42d by kyle

试听课程以及未听的不保存轨迹

parent 5051ea4f
......@@ -474,6 +474,7 @@
},
// // 暂停播放
async pause() {
if (this.courseInfo.status != 1){
console.log('pause')
this.isPauseFlag = true;
if (this.timer) {
......@@ -487,6 +488,7 @@
this.playbackId = null;
this.courseDetail();
}
}
},
timeupdate(e) {
this.totalTime = e.detail.duration;
......@@ -574,6 +576,7 @@
this.videoContext = uni.createVideoContext('myVideo');
},
onUnload() {
if (this.courseInfo.status != 1 && this.viewTime!=0) {
this.videoContext.pause();
this.saveVideoPlayback();
if (this.timer) {
......@@ -581,6 +584,7 @@
}
}
}
}
</script>
<style lang="scss">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment