enhancement
We need the Create dialog to remain open after an object is created, for parts of the form to be reset, and for the user to be able to create multiple objects in quick succession.
Workaround
Override (without calling `super`):
protected void afterCommit(LayoutComponent component, Object newObject) {
deleteFormContext(component);
}
If you have post-create actions, you must either implement them in this method (setSelected(...) etc.) or define a variable
_postCreateActions = TypedConfiguration.getInstanceList(context, config.getPostCreateActions());
and additionally in `afterCommit()`:
WithPostCreateActions.processCreateActions(_postCreateActions, component, newObject);
.
Test
- /com.top_logic.demo/src/test/java/test/com/top_logic/demo/scripted/layout/create/TestMultiCreateWithoutClosingDialog.script.xml