8d9389d9 by lttnew

申请考点提示

1 parent 4eb1ea9e
...@@ -203,6 +203,10 @@ function register() { ...@@ -203,6 +203,10 @@ function register() {
203 goLogin() 203 goLogin()
204 } 204 }
205 }) 205 })
206 }).catch((err) => {
207 if (isServer500(err)) {
208 getCode()
209 }
206 }) 210 })
207 } 211 }
208 212
...@@ -285,6 +289,14 @@ function getCode() { ...@@ -285,6 +289,14 @@ function getCode() {
285 }) 289 })
286 } 290 }
287 291
292 function isServer500(err) {
293 const message = String(err?.message || err?.errMsg || '')
294 return err?.statusCode === 500 ||
295 err?.code === 500 ||
296 err?.data?.code === 500 ||
297 message.includes('HTTP 500')
298 }
299
288 // 发送短信验证码 300 // 发送短信验证码
289 function getCaptchaSms() { 301 function getCaptchaSms() {
290 if (!registerForm.value.telNo) { 302 if (!registerForm.value.telNo) {
......
...@@ -405,11 +405,14 @@ function checkDialogs() { ...@@ -405,11 +405,14 @@ function checkDialogs() {
405 405
406 async function checkExamPointDialog() { 406 async function checkExamPointDialog() {
407 console.log('checkExamPointDialog', app.globalData.userInfo.hintFlag ) 407 console.log('checkExamPointDialog', app.globalData.userInfo.hintFlag )
408 // const [err, res] = await to(api.getMyRecentExam()) 408 const [err, res] = await to(api.getMyRecentExam())
409 // if (err || !res?.data) return 409 if (err) return
410 // const status = res.data?.auditStatus 410 const examData = res?.data
411 const status = examData?.auditStatus
412 const canShowByExamStatus = examData == null || status == 0 || status == 3
411 // (status == 0 || status == 3) && 413 // (status == 0 || status == 3) &&
412 if ( 414 console.log('122', app.globalData.memberInfo?.activeStatus,app.globalData.authenticationStatus,app.globalData.deptType,app.globalData.userInfo.hintFlag, app.globalData.memberInfo?.isPoints)
415 if (canShowByExamStatus &&
413 app.globalData.memberInfo?.activeStatus == 1 && 416 app.globalData.memberInfo?.activeStatus == 1 &&
414 app.globalData.authenticationStatus == 2 && 417 app.globalData.authenticationStatus == 2 &&
415 app.globalData.deptType == 6 && 418 app.globalData.deptType == 6 &&
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!