The DataSource Model including validation should come from the server and not defined within javascript where possible. There should be two primary ways to populate the model using the DataSource widget. 1.) Retrieved from the DataSource call itself as a JSON property off of the data call. You should be able to define a schema: { parseModel: function(data) { return data.model } } to retrieve the model directly from the data call. 2.) You should be able to specify the schema: { model: new DataSource({ ... }) }. The model itself should be DataSourcable so you can retrieve (with ETag/Last-Modified and Cache-Control) the model as a separate request alongside the data. Given that you should be able to retrieve the model as a separate request, you should be given the opportunity to augment/modify the model within the client side using something like schema: { changeModel: function(model) { // Supplement Model here } }
Hi Jeff,
We have a KB article that illustrates how the described behavior can be achieved.
https://docs.telerik.com/kendo-ui/knowledge-base/create-with-dynamic-columns-and-data-types
Regards,
Viktor Tachev
Progress Telerik
Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.