Exemplo n.º 1
0
 public ActionResult <UserGroup> GetUserGroup(Guid ID)
 {
     try
     {
         var rs = _userGroupService.GetByID(ID);
         if (rs == null)
         {
             return(NotFound("ID not found"));
         }
         UserGroupVM result = _mapper.Map <UserGroupVM>(rs);
         return(Ok(result));
     }
     catch (Exception e)
     {
         return(BadRequest(e.Message));
     }
 }