Beispiel #1
0
 public async Task <HttpResponseMessage> Listar()
 {
     try
     {
         var response = _serviceUsuario.Listar();
         return(await ResponseAsync(response, _serviceUsuario));
     }
     catch (Exception ex)
     {
         return(await ResponseExceptionAsync(ex));
     }
 }
Beispiel #2
0
        public async Task <IActionResult> Listar()
        {
            try
            {
                AtualizarUsuarioLogado();

                return(await ResponseAsync(_serviceUsuario.Listar(), _serviceUsuario));
            }
            catch (Exception e)
            {
                return(await ResponseExceptionAsync(e));
            }
        }
Beispiel #3
0
 public Task <HttpResponseMessage> Listar()
 {
     return(CreateResponse(HttpStatusCode.OK, _serviceUsuario.Listar(), _serviceUsuario.GetNotifications()));
 }