Beispiel #1
0
 public RedirectToRouteResult Activate(ActivateCourseCommand command)
 {
     if (!ModelState.IsValid)
         return this.RedirectToAction(c => c.Activate(command.CourseId));
     _commandService.Execute(command);
     return this.RedirectToAction(c => c.Details(command.CourseId));
 }
 public void WhenIActivateTheCourse()
 {
     var cmd = new ActivateCourseCommand()
                   {
                       CourseId = DomainHelper.GetEventSourceId<Course>()
                   };
     DomainHelper.WhenExecuting(cmd);
 }