0
这是我的仓库层:寻呼与PagedList
public List<Section> GetAllSections()
{
return context.Sections.Include("Groups").Include("Groups.Classes").ToList();
}
这是我的应用层:
public List<Section> GetAllSections()
{
return cacheSectionRepo.GetAllSections();
}
而且在控制我有:
SectionApplication sectionApp = new SectionApplication();
public ActionResult Index()
{
return View(sectionApp.GetAllSections());
}
现在,我想使我的Index
查看paged.I想使用PagedList.How应该这样做吗?例如,我想让每个页面显示5条记录。