Maximize productivity with
30% off* for a limited time
using BOOSTDEV30.
Includes 3- and 5-packs.
*Some exclusions may apply.New Product LaunchBoldDesk: Help desk ticketing software starts at $10 for 3 agents.
Try it for free.
public JsonResult LoadData(Params param) // Here we get the Start and End Date and based on that we can filter the data and return to Scheduler
{
DateTime start = DateTime.Parse(param.StartDate);
DateTime end = DateTime.Parse(param.EndDate);
var data = db.ScheduleEventDatas.Where(app => (app.StartTime >= start && app.StartTime <= end) || (app.RecurrenceRule != null && app.RecurrenceRule != "")).ToList(); // Here filtering the events based on the start and end date value.
return Json(data, JsonRequestBehavior.AllowGet);
}
public class Params
{
public string StartDate { get; set; }
public string EndDate { get; set; }
} |