I am tring to synco a streets combo which is cascaded with a citys combo with it's value in the model.
I am tring to use the fallowing js lines:
var combobox = $("#MyStreetsCombo").data("kendoComboBox);
var dataItem = combox.dataSource.get(combobox.value());
combo.select(dataItem);
var dataItem is always undefined.
I have seen this post http://www.kendoui.com/forums/ui/dropdownlist/why-doesn-t-mydropdowncontrolid-data-kendodropdownlist-datasource-get-1-work.aspx
but I do not understand how to pass the jsonobject DataSourceSchema to set the id of the model in the rasor syntax.
@(Html.Kendo().ComboBox()
.Name("StreetsCombo")
.DataTextField("Text")
.DataValueField("Value")
.DataSource(source => {
source.Read(read =>
{
readAction("Action" , "Controller")
.Data("filterFunction");
})
.ServerFiltering(true)
.DataSourceSchema( new {model ..... id = 'Value'}).???;
)
Ariel
I am tring to use the fallowing js lines:
var combobox = $("#MyStreetsCombo").data("kendoComboBox);
var dataItem = combox.dataSource.get(combobox.value());
combo.select(dataItem);
var dataItem is always undefined.
I have seen this post http://www.kendoui.com/forums/ui/dropdownlist/why-doesn-t-mydropdowncontrolid-data-kendodropdownlist-datasource-get-1-work.aspx
but I do not understand how to pass the jsonobject DataSourceSchema to set the id of the model in the rasor syntax.
@(Html.Kendo().ComboBox()
.Name("StreetsCombo")
.DataTextField("Text")
.DataValueField("Value")
.DataSource(source => {
source.Read(read =>
{
readAction("Action" , "Controller")
.Data("filterFunction");
})
.ServerFiltering(true)
.DataSourceSchema( new {model ..... id = 'Value'}).???;
)
Ariel