public ActionResult <Contractor> GetById(int id)
 {
     try
     {
         return(Ok(_service.GetById(id)));
     }
     catch (Exception e)
     {
         return(BadRequest(e.Message));
     }
 }
예제 #2
0
 public ActionResult <Contractor> GetById(int id)
 {
     try
     {
         return(Ok(_contractorsService.GetById(id)));
     }
     catch (System.Exception err)
     {
         return(BadRequest(err.Message));
     }
 }