|
@@ -8,7 +8,7 @@
|
|
|
<view v-if="!down">
|
|
|
<view v-for="(itemM,indexM) in list" :key="indexM">
|
|
|
<view v-if="itemM.type!=2">
|
|
|
- <courseSection :courseId="courseId" :goodsId="goodsId" :isBuy="isBuy" :nextMenuItem="findNextSection(indexM)" :isRebuild="isRebuild" :gradeId="gradeId" :menuItem="itemM" :levelId="levelId+'-'+itemM.sectionId"></courseSection>
|
|
|
+ <courseSection :courseId="courseId" @playEnd="refreshList" :goodsId="goodsId" :isBuy="isBuy" :nextMenuItem="findNextSection(indexM)" :isRebuild="isRebuild" :gradeId="gradeId" :menuItem="itemM" :levelId="levelId+'-'+itemM.sectionId"></courseSection>
|
|
|
<u-line v-if="indexM<list.length-1"></u-line>
|
|
|
</view>
|
|
|
<view v-if="itemM.type==2">
|
|
@@ -43,9 +43,9 @@ import courseSection from '@/components/course/courseSection.vue';
|
|
|
export default {
|
|
|
name: 'courseChapter',
|
|
|
props: {
|
|
|
- learningOrder:{ //是否设置学习顺序 1 设置 0不设置
|
|
|
+ learningOrder:{ //是否设置学习顺序 0 设置 1不设置
|
|
|
type:Number,
|
|
|
- default:0
|
|
|
+ default:1
|
|
|
},
|
|
|
menuItem: {
|
|
|
type: Object,
|
|
@@ -85,7 +85,6 @@ export default {
|
|
|
list:[],
|
|
|
examList:{},
|
|
|
canLearn:false, //是否全部视频看完才可以练习、测试
|
|
|
- clickItem:'',
|
|
|
};
|
|
|
},
|
|
|
onLoad() {},
|
|
@@ -95,10 +94,7 @@ export default {
|
|
|
|
|
|
},
|
|
|
onPageShow() {
|
|
|
-
|
|
|
- if(this.clickItem) {
|
|
|
- this.refreshList();
|
|
|
- }
|
|
|
+ this.refreshList();
|
|
|
},
|
|
|
methods: {
|
|
|
refreshList() {
|
|
@@ -115,10 +111,9 @@ export default {
|
|
|
* 去做题
|
|
|
*/
|
|
|
async toDo(id,goodsId =0,moduleId = 0, chapterId = 0,item,index) {
|
|
|
- this.clickItem = item;
|
|
|
|
|
|
console.log(this.learningOrder)
|
|
|
- if(this.learningOrder == 1) {
|
|
|
+ if(this.learningOrder == 0) {
|
|
|
if(this.canLearn) {
|
|
|
|
|
|
let num = await this.bankRecordDoNum(item.typeId)
|