登录直接展示验证框

dev
yujialong 3 years ago
parent 47b48df0dc
commit 5be69a4143
  1. 19
      src/views/Login.vue

@ -114,7 +114,7 @@ export default {
return {
activeIndex:"1",
showVerify:false,// -
showVerify: true,// -
verificationIMG:'',//
//
@ -134,7 +134,7 @@ export default {
},
// +
showPhoneVerify:false,// -
showPhoneVerify:true,// -
PhoneVerificationIMG:'',//
phoneOrEmail: {
account: '',
@ -142,7 +142,8 @@ export default {
code:'',
platform:3,
random:'',
distinguish:2
distinguish:2,
type: 2
},
phoneOrEmailrules:{
account: [{ validator: regPhoneOrEmail, trigger: 'blur' }],
@ -214,16 +215,16 @@ export default {
},
blur(){
if(!this.param.account){
return this.verificationIMG = ''
}
// if(!this.param.account){
// return this.verificationIMG = ''
// }
this.param.random = Math.floor(Math.random()*999999999)
this.verificationIMG = this.api.verification+'?random='+`${this.param.random}`
},
phoneBlur(){
if(!this.phoneOrEmail.account){
return this.PhoneVerificationIMG = ''
}
// if(!this.phoneOrEmail.account){
// return this.PhoneVerificationIMG = ''
// }
this.phoneOrEmail.random = Math.floor(Math.random()*999999999)
this.PhoneVerificationIMG = this.api.verification+'?random='+`${this.phoneOrEmail.random}`
},

Loading…
Cancel
Save