// GET: Topic public ActionResult Index(int?pageSize, int?page) { int rows = pageSize ?? Common.Contant.Configuration.POST_PER_PAGE; int pageNumber = page ?? Common.Contant.Configuration.FIRST_NUMBER; TopicsSearchResult model = _topicService.GetAll(rows, pageNumber); return(View(model)); }
public TopicsSearchResult GetAll(int size, int skip) { TopicsSearchResult res = new TopicsSearchResult() { Topics = _topicRepository.GetAll(size, skip), TotalTopics = _topicRepository.Count() }; return(res); }