public async Task <JsonResult> Login(LoginRequest form) { await AuthorizeManagement.SignOutAsync(); if (form.LoginId != "test" || form.Password != "1234") { return(Json(new { result = false })); } await AuthorizeManagement.SignInAsync(form.LoginId); return(Json(new { result = true })); }
public async Task <IActionResult> LogOut() { await AuthorizeManagement.SignOutAsync(); return(RedirectToAction("Index")); }