最近刚刚接触MVC不久,因项目中要用到分页,网上找了下资料,最后采用了MvcPager(http://www.webdiyer.com/),支持同步和Ajax异步分页。废话不多说了直接上代码。

一.MvcPager异步

ViewModel:

    public class Article
    {
        [Display(Name = "信息编号")]
        public int ID { get; set; } 

        [Display(Name = "信息标题")]
        public string Title { get; set; }

        [Display(Name = "信息内容")]
        public string Content { get; set; }
    }
View Code

相关文章: