public ActionResult ProcessPopupPartial(RequestProcessResultModel model) { if (ModelState.IsValid) { if (model.Result.Equals(VacationStatusTypeEnum.Approved.ToString())) { _requestProcessService.ApproveVacation(Mapper.Map <RequestProcessResultModel, RequestProcessResultDTO>(model)); } else { _requestProcessService.DenyVacation(Mapper.Map <RequestProcessResultModel, RequestProcessResultDTO>(model)); } } _requestProcessService.SetReviewerID(User.Identity.GetUserId()); return(View("Requests", Mapper.MapCollection <RequestDTO, RequestViewModel>(_requestProcessService.GetRequestsForTeamLeader()))); }
public ActionResult ProcessPopupPartial(RequestProcessResultModel model) { _requestProcessService.SetReviewerID(User.Identity.GetUserId()); if (ModelState.IsValid) { if (model.Result.Equals(VacationStatusTypeEnum.Approved.ToString())) { _requestProcessService.ApproveVacation(Mapper.Map <RequestProcessResultModel, RequestProcessResultDTO>(model)); } else { _requestProcessService.DenyVacation(Mapper.Map <RequestProcessResultModel, RequestProcessResultDTO>(model)); } } return(RedirectToAction("Requests")); }