现在我有一个这样的登录代码,UserInfo 是一个带有用户名和密码的表单
@RequestMapping(value = "/login/loginCheck", method = RequestMethod.POST)
public Map<String, Object> loginCheck(UserInfo userInfo)
@RequestMapping(value = "/login/PageA", method = RequestMethod.POST)
public Map<String, Object> PageA(){
//maybe check the session
//if session expired ,then redirect to login page
}
登录后,我应该将页面重定向到页面A,并在会话中记录用户名,那么在spring框架中,我只是配置它还是从请求中获取会话?
希望清楚。