I'm trying to use a combobox editor set in 'multiple' mode inside an editable datagrid. The tutorial lists an example combobox in single-selection mode (
http://www.jeasyui.com/tutorial/datagrid/datagrid12.php). Here is my editor definition for this column:
editor: {
type: 'combobox',
options: {
url: 'GetNames?unitId=23',
multiple: true,
valueField: 'id',
textField: 'name'
}
}
GetNames returns json data like this:
[{"id":301247,"name":"Jane Doe"},{"id":307614,"name":"John Doe"},{"id":169291,"name":"Mr Blah"}]
It is close to working, except for two problems:
1) the combobox editor selects all items in the drop down panel even if my data-providing url returns data with no 'selected' attribute.
2) if the "selected" drop down list entries need to have the entries return with the "selected" attribute true, how does the GetNames backend handler know which row the data is to be retrieved for? Seems like the GetNames URL needs to have an additional parameter indicating the selected entries - but that can be specified at the time of definition for the datagrid.
Any ideas how to get this to work?