Ejemplo n.º 1
0
 public ActionResult SmileIndex(int page = 1)
 {
     PageInfo pagingInfo = new PageInfo { CurrentPage = page, ItemsPerPage = pageSize, TotalItems = repo.SmileFrownCount() };
     SmileListViewModel model = new SmileListViewModel { Smiles = repo.getAllSmiles(pageSize, (page - 1) * pageSize), PagingInfo = pagingInfo };
     return View(model);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Displays a list of all locations in the system.
 /// </summary>
 /// <param name="page">Page to display. Default is 1.</param>
 /// <returns>View with ViewModel.</returns>
 public ActionResult LocationIndex(int page = 1)
 {
     PageInfo pagingInfo = new PageInfo { CurrentPage = page, ItemsPerPage = pageSize, TotalItems = repo.pointCount() };
     PointListViewModel model = new PointListViewModel { Points = repo.getAllPoints(pageSize, (page - 1) * pageSize), PagingInfo = pagingInfo };
     return View(model);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Displays a list of all of the organizations in the system.
 /// </summary>
 /// <param name="page">Page to display. Default is 1.</param>
 /// <returns>View with ViewModel.</returns>
 public ActionResult OrganizationIndex(int page = 1)
 {
     PageInfo pagingInfo = new PageInfo { CurrentPage = page, ItemsPerPage = pageSize, TotalItems = repo.orgCount() };
     OrgListViewModel model = new OrgListViewModel { Organizations = repo.getAllOrganizations(pageSize, (page - 1) * pageSize), PagingInfo = pagingInfo };
     return View(model);
 }