账号禁止登录判断

This commit is contained in:
吕金泽 2022-11-23 09:10:39 +08:00
parent de3fab92f8
commit af614e9ef1

View File

@ -220,6 +220,10 @@ if(!user){
exit 0,'用户名或密码错误' exit 0,'用户名或密码错误'
} }
if(user.isLogin == '1'){
exit 0, '此账号禁止登录'
}
StpUtil.login(user.id) StpUtil.login(user.id)
var token = StpUtil.getTokenValueByLoginId(user.id) var token = StpUtil.getTokenValueByLoginId(user.id)
loginLog.token = token loginLog.token = token