public ActionResult ForgotPassword(ForgotPasswordInput forgotPasswordInput) { if (ModelState.IsValid) { var message = new ForgotPasswordInputMessage {Input = forgotPasswordInput, Result = new ForgotPasswordResult()}; Bus.Send(message); if (message.Result.Success) { return View("forgotpasswordsent", (object) message.Result.Message); } ModelState.AddModelError("model", message.Result.Message); } return View(forgotPasswordInput); }
public ActionResult ForgotPassword(ForgotPasswordInput forgotPasswordInput) { if (ModelState.IsValid) { var message = new ForgotPasswordInputMessage { Input = forgotPasswordInput, Result = new ForgotPasswordResult() }; Bus.Send(message); if (message.Result.Success) { return(View("forgotpasswordsent", (object)message.Result.Message)); } ModelState.AddModelError("model", message.Result.Message); } return(View(forgotPasswordInput)); }