/**
  * 查看客户经理评估信息(自己及下属的)
  *
  * @param request
  * @return
  */
 @ResponseBody
 @RequestMapping(
     value = "browse.page",
     method = {RequestMethod.GET})
 @JRadOperation(JRadOperation.BROWSE)
 public AbstractModelAndView displayOrganization(
     @ModelAttribute ManagerAssessmentScoreFilter filter, HttpServletRequest request) {
   filter.setRequest(request);
   List<String> subManagerIds = new ArrayList<String>();
   IUser user = Beans.get(LoginManager.class).getLoggedInUser(request);
   subManagerIds.add(user.getId());
   List<AccountManagerParameterForm> managerParameterForms =
       managerBelongMapService.findSubListManagerByManagerId(user.getId());
   for (AccountManagerParameterForm managerParameterForm : managerParameterForms) {
     subManagerIds.add(managerParameterForm.getUserId());
   }
   filter.setSubManagerIds(subManagerIds);
   QueryResult<TyManagerAssessment> result =
       managerAssessmentScoreService.findManagerAssessmentScoreByFilter(filter);
   JRadPagedQueryResult<TyManagerAssessment> pagedResult =
       new JRadPagedQueryResult<TyManagerAssessment>(filter, result);
   JRadModelAndView mv =
       new JRadModelAndView("/manager/assessmentscore/ty_assessmentscore_record_browse", request);
   mv.addObject(PAGED_RESULT, pagedResult);
   return mv;
 }
  @RequestMapping(value = {"/logout.page"})
  public String logout(HttpServletRequest request) {

    IUser user = loginManager.getLoggedInUser(request);
    String login = user.getLogin();
    String type =
        user.getUserType() == IUser.USER_TYPE_LOCAL ? LoginManager.LOCAL : LoginManager.LDAP;
    String ipAddress = request.getRemoteAddr();
    String signOutMsg = i18nHelper.getMessage("system.auth.success");

    loginManager.logout(request);
    loginLogManager.addSignOutLog(login, type, ipAddress, signOutMsg);

    return "redirect:login.html";
  }
 /**
  * 显示页面
  *
  * @param request
  * @return
  */
 @ResponseBody
 @RequestMapping(value = "display.page")
 @JRadOperation(JRadOperation.DISPLAY)
 public AbstractModelAndView display(HttpServletRequest request) {
   JRadModelAndView mv =
       new JRadModelAndView("/manager/assessmentscore/ty_assessment_change", request);
   String id = RequestHelper.getStringValue(request, ID);
   IUser user = Beans.get(LoginManager.class).getLoggedInUser(request);
   if (StringUtils.isNotEmpty(id)) {
     TyManagerAssessment managerAssessmentScoreForm =
         managerAssessmentScoreService.findManagerAssessmentScoreById(id);
     if (managerAssessmentScoreForm.getCreateUser() == null) {
       managerAssessmentScoreForm.setCreateUser(user.getDisplayName());
     }
     mv.addObject("assessmentScoreForm", managerAssessmentScoreForm);
   }
   return mv;
 }