public override void OnActionExecuting(ActionExecutingContext filterContext)
        {
            var modelType = filterContext.ActionParameters["model"].GetType();
            var model = ServiceLocator.Current.GetInstance(modelType);

            filterContext.SetParameter("model", model);        
        }
 public override void OnActionExecuting(ActionExecutingContext filterContext)
 {
     var step = _process.CurrentStep.Name;
     if (!_process.IsReadyFor(step))
     {
         filterContext.Result = RedirectTo(_process.CurrentStep);
         filterContext.Result.ExecuteResult(filterContext);
         filterContext.HttpContext.Response.End();
     }
     filterContext.SetParameter("step", _process.CurrentStep);        
 }
 private void SetModelParameter(ActionExecutingContext filterContext)
 {
     filterContext.SetParameter("model", GetModel(filterContext));
 }