public ActionResult OneAccount(string id) { if (String.IsNullOrWhiteSpace(id)) { return View("index", new StatByAccountViewModel()); } IPQueryModel model = new IPQueryModel(); model.SelectedUserID = id; model.QueryData(); model.CountTotalRows(); return View(model); }
public ActionResult PagingAction(IPQueryModel model) { try { string pageIndex = Request.Form["txtPageNaviNo"]; if (!string.IsNullOrWhiteSpace(pageIndex)) { model.PageIndex = int.Parse(pageIndex); } else { model.PageIndex = 0; } model.SelectedUserID = Request.Form["hidUserID"]; model.QueryData(); return View(model); } catch (Exception ex) { ModelState.AddModelError("", ex.Message); return View(); } }
protected ViewResult RefreshData(bool needReFetchRecordCount, IPQueryModel model) { if (needReFetchRecordCount) { model.CountTotalRows(); ModelState.Remove("TotalRows"); } model.QueryData(); return View(model); }