Hi,
in my viewmodel i have defined a datasource with type: "odata".
The datasource is bound to a listview like this:
The used template is a combination of parts defined in html and code. - including some if-statements.
Inside the template i have this textbox:
This should make it possible for the user to change the "someIntValue" directly from the list.
In another function i want to foreach all the bound items and submit the new "someIntValue" values to the server,
but every time i try that the values are still the original ones.
Any ideas what i'm missing to make this work?
Here is the model i defined in the schema of the datasource:
in my viewmodel i have defined a datasource with type: "odata".
The datasource is bound to a listview like this:
var template = kendo.template($("#Template_Pre").html()
+ viewModel.templates["someKey"].Item
+ $("#Template_Sub").html());
$("#mylist").kendoMobileListView({
dataSource: viewModel.listDataSource,
template: template,
appendOnRefresh: false,
pullToRefresh: true,
scrollThreshold: 30
});
Inside the template i have this textbox:
<
input
data-role
=
"numerictextbox"
data-bind
=
"value: someIntValue"
/>
This should make it possible for the user to change the "someIntValue" directly from the list.
In another function i want to foreach all the bound items and submit the new "someIntValue" values to the server,
but every time i try that the values are still the original ones.
Any ideas what i'm missing to make this work?
Here is the model i defined in the schema of the datasource:
model: {
id: "myId",
fields: {
myId: { editable: false, type: "number" },
someStringValue: { editable: false, type: "string" },
someIntValue: { editable: true, type: "number", validation: { min: 0 } }
}
}