private ActionResult GetView(SearchClubModel searchClubModel) { var clubs = _clubRepository.GetBy(_sessionSearch.ClubSearchSpec); searchClubModel.Init(clubs, _sessionSearch.ClubSearchSpec); return View(searchClubModel); }
public ActionResult Search(SearchClubModel searchClubModel, int? page) { _sessionSearch.ClubSearchSpec.PageSize = 20; if (Request["page"] != null) _sessionSearch.ClubSearchSpec.CurrentPage = Convert.ToInt32(Request["page"]); return GetView(searchClubModel); }
public ActionResult Search(SearchClubModel searchClubModel) { _sessionSearch.ClubSearchSpec.CurrentPage = 1; _sessionSearch.ClubSearchSpec.Filter.TextSearch.Clear(); if (searchClubModel.SearchTerm != null) _sessionSearch.ClubSearchSpec.Filter.TextSearch.AddTerms(searchClubModel.SearchTerm); return GetView(searchClubModel); }