public ActionResult PasswordSet() { PasswordSetModel mode = new PasswordSetModel() { UserId = LoginUser.Id }; return(View(mode)); }
public async Task <ActionResult> PasswordSet(PasswordSetModel viewModel) { var result = await UserManager.ChangePasswordAsync(viewModel.UserId, viewModel.Password, viewModel.NewPassword); if (result.Succeeded) { EnsureLoggedOut(); return(View(viewModel)); } AddErrors(result); return(View(viewModel)); }