@Override public List<Project> getProjectList(User user, int curPageNum, int pageSize) { List<Project> projectList = projectDao.getProjectList(user, curPageNum, pageSize); for (Project p : projectList) { if (user.isUserInRole("admin") || p.getUser().getId() == user.getId()) p.setIsManagable(true); } return projectList; }
@Override public List<Project> getProjectList() { return projectDao.getProjectList(); }