Skip to content

Instantly share code, notes, and snippets.

@toddpi314
Created July 29, 2012 23:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toddpi314/3202519 to your computer and use it in GitHub Desktop.
Save toddpi314/3202519 to your computer and use it in GitHub Desktop.
CoreViewModel
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Mvc;
using LightningMVC.Views;
namespace Views
{
public abstract class CoreViewModel
{
public ActionResult ActionResult { get; set; }
public String Error { get; set; }
public IViewController ViewController { get; set; }
public bool IsAjaxRequest { get; set; }
protected void NavigateToView(string controller, string view, object args = null)
{
this.ActionResult = ViewController.NavigateToView(controller, view, args);
}
public virtual void OnDataSet()
{
}
public virtual void OnValidated()
{
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment