Hello Telerik Team !
I'm using telerik gantt chart for MVC
i want to ask can i manipulate tasks data before it get's bind to the chart ?
like when READ action for task data source gets fired and get the data from server and then at client side before binding tasks to chart it can be changed.
can i do that ? kindly tell.
5 Answers, 1 is accepted
Yes you can manipulate the data recived from the remote by specifying a schema.parse function for the Gantt DataSource. Note, that in order to be able to configure the Parse() function, you will have to use a Custom DataSource for the Gantt HTML helper:
Note, that all fields should be properly described in the Model section. Further information on that topic could be found in our Documentation.
can same thing happen in Resources ? i mean before opening the resources dialog box i can make change in datasource then let it append in dialogbox?
Yes, the same could be applied to for the Gantt Resources datasource too:
hey . i was trying to get the assignments for the particular task in OnEdit event and in OnSave event. i was able to get only the resources but not the assignments for that task ?
i mean if i have one assigned resource coming from database and that is checked in resources dialog box. if I check one more resource and hit have button of task dialog box in OnSave event i'm getting the resource only which was coming from database. not the new one which i checked and hit save button. how can i get the new assigned resources ? i have not seen any Assignment property in my selected task as well.
The newly added assignments will be present in the values field of the evenArgs object of the save event handler of the widget: