public ActionResult AddSessionDelegate(AddDelegateCommand command) { var errors = addValidator.GetErrorList(command); if (errors.Any()) { //diplay errors to the user return(View(errors)); } addHandler.Handle(command); return(RedirectToAction("Index", "SessionDelegate")); }
public ActionResult CancelSessionDelegateFromSession(UpdateDelegateCommand command) { var errors = updateValidator.GetErrorList(command); if (errors.Any()) { //diplay errors to the user return(View(errors)); } updateHandler.Handle(command); return(RedirectToAction("Index", "Session")); }