public IActionResult Details(int?id)
 {
     if (!id.HasValue)
     {
         return(RedirectToAction("Index"));
     }
     return(View(_repo.GetMemberById(id.Value)));
 }
        public HttpStatusCode GetMember(int id)
        {
            var member = _repo.GetMemberById(id);

            if (member != null)
            {
                return(HttpStatusCode.OK);
            }
            else
            {
                return(HttpStatusCode.NotFound);
            }
        }
示例#3
0
        public async Task <MembersDTO> GetMemberById(string email)
        {
            var members = await _repo.GetMemberById(email);

            return(_mapper.ToMembersDTO(members));
        }