Ejemplo n.º 1
0
 public async Task <ActionResult <Invoices> > GetInvoices()
 {
     try
     {
         return(Ok(await invoicesRepository.GetAllInvoices()));
     }
     catch (Exception)
     {
         return(StatusCode(StatusCodes.Status500InternalServerError, "Error retrieving data from database"));
     }
 }