// Get Project Inform list
        public ProjectInformResponse GetPendingProjectInform(ProjectInformRequest request)
        {
            var response = new ProjectInformResponse { ProjectInformList = new List<ProjectInformDto>() };

            // Search pending project informs
            var informsFound = Olympus._Enterprise.ProjectInforms.Where(x => x.UserId == request.EmployeeId &&
                             x.StateId == 1 && x.WasDeleted == false)
                             .OrderByDescending(y => y.DateModified)
                             .Take(Convert.ToInt32(Properties.Resources.MaximunResultRows))
                             .Distinct()
                             .ToList();

            if (informsFound.Count > 0)
            {
                response.ProjectInformList = Mapper.Map<List<ProjectInformDto>>(informsFound);
            }
            return response;
        }
 // Get Pending Projects
 public ProjectInformResponse GetPendingProjectInform(ProjectInformRequest request)
 {
     return _projectInformService.GetPendingProjectInform(request);
 }
Exemple #3
0
 //
 // GET: /Project/
 public ActionResult Index()
 {
     var model = new ProjectInformModel();
     var request = new ProjectInformRequest { EmployeeId = SessionManager.EmployeeId };
     model.PendingProjectInforms = new ProjectInformFactory().GetPendingProjectInform(request).ProjectInformList;
     return View(model);
 }