Commit f05cbf2a by yuquan.zhu Committed by chenzg

修改离职提示语

parent 0a9791f2
......@@ -58,7 +58,8 @@ public class RedisSessionInterceptor implements HandlerInterceptor {
try {
QyzxEmpLogin eld = BeanUtil.toBean(session.getAttribute("ui"), QyzxEmpLogin.class);
if(redisUtil.get("BlockUser"+eld.getId())!=null){
response401(response);
redisUtil.del("BlockUser"+eld.getId());
response302(response);
return false;
}
}catch (Exception e){
......@@ -82,6 +83,16 @@ public class RedisSessionInterceptor implements HandlerInterceptor {
}
}
private void response302(HttpServletResponse response) {
response.setCharacterEncoding("UTF-8");
response.setContentType("application/json; charset=utf-8");
try {
response.getWriter().print(new JSONObject(new ResponseResult().kickOut()).toString());
} catch (IOException e) {
e.printStackTrace();
}
}
@Override
public void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,
ModelAndView modelAndView) throws Exception {
......
......@@ -35,7 +35,7 @@ public class ResponseResult extends LinkedHashMap<String, Object> implements Ser
private static final String MESSAGE_FAIL = "操作失败";
private static final String MESSAGE_ERROR = "操作错误";
private static final String MESSAGE_UNLOGIN = "会话超时,请重新登录";
private static final String MESSAGE_KICKOUT = "当前账户已在其他地方登录,请重新登录";
private static final String MESSAGE_KICKOUT = "你已被管理员移出公司,请重新登录";
private static final String MESSAGE_PARAMERROR = "参数错误";
private static final String MESSAGE_UNAUTHORIZED = "授权错误";
private static final String MESSAGE_UNAUTHENTICATED = "认证错误";
......
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