I've got a working ListGrid with a GWT-RPC datasource. I can fetch existing data and display it in the ListGrid without any problems. I am using the sample code from the showcase, for databound dependent-selects.
The datasource does have a pkField with the properties set as follows:
pkField = new DataSourceIntegerField("Id", null);
pkField.setPrimaryKey(true);
pkField.setCanEdit(false);
pkField.setRequired(true);
pkField.setRootValue(0);
The code to add a new row is as follows:
I get the dependent-selects opened just fine.
There are 4 columns, the first column (pkField), and the last column are not editable.
So ... after I select an item from the first-selection, it does not go to the next drop-down combo-box.
Instead, the added new record disappears.
If I click on an existing record, this doesn't happen.
Any help would be very much appreciated! Thanks!
The datasource does have a pkField with the properties set as follows:
pkField = new DataSourceIntegerField("Id", null);
pkField.setPrimaryKey(true);
pkField.setCanEdit(false);
pkField.setRequired(true);
pkField.setRootValue(0);
The code to add a new row is as follows:
Code:
addDataButton.addClickHandler(new ClickHandler() { public void onClick(ClickEvent event) { field1.setCanEdit(true); field2.setCanEdit(true); myGrid.startEditingNew(); } });
There are 4 columns, the first column (pkField), and the last column are not editable.
So ... after I select an item from the first-selection, it does not go to the next drop-down combo-box.
Code:
field1.addChangedHandler(new com.smartgwt.client.widgets.grid.events.ChangedHandler() { public void onChanged(com.smartgwt.client.widgets.grid.events.ChangedEvent event) { myGrid.clearEditValue(event.getRowNum(),"dataName"); } });
If I click on an existing record, this doesn't happen.
Any help would be very much appreciated! Thanks!
Comment