Example #1
0
        private IEnumerable <ProjectTeamMemberViewModel> GetUsersWithFTE()
        {
            var activeUsers = _userQueryService.GetAllActiveUsers();

            return(activeUsers.Select(x => new ProjectTeamMemberViewModel
            {
                FirstName = x.FirstName,
                LastName = x.LastName,
                UserId = x.UserId,
                TeamMemberActivities = _userQueryService.GetUserActivities(new UserId(x.UserId))
                                       .Select(s => new ProjectTeamMemberActivityViewModel
                {
                    RoleId = s.RoleId,
                    FTE = s.FTE,
                    EndDate = s.EndDate,
                    StartDate = s.StartDate,
                    UserId = s.UserId
                })
            }));
        }