Commit 4ce3aa8d authored by Facius's avatar Facius

improvement: 首页未登录跳转到登录页面

parent 886e863c
...@@ -397,6 +397,12 @@ export default { ...@@ -397,6 +397,12 @@ export default {
} }
}, },
handleClickLeftTop() { handleClickLeftTop() {
if (!this.vuex_token) {
this.$u.route({
url: 'pages/login/index',
})
return
}
this.$u.route({ this.$u.route({
url: 'pages/learn/selectCategory', url: 'pages/learn/selectCategory',
}) })
...@@ -413,6 +419,12 @@ export default { ...@@ -413,6 +419,12 @@ export default {
}) })
}, },
handleClickItem(key) { handleClickItem(key) {
if (!this.vuex_token) {
this.$u.route({
url: 'pages/login/index',
})
return
}
if (this.info.id) { if (this.info.id) {
// 跳转到学练记录 // 跳转到学练记录
this.$u.route({ this.$u.route({
...@@ -429,8 +441,6 @@ export default { ...@@ -429,8 +441,6 @@ export default {
} }
}, },
handleClickExperience() { handleClickExperience() {
// this.selected.state = false
// this.$u.vuex('experience', false)
// 体验 // 体验
// 1.顺序答题 2.随机练习 3.模拟考试 4.收藏答题 5.错题答题 6.专项练习-单选 7.专项练习-多选 8.专项练习-判断 9.专项练习-答案是 // 1.顺序答题 2.随机练习 3.模拟考试 4.收藏答题 5.错题答题 6.专项练习-单选 7.专项练习-多选 8.专项练习-判断 9.专项练习-答案是
this.$u.route({ this.$u.route({
...@@ -529,6 +539,12 @@ export default { ...@@ -529,6 +539,12 @@ export default {
this.finishCount = this.answerCount[this.questionWarehouseId] || 0 this.finishCount = this.answerCount[this.questionWarehouseId] || 0
}, },
handleSelectTip() { handleSelectTip() {
if (!this.vuex_token) {
this.$u.route({
url: 'pages/login/index',
})
return
}
this.$u.route({ this.$u.route({
url: 'pages/learn/detail', url: 'pages/learn/detail',
params: { params: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment