提交 e7692be6 authored 作者: lhh's avatar lhh

修改bug

上级 ef04d268
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
<div class="info"> <div class="info">
紫荆小秘书:13263110169(同微信)<br /> 紫荆小秘书:13263110169(同微信)<br />
地址:北京市海淀区中关村东路1号院清华科技园7号楼5层<br /> 地址:北京市海淀区中关村东路1号院清华科技园7号楼5层<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;深圳市福田区博今商务广场A座22层
<br />邮箱:WMC@ezijing.com <br />邮箱:WMC@ezijing.com
</div> </div>
</div> </div>
......
...@@ -17,7 +17,6 @@ getCourseDetail({ id: route.query?.id as string }).then((res: any) => { ...@@ -17,7 +17,6 @@ getCourseDetail({ id: route.query?.id as string }).then((res: any) => {
const d = res.data.course const d = res.data.course
if (d.chapters?.length) { if (d.chapters?.length) {
d.chapters = d.chapters.map((item: any) => { d.chapters = d.chapters.map((item: any) => {
console.log(item.id, route.query.chapterId, 'item.id === route.query.chapterId')
if (item.id === route.query.zId) { if (item.id === route.query.zId) {
item.show = true item.show = true
} else { } else {
...@@ -51,6 +50,7 @@ onMounted(() => { ...@@ -51,6 +50,7 @@ onMounted(() => {
chapter_id: route.query?.chapterId as string chapter_id: route.query?.chapterId as string
}).then((res: any) => { }).then((res: any) => {
// videoSrc.value = res.data.info?.FD // videoSrc.value = res.data.info?.FD
params._p = res.data?.cache?.pt
player = new Player({ player = new Player({
id: 'mse', id: 'mse',
url: res.data.info?.FD, url: res.data.info?.FD,
...@@ -63,7 +63,7 @@ onMounted(() => { ...@@ -63,7 +63,7 @@ onMounted(() => {
// 最大学习时刻 // 最大学习时刻
params._m = Math.max(ev.currentTime, params._m) params._m = Math.max(ev.currentTime, params._m)
params._c = ev.currentTime params._c = ev.currentTime
params._p = ev.currentTime params._p += 0.25
if (!ps.includes(parseInt(ev.currentTime))) { if (!ps.includes(parseInt(ev.currentTime))) {
ps.push(parseInt(ev.currentTime)) ps.push(parseInt(ev.currentTime))
} }
......
...@@ -8,19 +8,18 @@ const handleClickItem = (item: any) => { ...@@ -8,19 +8,18 @@ const handleClickItem = (item: any) => {
} }
const isEmpty = $computed(() => { const isEmpty = $computed(() => {
if (props?.data || props.data?.length === 0) return false const findIndex = props.data?.findIndex((item: any) => item.certificate !== '')
if (props.data?.findIndex((item: any) => item.certificate === '') !== -1) { if (findIndex !== -1) {
return false
} else {
return true return true
} }
return false
}) })
console.log(isEmpty, 'isEmpty') console.log(isEmpty, 'isEmpty')
</script> </script>
<template> <template>
<AppCard title="我的电子学习证明" id="team"> <AppCard title="我的电子学习证明" id="team">
<template #header-aside> </template> <template #header-aside></template>
<div class="course_list" v-if="isEmpty"> <div class="course_list" v-if="isEmpty">
<template v-for="item in data" :key="item.id"> <template v-for="item in data" :key="item.id">
<div class="list_item" v-if="item.certificate !== ''" @click="handleClickItem(item)"> <div class="list_item" v-if="item.certificate !== ''" @click="handleClickItem(item)">
......
...@@ -81,7 +81,7 @@ const editPassword = function () { ...@@ -81,7 +81,7 @@ const editPassword = function () {
<!-- 我的课程 --> <!-- 我的课程 -->
<Course :data="studyInfo?.courses" /> <Course :data="studyInfo?.courses" />
<!-- 电子证书 --> <!-- 电子证书 -->
<Cert :data="studyInfo?.courses" /> <Cert :data="studyInfo?.courses" v-if="studyInfo?.courses" />
<div class="logout" @click="onLogout">退出登录</div> <div class="logout" @click="onLogout">退出登录</div>
</div> </div>
</template> </template>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论