I successfully filled my combobox. But now I'm trying to set default value for combobox. For example let's say third value from source. This is my input and datasource:
<script>
viewModel.dataSourceType = new kendo.data.DataSource({
transport: {
read: {
url: "/api/Type/Get",
dataType: "json"
}
},
schema: {
id: "Id",
data: "Data",
model: {
id: "Id",
fields: {}
}
}
});
<input id="type"
data-role="combobox"
data-value-primitive="true"
data-auto-bind="true"
data-text-field="Name"
data-value-field="Id"
data-bind="value: model.Id, source: dataSourceType">
It's probably really easy but I'm strugling with that. Thank you.
I assume you look for the index configuration option.