getData()

"By default, JS2 Scheduler support load on demand concept where post is raised for each navigation and CRUD actions with start and end date of current view as parameters. "

This was stated in this post:

https://www.syncfusion.com/forums/143992/dynamically-load-data-into-the-schedule-control-when-month-changes

However, the crud actions are noted to pass many more parameters (EditParams) as seen in the below link.

"Definition for the controller method GetData can be referred here."

https://ej2.syncfusion.com/documentation/schedule/data-binding/#scheduler-crud-actions


let dataManager: DataManager = new DataManager({
   url: 'Home/GetData', // 'controller/actions'
   crudUrl: 'Home/UpdateData',
   adaptor: new UrlAdaptor
   });


Is there any documentation regarding what actually occurs and when it occurs when assigning url and crudURL?

Please help. Thanks.



2 Replies

VI Vincent September 11, 2022 02:09 PM UTC

I was able to verify in stackblitz that the control appends a query string onto url: mysite.com with StartDate and EndDate as the parameters.


I also noticed that the Requests are cached despite setting: DataManager.datasource.eneablecaching=false.


I am wondering if I am not looking in the right place to see where this is documented.


 

requestsArray[1]

    1. 0: e


RV Ravikumar Venkatesan Syncfusion Team September 13, 2022 07:39 AM UTC

Hi Vincent,


Greetings from Syncfusion support.


Sample: https://stackblitz.com/edit/ej2-ts-schedule-url-adaptor-sample?file=index.ts

Url Adaptor service: https://www.syncfusion.com/downloads/support/directtrac/general/ze/ej2-ts-schedule-url-adaptor-service-1888702072


When a Schedule requests data from the server the Start and End dates of the selected date range will be sent to the server. Also, you can send the custom parameters to the server end using the query property of the Schedule eventSettings. You can find the details in the below UG section.


https://ej2.syncfusion.com/documentation/schedule/data-binding/#passing-additional-parameters-to-the-server


When a CRUD action is performed with the appointment the Schedule will send the respective appointment details like the (EditParams)model shown below. So, you Add, Edit, or Delete an appointment at the server end based on the details. Kindly refer to the below UG to perform CRUD actions with the Schedule.


Note: The EditParams value will change based on the action performed with the Schedule and the below UG section explains how to handle those actions at the server end.


https://ej2.syncfusion.com/documentation/schedule/data-binding/#scheduler-crud-actions



The url property value assigned to the dataManager will load the data from the server. If you want to perform CRUD actions with the Schedule you need to provide the crudUrl property of the dataManager. So, that server method will be invoked on each Schedule CRUD action and the appointment data will be updated at the server end.



Kindly try the shared sample and let us know if you need any further assistance on this.


Regards,

Ravikumar Venkatesan


Loader.
Up arrow icon