Beispiel #1
0
        public IList <UsersExperienceViewModel> GetExperienceByUserID(Guid UserID)
        {
            IList <UsersExperienceViewModel> experiences = new List <UsersExperienceViewModel>();

            try
            {
                experiences = _context.usp_UsersExperience_GetByUserID(UserID)
                              .Select(x => new UsersExperienceViewModel
                {
                    Id          = x.Id,
                    Company     = x.Company,
                    WorkTitle   = x.WorkTitle,
                    FromDate    = x.FromDate,
                    ToDate      = x.ToDate,
                    Comments    = x.Comments,
                    IsActive    = x.IsActive,
                    UserID      = x.UserID,
                    CreatedBy   = x.CreatedBy,
                    UpdatedBy   = x.UpdatedBy,
                    CreatedDate = x.CreatedDate,
                    UpdatedDate = x.UpdatedDate
                }).ToList();
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return(experiences);
        }