Commit c0410a4a authored by Damon's avatar Damon

refactor: 每日一练

parent cce6118d
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
<answer-operation-tips :show.sync="show" /> <answer-operation-tips :show.sync="show" />
<answer-complete-pop <answer-complete-pop
:numberList="result" :numberList="result"
type="completeType" :type="completeType"
:visible.sync="visible" :visible.sync="visible"
@cancel="cancel" @cancel="cancel"
@submit="submit" @submit="submit"
...@@ -274,11 +274,12 @@ export default { ...@@ -274,11 +274,12 @@ export default {
this.$u.vuex('questionList', this.list) this.$u.vuex('questionList', this.list)
// 每日一练数量统计 // 每日一练数量统计
if (this.daily) { if (this.type === 1 && this.daily) {
if (this.dailyCount < 9) this.dailyCount++ if (this.dailyCount < 3) this.dailyCount++
if (this.dailyCount === 9) { if (this.dailyCount === 3) {
this.completeType = 'daily' this.completeType = 'daily'
this.visible = true this.visible = true
return
} }
} }
...@@ -301,7 +302,8 @@ export default { ...@@ -301,7 +302,8 @@ export default {
}, },
// 弹框确认 // 弹框确认
submit() { submit() {
if (this.completeType = 'daily') { if (this.completeType === 'daily') {
this.daily = false
this.visible = false this.visible = false
} else { } else {
// 提前交卷 // 提前交卷
...@@ -312,7 +314,7 @@ export default { ...@@ -312,7 +314,7 @@ export default {
}, },
// 弹框取消 // 弹框取消
cancel() { cancel() {
if (this.completeType = 'daily') { // 查看记录 if (this.completeType === 'daily') { // 查看记录
// this.$u.route('/pages/index/index') // this.$u.route('/pages/index/index')
} else { } else {
this.visible = false this.visible = false
......
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