public ActionResult GetProjects(ProjectSearchDTO req) { int total = 0; var list = ProjectRepository.GetList(out total, req); return(Json(new { rows = list, total = total }, JsonRequestBehavior.AllowGet)); }
public ActionResult GetProjects(ProjectSearchDTO req) { if (req.ListType == 1) { req.offset = (req.offset - 1) * req.limit; } int total = 0; var list = _projectRepository.GetList(out total, req); return(Json(new { rows = list, total = total, code = 0, msg = "" }, JsonRequestBehavior.AllowGet)); }