feat: 更新视频播放器组件,添加章节视频功能并优化返回逻辑
This commit is contained in:
@@ -6,11 +6,12 @@
|
||||
<!-- 页面内容 -->
|
||||
<view class="page-content">
|
||||
<!-- 课程视频 -->
|
||||
<AliPlayer
|
||||
<CourseVideo
|
||||
:video-list="videoList"
|
||||
:current-index="currentVideoIndex !== null ? currentVideoIndex : 0"
|
||||
:course="{courseTitle:courseTitle, chapterTitle: chapterTitle}"
|
||||
:cover="curriculumImgUrl || ''"
|
||||
:http="mainClient"
|
||||
/>
|
||||
|
||||
<!-- 选项卡 -->
|
||||
@@ -49,10 +50,15 @@
|
||||
import { ref } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { courseApi } from '@/api/modules/course'
|
||||
import AliPlayer from '@/components/ali-video/index.vue'
|
||||
import type { IChapterDetail } from '@/types/course'
|
||||
import type { IVideoInfo } from '@/types/video'
|
||||
|
||||
import { mainClient } from '@/api/clients'
|
||||
|
||||
import CourseVideo from '@/components/course/chapter-video.vue'
|
||||
import { useSafeBack } from '@/components/nav-bar/use-safe-back'
|
||||
useSafeBack()
|
||||
|
||||
// 页面参数
|
||||
const chapterId = ref<number>(0)
|
||||
const courseTitle = ref('')
|
||||
|
||||
Reference in New Issue
Block a user