Example #1
0
        public async Task <IActionResult> GetMentor(int id)
        {
            var mentor = await _repo.GetMentor(id);

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

            return(Ok(mentorToReturn));
        }
Example #2
0
        public IActionResult GetMentor(string mentormail)
        {
            var mentor = repository.GetMentor(mentormail);

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

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

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

            return(Ok(mentor));
        }
Example #5
0
 public MentorModel GetMentor(int userId)
 {
     return(_repo.GetMentor(userId));
 }