Esempio n. 1
0
        public UsersEducationViewModel GetEducationByID(int EducationID)
        {
            UsersEducationViewModel education = new UsersEducationViewModel();

            try
            {
                education = _context.usp_UsersEducation_GetByID(EducationID)
                            .Select(x => new UsersEducationViewModel
                {
                    Id = x.Id,
                    CourseSpecialization = x.CourseSpecialization,
                    Institute            = x.Institute,
                    GPA         = x.GPA,
                    StartPeriod = x.StartPeriod,
                    EndPeriod   = x.EndPeriod,
                    Comments    = x.Comments,
                    IsActive    = x.IsActive,
                    UserID      = x.UserID,
                    CreatedBy   = x.CreatedBy,
                    UpdatedBy   = x.UpdatedBy,
                    CreatedDate = x.CreatedDate,
                    UpdatedDate = x.UpdatedDate
                }).FirstOrDefault();
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return(education);
        }