Browse Source

Merge remote-tracking branch 'origin/4.0' into 4.0

4.0
yaoq 2 years ago
parent
commit
a0c06b128b
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      smtweb-framework/core/src/main/java/cc/smtweb/framework/core/session/SessionUtil.java

+ 4
- 0
smtweb-framework/core/src/main/java/cc/smtweb/framework/core/session/SessionUtil.java View File

@@ -9,6 +9,7 @@ import cc.smtweb.framework.core.exception.BizException;
import cc.smtweb.framework.core.mvc.controller.IEditor; import cc.smtweb.framework.core.mvc.controller.IEditor;
import cc.smtweb.framework.core.mvc.realm.exception.UnauthenticatedException; import cc.smtweb.framework.core.mvc.realm.exception.UnauthenticatedException;
import cc.smtweb.framework.core.util.NumberUtil; import cc.smtweb.framework.core.util.NumberUtil;
import cc.smtweb.framework.core.util.SpringUtil;
import cc.smtweb.framework.core.util.StringUtil; import cc.smtweb.framework.core.util.StringUtil;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.web.context.request.RequestContextHolder; import org.springframework.web.context.request.RequestContextHolder;
@@ -157,6 +158,9 @@ public class SessionUtil {
UserSession us = null; UserSession us = null;
if (StringUtils.isNotBlank(token)) { if (StringUtils.isNotBlank(token)) {
us = RedisManager.getInstance().get(token, UserSession.class); us = RedisManager.getInstance().get(token, UserSession.class);
// token延时
SessionManager sessionManager = SpringUtil.getBean(SessionManager.class);
sessionManager.flush(token);
} }
//校验登录 //校验登录
final boolean isNologin ="design".equals(token) || isNoLogin(lasturi); final boolean isNologin ="design".equals(token) || isNoLogin(lasturi);


Loading…
Cancel
Save