提交 791924c2 编写于 作者: guangjun.yang's avatar guangjun.yang

如果没有找到,则不做后面操作

上级 90beb7ef
...@@ -56,6 +56,8 @@ export default { ...@@ -56,6 +56,8 @@ export default {
Toast("已是第一题"); Toast("已是第一题");
} else { } else {
let cIndex = findQuestionIndexNo(this.questionList, "titleNo", this.currentQuestion.titleNo); let cIndex = findQuestionIndexNo(this.questionList, "titleNo", this.currentQuestion.titleNo);
// 如果没有找到,则不做后面操作
if(!this.questionList[cIndex - 1]) return;
this.$store.commit( this.$store.commit(
"SET_CURRENT_QUESTION", "SET_CURRENT_QUESTION",
this.questionList[cIndex - 1] || { answerList: [] } this.questionList[cIndex - 1] || { answerList: [] }
...@@ -68,7 +70,6 @@ export default { ...@@ -68,7 +70,6 @@ export default {
}, },
// 下一页 // 有可能要触发下分页(后面的个数只有一条) // 下一页 // 有可能要触发下分页(后面的个数只有一条)
// TODO
next() { next() {
if(!this.canRun()) return; if(!this.canRun()) return;
this.$sendBuriedData({ this.$sendBuriedData({
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册