I have a MVVM page where upon loading, it make an ajax request to retrieve a model and set the viewmodel to the retrieved model. This model has a few strings and includes a LIST<rates> type. The form is bound to the model and includes input boxes for the strings plus an EDITABLE grid for the List<rates>. My issue is binding the grid to the List<rates> AND allowing it to be editable with a schema. How do I setup the Datasource to point to the List<rates> for the grid, and include a schema to allow for inline editing? I was trying to avoid having a separate remote datasource call since I already have the data from the initial setup.
My model is like this:
var existingtimeKeeperRatesModel = kendo.data.Model.define({
id: "TimeKeeperName",
fields: {
"TimeKeeperName": {
type: "string",
editable: false
},
"StandardRate": {
type: "number",
editable: false
},
"FromRate": {
type: "number",
editable: false
},
"ToRate": {
type: "number",
editable: true
},
"RateTerminateDate": {
type: "date",
editable: true,
parse: function (value) {
return kendo.parseDate(value, "MM-dd-yyyy");
}
}
},
})