From f475638fbd92867f567bc429678195bf0d635ba9 Mon Sep 17 00:00:00 2001 From: songwenxuan <1924103812@qq.com> Date: Tue, 14 May 2024 10:54:15 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=89=E7=BA=BF=20session=E6=9C=89=E6=95=88?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E8=AE=BE=E7=BD=AE=E4=B8=BA8=E5=B0=8F?= =?UTF-8?q?=E6=97=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/zcloud/controller/system/MainController.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/zcloud/controller/system/MainController.java b/src/main/java/com/zcloud/controller/system/MainController.java index 1ea3856e..933ba963 100644 --- a/src/main/java/com/zcloud/controller/system/MainController.java +++ b/src/main/java/com/zcloud/controller/system/MainController.java @@ -67,7 +67,9 @@ public class MainController extends BaseController { String errInfo = "success"; Session session = Jurisdiction.getSession(); // 设置session 超时时间2小时 - session.setTimeout(1000 * 60 * 60 * 2); +// session.setTimeout(1000 * 60 * 60 * 2); + // 设置session 超时时间8小时 + session.setTimeout(1000 * 60 * 60 * 8); User user = (User)session.getAttribute(Const.SESSION_USER); //读取session中的用户信息(单独用户信息) if (user != null) { User userr = (User)session.getAttribute(Const.SESSION_USERROL); //读取session中的用户信息(含角色信息)