提交 67d5f2e6 authored 作者: lihuihui's avatar lihuihui

updata

上级 fa548700
......@@ -172,7 +172,7 @@ export default {
clearInterval(this.clearTime)
if (!n) {
this.$router.replace({
path: '/examEnd',
path: '/examEnd'
})
}
window.localStorage.setItem('showflag', 'true')
......@@ -213,10 +213,10 @@ export default {
this.isExamTimeDate = false
clearInterval(this.clearTime)
this.examTime = '00:00:00 倒计时'
this.endExam(1)
} else {
this.countDown(countTime)
}
countTime === 2 && (this.endExam(1))
}, 1000)
},
addZero(i) {
......@@ -242,19 +242,6 @@ export default {
}).catch(err => {
this.isExamEnd = true
console.log(err)
// if (err.message === '考试已结束') {
// this.$alert(err.message, {
// callback: action => {
// this.$router.replace({
// path: '/examEnd'
// })
// }
// })
// } else {
// this.$alert(err.message, {
// callback: action => {}
// })
// }
})
},
getCache() {
......
......@@ -36,12 +36,11 @@ export default {
this.width = '100%'
}, 1000)
setTimeout(() => {
// this.ispop = false
this.ispop = false
window.localStorage.removeItem('showflag')
setTimeout(() => {
console.log(JSON.parse(window.localStorage.getItem('examInfo')).exam_id)
this.$router.replace({
path: `/login/${this.$route.query.id}`
path: `/login/${JSON.parse(window.localStorage.getItem('examInfo')).exam_id}`
})
}, 5000)
}, 4000)
......
......@@ -232,13 +232,13 @@ export default {
if (this.form[this.allForm[i].key] !== '') {
if (this.allForm[i].key === 'mobile') {
if (!(/^1[3456789]\d{9}$/.test(this.form.mobile))) {
this.$alert('手机号不正确')
this.$alert('手机号格式不正确')
return false
}
}
if (this.allForm[i].key === 'email') {
if (!(/^([a-zA-Z\d])(\w)+@[a-zA-Z\d]+\.[a-zA-Z]{2,4}$/.test(this.form.email))) {
this.$alert('邮箱不正确')
this.$alert('邮箱格式不正确')
return false
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论