完善登录和注册的提示逻辑

This commit is contained in:
jishenghua
2024-05-30 00:23:28 +08:00
parent aa775f99a3
commit da42261f5b
3 changed files with 13 additions and 13 deletions

View File

@@ -275,32 +275,32 @@
description: ((err.response || {}).data || {}).message || err.message || err.data.message || "请求出现错误请稍后再试",
duration: 4,
});
this.loginBtn = false;
//验证码刷新
this.form.setFieldsValue({'inputCode':''})
this.handleChangeCheckCode()
this.loginBtn = false;
},
generateCode(value){
this.verifiedCode = value.toLowerCase()
},
departConfirm(res, loginName){
if(res.code==200){
if(res.code === 200){
let err = {};
if(res.data.msgTip == 'user can login'){
if(res.data.msgTip === 'user can login'){
this.loginSuccess(res)
} else if(res.data.msgTip == 'user is not exist'){
} else if(res.data.msgTip === 'user is not exist'){
err.message = '用户不存在';
this.requestFailed(err)
this.Logout();
} else if(res.data.msgTip == 'user password error'){
} else if(res.data.msgTip === 'user password error'){
err.message = '用户密码不正确';
this.requestFailed(err)
this.Logout();
} else if(res.data.msgTip == 'user is black'){
} else if(res.data.msgTip === 'user is black'){
err.message = '用户被禁用';
this.requestFailed(err)
this.Logout();
} else if(res.data.msgTip == 'tenant is black'){
} else if(res.data.msgTip === 'tenant is black'){
if(loginName === 'jsh') {
err.message = 'jsh用户已停用请注册租户进行体验';
} else {
@@ -308,11 +308,11 @@
}
this.requestFailed(err)
this.Logout();
} else if(res.data.msgTip == 'tenant is expire'){
} else if(res.data.msgTip === 'tenant is expire'){
err.message = '试用期已结束,请联系客服续费';
this.requestFailed(err)
this.Logout();
} else if(res.data.msgTip == 'access service error'){
} else if(res.data.msgTip === 'access service error'){
err.message = '查询服务异常';
this.requestFailed(err)
this.Logout();

View File

@@ -245,10 +245,10 @@
description: res.data.message || "注册失败",
duration: 2
});
that.registerBtn = false
//验证码刷新
this.form.setFieldsValue({'inputCode':''})
this.handleChangeCheckCode()
that.registerBtn = false
}
}).catch((err) => {
that.requestFailed(err);