Commit 53b20ddb authored by hezhen's avatar hezhen

123

parent 639a80aa
...@@ -188,8 +188,14 @@ public class AuthController { ...@@ -188,8 +188,14 @@ public class AuthController {
if(result==null){ if(result==null){
data.put("status",1001); data.put("status",1001);
}else { }else {
Integer positionId=result.getInteger("positionId")==null?0:result.getInteger("positionId");
if (positionId==4 || positionId==1 || positionId==2 || positionId==3){
String token=appAuthService.getToken(username,result.getInteger("userId")); String token=appAuthService.getToken(username,result.getInteger("userId"));
data.put("token",token); data.put("token",token);
}else {
data.put("status",ResultCode.FAILED_CODE);
data.put("message","登录失败");
}
} }
} }
return data; return data;
......
...@@ -435,6 +435,7 @@ public class AppPermissionService { ...@@ -435,6 +435,7 @@ public class AppPermissionService {
data.put("userId", userid); data.put("userId", userid);
data.put("imUserId", userVo.getImUserid()); data.put("imUserId", userVo.getImUserid());
data.put("code", userVo.getCode()); data.put("code", userVo.getCode());
data.put("positionId", userVo.getPositionId());
//更新登录时间 和 ip //更新登录时间 和 ip
String clientIp = getIp(); String clientIp = getIp();
appUserLoginBiz.updateLoginInfo(userid, clientIp); appUserLoginBiz.updateLoginInfo(userid, clientIp);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment