I use mvc4/razor,
1)In the below code,where does Data() and Save gets called from? I want to change the name of Data() to someother name, where can I change it?
2) how does Data() hits on loadingthe events?
public ContentResult Data()
{
return (new SchedulerAjaxData(
new CalendarDataContainer().Events.Select(e => new { e.id, e.text, e.start_date, e.end_date })
)
);
}
public ContentResult Save(int? id, FormCollection actionValues)
{
//code
}
Save and Data actions are triggered when client-side sends AJAX requests to urls like “ControllerName/Save” or “ControllerName/Data”(it actually depends on routing settings, but this is default configuration)
Scheduler is configured to call DataAction after initialization (DHXScheduler.LoadData = true; in basic config),
and send changes to the SaveAction (DHXScheduler.EnableDataprocessor = true;)
If you want to change names of this methods, you can do it with following code:DHXScheduler.DataAction = "Data";
DHXScheduler.SaveAction = "Save";