Пример #1
0
 public async Task <IActionResult> Post(CompanyAddDTO companyAddDTO)
 {
     try
     {
         if (!ModelState.IsValid)
         {
             return(BadRequest(Messages.InvalidModel));
         }
         return(Ok(await _company.Post(companyAddDTO)));
     }
     catch (Exception ex)
     {
         return(BadRequest(Messages.GeneralError));
     }
 }