//Get public ActionResult GetClients(jQueryDataTableParamModel param) { int totalRecords = 0; var sortColumnIndex = Convert.ToInt32(Request["iSortCol_0"]); var sortDirection = Request["sSortDir_0"]; // asc or desc BLClientSite clientSiteBL = new BLClientSite(); List<tblClientSite> lstCustomerClients = clientSiteBL.GetAllClientSite(SessionHelper.UserSession.CustomerID, param.iDisplayStart, param.iDisplayLength, sortColumnIndex, sortDirection, param.sSearch, ref totalRecords); var result = from c in lstCustomerClients let ServiceTypeName = c.ServiceType.Name let TimeZoneName = c.TimeZone.Name let StatusName = c.Status.Name select new[] { c.BusinessName, ServiceTypeName, TimeZoneName, StatusName, c.ClientID.ToString() }; return Json(new { sEcho = param.sEcho, iTotalRecords = totalRecords, iTotalDisplayRecords = totalRecords, aaData = result }, JsonRequestBehavior.AllowGet); }