提交 63db5cfc authored 作者: lihuihui's avatar lihuihui

错题集缓存记录修改

上级 cd235133
...@@ -194,8 +194,8 @@ export default { ...@@ -194,8 +194,8 @@ export default {
// 缓存试题 // 缓存试题
cacheQuestion() { cacheQuestion() {
const param = { const param = {
type: this.$route.query.type, type: this.$route.query.type === undefined ? 1 : this.$route.query.type,
question_type: this.$route.query.questionType, question_type: this.$route.query.questionType === undefined ? '' : this.$route.query.questionType,
answer: JSON.stringify(this.cacheList) answer: JSON.stringify(this.cacheList)
} }
api.cacheQuestion(param).then(res => {}) api.cacheQuestion(param).then(res => {})
...@@ -231,8 +231,8 @@ export default { ...@@ -231,8 +231,8 @@ export default {
this.$router.push({ this.$router.push({
name: 'answerCard', name: 'answerCard',
query: { query: {
type: this.$route.query.type ? this.$route.query.type : 1, type: this.$route.query.type === undefined ? 1 : this.$route.query.type,
questionType: this.$route.query.questionType questionType: this.$route.query.questionType === undefined ? '' : this.$route.query.questionType
} }
}) })
}, },
...@@ -317,8 +317,8 @@ export default { ...@@ -317,8 +317,8 @@ export default {
// 初始化数据 || 翻页请求数据 // 初始化数据 || 翻页请求数据
initData(pages, isPush) { initData(pages, isPush) {
const params = { const params = {
type: this.$route.query.type ? this.$route.query.type : 1, type: this.$route.query.type === undefined ? 1 : this.$route.query.type,
question_type: this.$route.query.questionType, question_type: this.$route.query.questionType === undefined ? '' : this.$route.query.questionType,
page: pages, page: pages,
page_size: 30 page_size: 30
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论