|
@@ -2451,7 +2451,6 @@ export default {
|
|
fromRebuild: this.isRebuild,
|
|
fromRebuild: this.isRebuild,
|
|
}); //通知播放结束,不来自重修目录的点击不用弹窗学习下一节
|
|
}); //通知播放结束,不来自重修目录的点击不用弹窗学习下一节
|
|
uni.$emit("playNext" + playNextId); //通知播放结束
|
|
uni.$emit("playNext" + playNextId); //通知播放结束
|
|
- uni.$emit('playNextSection', this.curPlayIndex) // 播放下一节
|
|
|
|
}
|
|
}
|
|
|
|
|
|
self.ossAvatarUrl = "";
|
|
self.ossAvatarUrl = "";
|
|
@@ -2687,50 +2686,66 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
//播放下一节
|
|
//播放下一节
|
|
- async nextSection(){
|
|
|
|
- console.log("放完了",this.menuAllList)
|
|
|
|
|
|
+ nextSection(){
|
|
|
|
+ // console.log("放完了",this.menuAllList)
|
|
if(!this.menuAllList.length){
|
|
if(!this.menuAllList.length){
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- console.log('this.sectionId:', this.sectionId, 'this.chapterId:', this.chapterId, 'this.moduleId:', this.moduleId);
|
|
|
|
- //第一个弹窗
|
|
|
|
|
|
+ // console.log('this.sectionId:', this.sectionId, 'this.chapterId:', this.chapterId, 'this.moduleId:', this.moduleId);
|
|
this.curPlayIndex = this.menuAllList.findIndex((item) => {
|
|
this.curPlayIndex = this.menuAllList.findIndex((item) => {
|
|
let i_sectionId = item.sectionId || 0
|
|
let i_sectionId = item.sectionId || 0
|
|
let i_chapterId = item.chapterId || 0
|
|
let i_chapterId = item.chapterId || 0
|
|
let i_moduleId = item.moduleId || 0
|
|
let i_moduleId = item.moduleId || 0
|
|
return i_sectionId == this.playSectionId && i_chapterId == this.chapterId && i_moduleId == this.moduleId
|
|
return i_sectionId == this.playSectionId && i_chapterId == this.chapterId && i_moduleId == this.moduleId
|
|
})
|
|
})
|
|
- console.log('查找到的curItem:', this.curPlayIndex);
|
|
|
|
|
|
+ // console.log('查找到的curItem:', this.curPlayIndex);
|
|
let data = this.menuAllList[this.curPlayIndex+1];
|
|
let data = this.menuAllList[this.curPlayIndex+1];
|
|
if (!data) {
|
|
if (!data) {
|
|
//第二个弹窗
|
|
//第二个弹窗
|
|
- }
|
|
|
|
- console.log("放下一个", data)
|
|
|
|
- this.moduleId = data.moduleId
|
|
|
|
- this.chapterId = data.chapterId
|
|
|
|
- this.sectionId = data.sectionId
|
|
|
|
- if(data.sectionType == 1) { //录播
|
|
|
|
- this.$store.commit("setPlaySectionId", { playSectionId: data.sectionId })
|
|
|
|
- this.$store.commit("setPlayVID", { playVID: data.recordingUrl })
|
|
|
|
|
|
+ uni.showModal({
|
|
|
|
+ title: '温馨提示',
|
|
|
|
+ content: '当前最后一节视频已学完 请检查所有章节是否学习完成?',
|
|
|
|
+ showCancel: false,
|
|
|
|
+ success: (res) => {
|
|
|
|
+ if (res.confirm) {
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ } else {
|
|
|
|
+ uni.showModal({
|
|
|
|
+ title: '温馨提示',
|
|
|
|
+ content: '当前节视频已学完,继续学习下一节?',
|
|
|
|
+ success: async (res) => {
|
|
|
|
+ if (res.confirm) {
|
|
|
|
+ console.log("放下一个", data)
|
|
|
|
+ this.moduleId = data.moduleId
|
|
|
|
+ this.chapterId = data.chapterId
|
|
|
|
+ this.sectionId = data.sectionId
|
|
|
|
+ if(data.sectionType == 1) { //录播
|
|
|
|
+ this.$store.commit("setPlaySectionId", { playSectionId: data.sectionId })
|
|
|
|
+ this.$store.commit("setPlayVID", { playVID: data.recordingUrl })
|
|
|
|
|
|
- this.sectionItem = data;
|
|
|
|
- await this.getPhotoLastRecord() // 获取拍照历史
|
|
|
|
- this.playVideo(data)
|
|
|
|
- } else if(data.sectionType == 2) { //直播
|
|
|
|
- this.studyRecordGetLastLive();
|
|
|
|
- } else if(data.sectionType == 3) { //回放
|
|
|
|
- this.$store.commit("setPlaySectionId", { playSectionId: data.sectionId })
|
|
|
|
- this.$store.commit("setPlayVID", { playVID: data.recordingUrl })
|
|
|
|
- this.sectionItem = data
|
|
|
|
- this.playVideo(data)
|
|
|
|
|
|
+ this.sectionItem = data;
|
|
|
|
+ await this.getPhotoLastRecord() // 获取拍照历史
|
|
|
|
+ this.playVideo(data)
|
|
|
|
+ } else if(data.sectionType == 2) { //直播
|
|
|
|
+ this.studyRecordGetLastLive();
|
|
|
|
+ } else if(data.sectionType == 3) { //回放
|
|
|
|
+ this.$store.commit("setPlaySectionId", { playSectionId: data.sectionId })
|
|
|
|
+ this.$store.commit("setPlayVID", { playVID: data.recordingUrl })
|
|
|
|
+ this.sectionItem = data
|
|
|
|
+ this.playVideo(data)
|
|
|
|
+ }
|
|
|
|
+ let playNextId = `moduleId${data.moduleId}chapterId${data.chapterId}sectionId${data.sectionId}`;
|
|
|
|
+ this.$store.commit("updatePlayNextId", playNextId);
|
|
|
|
+ this.updateChapterOpen(true)
|
|
|
|
+ this.reStart = false
|
|
|
|
+ this.getMenuList()
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
}
|
|
}
|
|
- let playNextId = `moduleId${data.moduleId}chapterId${data.chapterId}sectionId${data.sectionId}`;
|
|
|
|
- this.$store.commit("updatePlayNextId", playNextId);
|
|
|
|
- // this.updateChapterOpen(true)
|
|
|
|
- // this.$emit('openModuleTwo', data)\
|
|
|
|
- data.id = data.moduleId
|
|
|
|
- uni.$emit('openEmit', data)
|
|
|
|
- },
|
|
|
|
|
|
+ },
|
|
|
|
|
|
//拍照
|
|
//拍照
|
|
openPhoto() {
|
|
openPhoto() {
|