Пример #1
0
        public async Task <IActionResult> GetMentor(int id)
        {
            var mentor = await _repo.GetMentor(id);

            var mentorToReturn = _mapper.Map <MentorForDetailedDTO>(mentor);

            return(Ok(mentorToReturn));
        }
Пример #2
0
        public IActionResult GetMentor(string mentormail)
        {
            var mentor = repository.GetMentor(mentormail);

            if (mentor == null)
            {
                return(NotFound());
            }
            return(Ok(mentor));
        }
Пример #3
0
        public IActionResult Get(string id)
        {
            var stud = mentorrepository.GetMentor(id);

            if (stud == null)
            {
                return(NotFound());
            }
            return(Ok(stud));
        }
Пример #4
0
        public IActionResult Get(Guid id)
        {
            var mentor = _mentorRepository.GetMentor(id);

            if (mentor == null)
            {
                return(NotFound());
            }

            return(Ok(mentor));
        }
Пример #5
0
 public MentorModel GetMentor(int userId)
 {
     return(_repo.GetMentor(userId));
 }