// GET: /<controller>/ public IActionResult Index() { var logins = _pr.GetPortalLogins(new PortalLoginQuery() { }); return(View("Index", logins)); }
public IActionResult Index() { //Get all users var users = _pr.GetPortalLogins(new PortalLoginQuery() { IsValid = null }); if (users.Total == 0) { ViewBag.IsCreated = false; return(View(new LoginViewModel())); } else { return(RedirectToAction("Login")); } }