public ViewResult Menu() { TeamViewListModel model = new TeamViewListModel { Teams = repository.Teams .OrderBy(p => p.TeamID) }; return(View(model)); }
public ViewResult List(int page = 1) { TeamViewListModel model = new TeamViewListModel { Teams = repository.Teams .OrderBy(p => p.TeamID) .Skip((page - 1) * size) .Take(size), PagingInfo = new PagingInfo { CurrentPage = page, ClubsPerPage = size, TotalClubs = repository.Teams.Count() } }; return(View(model)); }