forked from github/dataease
fix(登录): 扫码登录失败错误提示
This commit is contained in:
parent
2c09394481
commit
9df4f4f2fd
@ -119,7 +119,7 @@ public class XDingtalkServer {
|
||||
LogUtil.error(e);
|
||||
Cookie cookie_error = new Cookie("DingtalkError", msg);
|
||||
cookie_error.setPath("/");
|
||||
|
||||
response.addCookie(cookie_error);
|
||||
return modelAndView;
|
||||
} catch (UnsupportedEncodingException e1) {
|
||||
e.printStackTrace();
|
||||
|
@ -123,7 +123,7 @@ public class XLarkServer {
|
||||
LogUtil.error(e);
|
||||
Cookie cookie_error = new Cookie("LarkError", msg);
|
||||
cookie_error.setPath("/");
|
||||
|
||||
response.addCookie(cookie_error);
|
||||
return modelAndView;
|
||||
} catch (UnsupportedEncodingException e1) {
|
||||
e.printStackTrace();
|
||||
|
@ -124,7 +124,7 @@ public class XWecomServer {
|
||||
LogUtil.error(e);
|
||||
Cookie cookie_error = new Cookie("WecomError", msg);
|
||||
cookie_error.setPath("/");
|
||||
|
||||
response.addCookie(cookie_error);
|
||||
return modelAndView;
|
||||
} catch (UnsupportedEncodingException e1) {
|
||||
e.printStackTrace();
|
||||
|
@ -233,6 +233,24 @@ export default {
|
||||
this.$error(msg)
|
||||
}
|
||||
this.clearOidcMsg()
|
||||
|
||||
if (Cookies.get('WecomError')) {
|
||||
this.$error(Cookies.get('WecomError'))
|
||||
this.switchCodeIndex(4)
|
||||
}
|
||||
this.clearWecomMsg()
|
||||
|
||||
if (Cookies.get('DingtalkError')) {
|
||||
this.$error(Cookies.get('DingtalkError'))
|
||||
this.switchCodeIndex(5)
|
||||
}
|
||||
this.clearDingtalkMsg()
|
||||
|
||||
if (Cookies.get('LarkError')) {
|
||||
this.$error(Cookies.get('LarkError'))
|
||||
this.switchCodeIndex(6)
|
||||
}
|
||||
this.clearLarkMsg()
|
||||
},
|
||||
|
||||
methods: {
|
||||
@ -254,6 +272,15 @@ export default {
|
||||
Cookies.remove('OidcError')
|
||||
Cookies.remove('IdToken')
|
||||
},
|
||||
clearWecomMsg() {
|
||||
Cookies.remove('WecomError')
|
||||
},
|
||||
clearDingtalkMsg() {
|
||||
Cookies.remove('DingtalkError')
|
||||
},
|
||||
clearLarkMsg() {
|
||||
Cookies.remove('LarkError')
|
||||
},
|
||||
showLoginImage(uiInfo) {
|
||||
this.uiInfo = getSysUI()
|
||||
if (!this.uiInfo || Object.keys(this.uiInfo).length === 0) {
|
||||
@ -287,6 +314,9 @@ export default {
|
||||
handleLogin() {
|
||||
this.initCache()
|
||||
this.clearOidcMsg()
|
||||
this.clearWecomMsg()
|
||||
this.clearDingtalkMsg()
|
||||
this.clearLarkMsg()
|
||||
this.$refs.loginForm.validate(valid => {
|
||||
if (valid) {
|
||||
this.loading = true
|
||||
|
Loading…
Reference in New Issue
Block a user