public async Task <IActionResult> Get() { try { var model = await _identity.GetUsersAsync(); if (model.Count() > 0) { return(Ok(model)); } else { return(NotFound()); } } catch (Exception ex) { _logger.Error(ex, HttpContext.Request.Path); return(BadRequest(ex)); } }
public async Task <IActionResult> LoadUserManagementView() { ViewData["Title"] = "UserManagement"; ViewData["users"] = (await _identityRepo.GetUsersAsync()); return(View("UserManagement")); }