@Action( value = REFRESH_USER + "*", results = {@Result(name = SUCCESS, type = REDIRECT_ACTION, location = "{1}")}) public String refreshUser() { super.saveUser(userService.refresh(currentUser())); return SUCCESS; }
private String login(UserStatus status) { super.clearSession(); if ((user = userService.login(user, status)) != null) { // 将相关的用户id存入session super.saveUser(user); super.getSessionMap().put("relativeUsers", talkingService.preGetRelativeUserId(user)); // 将相关的用户id存入session super.getSessionMap().put("relativeUsers", talkingService.preGetRelativeUserId(user)); return SUCCESS; } else { return INPUT; } }
@Action( value = REGISTER_VALIDATE, results = { @Result(name = SUCCESS, type = REDIRECT_ACTION, location = IndexAction.INDEX), @Result( name = INPUT, type = REDIRECT_ACTION, location = MANAGER_LOGIN_INPUT, params = {"msg", "注册验证失败(可能链接已过期)!"}) }) public String registerValidate() { user = mailService.validateRegisterUser(code); if (user != null) { super.saveUser(user); return SUCCESS; } else { return INPUT; } }