I have a dynamically filled DropDown list which is initialized after grid cell click.
Problem is, that after select any value is always displayed in datagrid only ID of selected number but not text value.
See image>
After select the value
I need to store selected id of item for update request (this works fine) and in datagrid set selected text value.
How can i do it?
Here is the code:
// COLUMNS
{
field :"worker",
title : "Worker",
// bind function for populate custom dropdown list
editor: orderWorkerDropDownEditor,
template: "#=worker#",
width:150
},
// DROPDOWN
$('<input data-bind="value:' + options.field + '"/>')
.appendTo(container)
.kendoDropDownList({
animation: false,
autoBind: true,
dataTextField: "wname",
dataValueField: "wid",
dataSource: [
{ wid: 1, wname: "Worker" },
{ wid: 2, wname: "Manager" },
{ wid: 3, wname: "Admin" }
]
});
Thanks for any help.