|
@@ -334,7 +334,6 @@ export default {
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
async onShow() {
|
|
async onShow() {
|
|
|
- console.log('-----couIndex', this.couIndex, this.courseId, this.courseName)
|
|
|
|
|
this.getInfo() // 判断有没有关注公众号
|
|
this.getInfo() // 判断有没有关注公众号
|
|
|
this.isClickOff() //关注公众号,每天最多显示1次;当天学员关闭弹窗后,无需再显示
|
|
this.isClickOff() //关注公众号,每天最多显示1次;当天学员关闭弹窗后,无需再显示
|
|
|
uni.removeStorageSync('goPath')
|
|
uni.removeStorageSync('goPath')
|
|
@@ -385,7 +384,7 @@ export default {
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
async onPullDownRefresh() {
|
|
async onPullDownRefresh() {
|
|
|
- console.log('下拉this.courseId:', this.courseId)
|
|
|
|
|
|
|
+ // console.log('下拉this.courseId:', this.courseId)
|
|
|
if (this.tabNum == 0) {
|
|
if (this.tabNum == 0) {
|
|
|
this.list1 = []
|
|
this.list1 = []
|
|
|
this.paramList[0].pageNum = 1
|
|
this.paramList[0].pageNum = 1
|
|
@@ -397,7 +396,7 @@ export default {
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
async onReachBottom() {
|
|
async onReachBottom() {
|
|
|
- console.log('加载this.courseId:', this.courseId, this.list1.length, this.paramList[0].total)
|
|
|
|
|
|
|
+ // console.log('加载this.courseId:', this.courseId, this.list1.length, this.paramList[0].total)
|
|
|
if (this.tabNum == 0) {
|
|
if (this.tabNum == 0) {
|
|
|
if (this.list1.length < this.paramList[0].total) {
|
|
if (this.list1.length < this.paramList[0].total) {
|
|
|
this.paramList[0].pageNum++
|
|
this.paramList[0].pageNum++
|
|
@@ -424,7 +423,6 @@ export default {
|
|
|
methods: {
|
|
methods: {
|
|
|
...mapActions(['getUserInfo','appCommonConfig']),
|
|
...mapActions(['getUserInfo','appCommonConfig']),
|
|
|
tobuy(item) {
|
|
tobuy(item) {
|
|
|
- // console.log(item)
|
|
|
|
|
if (item.goodsType == 2) {
|
|
if (item.goodsType == 2) {
|
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
|
url: '/pages2/bank/detail?id='+item.goodsId
|
|
url: '/pages2/bank/detail?id='+item.goodsId
|
|
@@ -615,7 +613,7 @@ export default {
|
|
|
this.list2.push(...list2)
|
|
this.list2.push(...list2)
|
|
|
},
|
|
},
|
|
|
async changeSub(subjectId, index) {
|
|
async changeSub(subjectId, index) {
|
|
|
- console.log('subjectId, index:', subjectId, index, 'this.courseId:', this.courseId, 'this.bankId:', this.bankId)
|
|
|
|
|
|
|
+ // console.log('subjectId, index:', subjectId, index, 'this.courseId:', this.courseId, 'this.bankId:', this.bankId)
|
|
|
this.subIndex = index
|
|
this.subIndex = index
|
|
|
this.courSubjectId = subjectId
|
|
this.courSubjectId = subjectId
|
|
|
this.paramList[this.tabNum].pageNum = 1
|
|
this.paramList[this.tabNum].pageNum = 1
|
|
@@ -652,7 +650,7 @@ export default {
|
|
|
recommendId: x.recommendId
|
|
recommendId: x.recommendId
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
- console.log('couIndex', this.couIndex, this.courseName)
|
|
|
|
|
|
|
+ // console.log('couIndex', this.couIndex, this.courseName)
|
|
|
//题库
|
|
//题库
|
|
|
this.bankName = list.filter(x => x.type == 2).sort((a,b) => a.sort - b.sort).map(x => {
|
|
this.bankName = list.filter(x => x.type == 2).sort((a,b) => a.sort - b.sort).map(x => {
|
|
|
return {
|
|
return {
|
|
@@ -668,7 +666,7 @@ export default {
|
|
|
courseId = this.courseName[0].recommendId
|
|
courseId = this.courseName[0].recommendId
|
|
|
this.courseId = this.courseName[0].recommendId
|
|
this.courseId = this.courseName[0].recommendId
|
|
|
}
|
|
}
|
|
|
- console.log('courseId:', courseId)
|
|
|
|
|
|
|
+ // console.log('courseId:', courseId)
|
|
|
this.getSubjectList(courseId)
|
|
this.getSubjectList(courseId)
|
|
|
let list1 = await this.getGoodsList(courseId, 0, '')
|
|
let list1 = await this.getGoodsList(courseId, 0, '')
|
|
|
this.list1.push(...list1)
|
|
this.list1.push(...list1)
|
|
@@ -697,7 +695,7 @@ export default {
|
|
|
recommendId: recommendId
|
|
recommendId: recommendId
|
|
|
}
|
|
}
|
|
|
subjectId && (params.subjectId = subjectId)
|
|
subjectId && (params.subjectId = subjectId)
|
|
|
- console.log('params:', params)
|
|
|
|
|
|
|
+ // console.log('params:', params)
|
|
|
this.$http({
|
|
this.$http({
|
|
|
url: `/app/common/activity/recommend/goodsList`,
|
|
url: `/app/common/activity/recommend/goodsList`,
|
|
|
method: 'get',
|
|
method: 'get',
|
|
@@ -724,7 +722,7 @@ export default {
|
|
|
if (res.data.code == 200) {
|
|
if (res.data.code == 200) {
|
|
|
let data = res.data.data || []
|
|
let data = res.data.data || []
|
|
|
this.subjectList = [{ id: '', subjectName: '全部'}, ...data]
|
|
this.subjectList = [{ id: '', subjectName: '全部'}, ...data]
|
|
|
- console.log('this.subjectList:', this.subjectList)
|
|
|
|
|
|
|
+ // console.log('this.subjectList:', this.subjectList)
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|