Exemplo n.º 1
0
 public ActionResult <IEnumerable <Task> > EditProject(int id, Project project)
 {
     try
     {
         var projectAdded = _projectRepository.EditProject(id, project);
         return(Ok(project));
     }
     catch (NotFoundException ex)
     {
         return(NotFound(new { message = ex.Message }));
     }
     catch (Exception ex)
     {
         return(BadRequest(new { message = ex.Message }));
     }
 }