|
|
|
@ -120,13 +120,6 @@ import store from "@/store"; |
|
|
|
|
data() { |
|
|
|
|
return { |
|
|
|
|
loading: false, |
|
|
|
|
myExam: { |
|
|
|
|
examName: '职业技能考试', |
|
|
|
|
grade_id: 1, |
|
|
|
|
subject_id: 7, |
|
|
|
|
examTime: '2024-1-12', |
|
|
|
|
examDays: 180, |
|
|
|
|
}, |
|
|
|
|
indexMenu: [ |
|
|
|
|
{ menuName: '视频课', key: 'video' }, |
|
|
|
|
{ menuName: '直播课', key: 'live' }, |
|
|
|
@ -141,15 +134,7 @@ import store from "@/store"; |
|
|
|
|
return store.getters.position; |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
watch: { |
|
|
|
|
myExam: { |
|
|
|
|
deep: true, |
|
|
|
|
handler() { |
|
|
|
|
this.getLearningData(); |
|
|
|
|
}, |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
onLoad() { |
|
|
|
|
onShow() { |
|
|
|
|
this.getLearningData(); |
|
|
|
|
}, |
|
|
|
|
onPageScroll(e) { |
|
|
|
@ -167,7 +152,6 @@ import store from "@/store"; |
|
|
|
|
async getLearningData() { |
|
|
|
|
try { |
|
|
|
|
const { data } = await getLearningData({ |
|
|
|
|
subject_id: this.myExam.subject_id, |
|
|
|
|
city: this.position, |
|
|
|
|
}); |
|
|
|
|
console.log(data); |
|
|
|
@ -199,11 +183,11 @@ import store from "@/store"; |
|
|
|
|
toMoreCourse(key) { |
|
|
|
|
if (key === 'offline_courses') { |
|
|
|
|
uni.navigateTo({ |
|
|
|
|
url: `/pages/activity/activity_list?gradeId=${this.myExam.gradeId}&subjectId=${this.myExam.subjectId}` |
|
|
|
|
url: `/pages/activity/activity_list?gradeId=${this.learningData.exam.gradeId}&subjectId=${this.learningData.exam.subjectId}` |
|
|
|
|
}); |
|
|
|
|
} else { |
|
|
|
|
uni.navigateTo({ |
|
|
|
|
url: `/pages/special/search?gradeId=${this.myExam.grade_id}&subjectId=${this.myExam.subject_id}&specialType=${ key === 'live' ? 4 : 3}` |
|
|
|
|
url: `/pages/special/search?gradeId=${this.learningData.exam.grade_id}&subjectId=${this.learningData.exam.subject_id}&specialType=${ key === 'live' ? 4 : 3}` |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
@ -219,7 +203,7 @@ import store from "@/store"; |
|
|
|
|
}, |
|
|
|
|
toPractice(id) { |
|
|
|
|
uni.navigateTo({ |
|
|
|
|
url: `/pages/topic/problem_index?id=${id}`, |
|
|
|
|
url: `/pages/special/question_index?id=${id}&is_analysis=${1}`, |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|