I have a data source with a lot of fields and an editing screen that breaks it up into multiple forms on different tabs. All forms use the same DataSource and ValuesManager. When I create each form I use ValuesManager.addMember(myForm) to associate them all with the same manager.
I have setSaveOnEnter(true) on all of the forms and have overridden DynamicForm.submit() on each form where I call a method that calls saveData() on the ValuesManager. I also have a "Save" button on the layout that calls saveData().
Also on the layout is a ListGrid tied to the same datasource. When a user clicks on a record in the grid I use ValuesManager.editRecord(event.getRecord()); The values from the selected record appear in all of the various forms tied to the ValuesManager.
The first of the various forms has a couple of fields that are required="true". If I click the Save button all is well, But if I press Enter in any forms I get this error.
Both of those fields do have data in them from the selected record. Although it is a WARN message my save method is not being called. So nothing appears to happen from the end user point of view.
Here is the method I call to create each of the forms, after which I then populate them with the fields for the particular form.
I have setSaveOnEnter(true) on all of the forms and have overridden DynamicForm.submit() on each form where I call a method that calls saveData() on the ValuesManager. I also have a "Save" button on the layout that calls saveData().
Also on the layout is a ListGrid tied to the same datasource. When a user clicks on a record in the grid I use ValuesManager.editRecord(event.getRecord()); The values from the selected record appear in all of the various forms tied to the ValuesManager.
The first of the various forms has a couple of fields that are required="true". If I click the Save button all is well, But if I press Enter in any forms I get this error.
Code:
17:24:02.111 [ERROR] [ipgui] 17:24:02.099:XRP1:WARN:validation:isc_VendorMaintenance$11_1:Validation errors occurred for the following fields with no visible form items: VVEN:- Field is required VNAM:- Field is required
Here is the method I call to create each of the forms, after which I then populate them with the fields for the particular form.
Code:
private DynamicForm getStandardForm() { DynamicForm stdForm = new DynamicForm() { @Override public void saveData() { saveVendor(); } }; stdForm.setDataSource(ipMrven); vm.addMember(stdForm); stdForm.setWrapItemTitles(false); stdForm.setSaveOnEnter(true); return stdForm; }
Comment