コード例 #1
0
        public ActionResult ExportDafDateRange(CC.Web.Models.AgencyReportingDafDateRangeModel model)
        {
            model.iDisplayLength = int.MaxValue;
            var all      = model.GetAgencyReportingData(db, Permissions);
            var filtered = model.ApplyFilter(all);
            var sorted   = model.ApplySort(filtered);

            return(this.Excel("AgencyReportingDafDateRangeReport", "Data", sorted));
        }
コード例 #2
0
        public JsonResult DafDateRangeDataTable(CC.Web.Models.AgencyReportingDafDateRangeModel model)
        {
            var all      = model.GetAgencyReportingData(db, Permissions);
            var filtered = model.ApplyFilter(all);
            var sorted   = model.ApplySort(filtered);
            var data     = new CC.Web.Models.jQueryDataTableResult()
            {
                sEcho = model.sEcho,
                iTotalDisplayRecords = filtered.Count(),
                iTotalRecords        = all.Count(),
                aaData = sorted.Skip(model.iDisplayStart).Take(model.iDisplayLength)
            };

            return(MyJsonResult(data));
        }