Hello all,
I have a problem with a Combogrid.
The data for this combogrid is obtained remotely, and the grid object is also using 'view:scrollview' because initially the data can be very large; possibly many 1000's of rows.
When my form loads, the Combogrid is bound to my ID field, in this case 'ModelID'.
This might load with a value such as 123.
The Combogrid is set up with:
$('#myform input.ModelID').combogrid({
idField: 'ID', textField: 'Name',
mode: 'remote',
loadMsg: 'Querying Database...',
panelWidth: '380',
multiSort: true,
singleSelect: true,
pageSize: 50,
view: scrollview,
remoteSort: true,
remoteFilter: true
... so when the form loads and the combogrid is initialised, the ID=123 should translate to Name='BlueModel' and the Value should then display in the textbox of the combogrid.
If the ID entry is in the first page of the combogrid data, all is well, the value is displayed.
The problem is that if the ID entry is NOT on the first page (i.e. the entry will not be in the combogrid's data property until the user scrolls down) then the Value is not displayed, the ID is shown instead. If the user does scroll down until the page of the entry, it is then translated.
When my form loads, I actually have another field 'Model' which already contains the translated value 'BlueModel', but I can't find a property or method for combogrid that will allow me to set the initial text value rather than attempt a lookup against the data property.
Can anyone help with either a way to ensure that the current ID value is looked up, or some way to initialise the combogrid textbox? Is trying to combine combogrid and scrollview a bad idea? (I also have datagrid-filter on this datagrid too, but that's another story!)
Many Thanks.
PS I really like EasyUI, it seems to do everything - that is until I make things too complicated!