|
|
@@ -18,12 +18,12 @@
|
|
|
<text class="course-name">单元:{{ subjectDetail.curDanyuanName }}</text>
|
|
|
<progress :percent="20" class="exam-progress-box" stroke-width="10" backgroundColor="#3c7dfd"
|
|
|
activeColor="#ffd11c" />
|
|
|
- <text class="course-name">继续学习</text>
|
|
|
+ <text class="course-name" @click="handlePlay(subjectDetail,'jixu')">继续学习</text>
|
|
|
</view>
|
|
|
<!-- 单元列表 -->
|
|
|
<view v-for="(unit, index) in danyuanList" :key="unit.danyuanId" :id="'unit-' + index" class="unit-item">
|
|
|
<!-- 单元标题 -->
|
|
|
- <view class="unit-title">
|
|
|
+ <view class="unit-title" @click="handleClickDanyuan(unit)">
|
|
|
<text class="unit-name">{{ unit.danyuanName }}</text>
|
|
|
<text class="unit-intro">{{ unit.danyuanIntro }}</text>
|
|
|
</view>
|
|
|
@@ -42,7 +42,7 @@
|
|
|
</view>
|
|
|
<view class="section-right">
|
|
|
<text class="section-number">第{{ section.number }}节</text>
|
|
|
- <text>播放按钮</text>
|
|
|
+ <text @click="handlePlay(section,'play')">播放按钮</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -50,6 +50,9 @@
|
|
|
<!-- 底部占位 -->
|
|
|
<view style="height: 100px; text-align: center;">查看更多内容</view>
|
|
|
</scroll-view>
|
|
|
+
|
|
|
+ <danyuanInfoVue ref="dyRef" v-if="isShow" @close="isShow= false"></danyuanInfoVue>
|
|
|
+
|
|
|
<CustomTabBar :currentTabNumber="1"></CustomTabBar>
|
|
|
</view>
|
|
|
</template>
|
|
|
@@ -59,6 +62,8 @@
|
|
|
import {
|
|
|
shuxueChanpinBanben
|
|
|
} from "@/api/chanpinneirong.js"
|
|
|
+ import danyuanInfoVue from '@/pages/xinshuxue/components/danyuanInfo.vue';
|
|
|
+
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
@@ -69,11 +74,13 @@
|
|
|
scrollTop: 0,
|
|
|
pageCacheKey: 'learn_page_scroll_cache',
|
|
|
hasRestoredScroll: false,
|
|
|
- showStickyTitle: false
|
|
|
+ showStickyTitle: false,
|
|
|
+ isShow: true
|
|
|
}
|
|
|
},
|
|
|
components: {
|
|
|
- CustomTabBar
|
|
|
+ CustomTabBar,
|
|
|
+ danyuanInfoVue,
|
|
|
},
|
|
|
onShow() {
|
|
|
|
|
|
@@ -105,7 +112,24 @@
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
-
|
|
|
+ handlePlay(da,code) {
|
|
|
+ let jieId = null;
|
|
|
+ if (code == 'jixu') {
|
|
|
+ jieId = da.curJieId;
|
|
|
+ } else {
|
|
|
+ jieId = da.jieId;
|
|
|
+ }
|
|
|
+ uni.navigateTo({
|
|
|
+ url: `/pages/xinshuxue/lookShipin?jieId=${jieId}`
|
|
|
+ })
|
|
|
+ },
|
|
|
+ handleClickDanyuan(item){
|
|
|
+ console.log('item', item)
|
|
|
+ this.isShow = true;
|
|
|
+ setTimeout(() => {
|
|
|
+ this.$refs.dyRef.handleShow(item.danyuanId)
|
|
|
+ },100)
|
|
|
+ },
|
|
|
|
|
|
loadDataFromApi() {
|
|
|
const req = {
|