public ActionResult ContentEditHistory(ContentHistoryModel model) { PagedData<EditHistory> history = model.Page; history.ToggleSort(); var srt = history.ParseSort(); history.TotalRecords = EditHistory.GetHistoryListCount(SiteData.CurrentSiteID, model.GetLatestOnly, model.SearchDate, model.SelectedUserID); if (history.TotalRecords > 0 && (history.PageNumber > history.TotalPages)) { history.PageNumber = history.TotalPages; } history.DataSource = EditHistory.GetHistoryList(history.OrderBy, history.PageNumberZeroIndex, history.PageSize, SiteData.CurrentSiteID, model.GetLatestOnly, model.SearchDate, model.SelectedUserID); ModelState.Clear(); return View(model); }
public ActionResult ContentEditHistory() { ContentHistoryModel model = new ContentHistoryModel(); PagedData<EditHistory> history = new PagedData<EditHistory>(); history.PageSize = 25; history.InitOrderBy(x => x.EditDate, false); model.Page = history; return ContentEditHistory(model); }