Commit e01c52a7 authored by 季圣华's avatar 季圣华
Browse files

解决获取管理系统信息的issue的问题

parent 356ae93f
...@@ -113,6 +113,7 @@ public class UserController { ...@@ -113,6 +113,7 @@ public class UserController {
// new Timestamp(System.currentTimeMillis()), (short) 0, "管理用户:" + username + " 登录系统", username + " 登录系统")); // new Timestamp(System.currentTimeMillis()), (short) 0, "管理用户:" + username + " 登录系统", username + " 登录系统"));
msgTip = "user can login"; msgTip = "user can login";
request.getSession().setAttribute("user",user); request.getSession().setAttribute("user",user);
if(("open").equals(mybatisPlusStatus)) {
String url = HTTP + manageIp + ":" + managePort + "/tenant/getTenant?tenantId=" + user.getTenantId(); String url = HTTP + manageIp + ":" + managePort + "/tenant/getTenant?tenantId=" + user.getTenantId();
JSONObject obj = HttpClient.httpGet(url); JSONObject obj = HttpClient.httpGet(url);
if(obj!=null && obj.getString("code").equals(CODE_OK)) { if(obj!=null && obj.getString("code").equals(CODE_OK)) {
...@@ -128,6 +129,7 @@ public class UserController { ...@@ -128,6 +129,7 @@ public class UserController {
} }
} }
} }
}
request.getSession().setAttribute("mybatisPlusStatus",mybatisPlusStatus); //开启状态 request.getSession().setAttribute("mybatisPlusStatus",mybatisPlusStatus); //开启状态
} catch (Exception e) { } catch (Exception e) {
logger.error(">>>>>>>>>>>>>>>查询用户名为:" + username + " ,用户信息异常", e); logger.error(">>>>>>>>>>>>>>>查询用户名为:" + username + " ,用户信息异常", e);
...@@ -180,10 +182,12 @@ public class UserController { ...@@ -180,10 +182,12 @@ public class UserController {
BaseResponseInfo res = new BaseResponseInfo(); BaseResponseInfo res = new BaseResponseInfo();
try { try {
request.getSession().removeAttribute("user"); request.getSession().removeAttribute("user");
request.getSession().removeAttribute("mybatisPlusStatus");
if(("open").equals(mybatisPlusStatus)) {
request.getSession().removeAttribute("tenantId"); request.getSession().removeAttribute("tenantId");
request.getSession().removeAttribute("userNumLimit"); request.getSession().removeAttribute("userNumLimit");
request.getSession().removeAttribute("billsNumLimit"); request.getSession().removeAttribute("billsNumLimit");
request.getSession().removeAttribute("mybatisPlusStatus"); }
response.sendRedirect("/login.html"); response.sendRedirect("/login.html");
} catch(Exception e){ } catch(Exception e){
e.printStackTrace(); e.printStackTrace();
......
Supports Markdown
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