Search in sources :

Example 11 with FormModel

use of org.kie.workbench.common.forms.model.FormModel in project kie-wb-common by kiegroup.

the class AbstractFormAdapter method migrate.

protected void migrate(FormMigrationSummary formSummary) {
    info("Starting migration for Form [" + formSummary.getOriginalForm().getPath().getFileName() + "]");
    FormModel formModel = extractFormModel(formSummary);
    if (formModel == null) {
        fail(formSummary, "Impossible to identify a valid Model for new form. This might mean that the form " + "has a reference to a missing Data Object or an unexisting BPM Process / Task");
        return;
    }
    doCreateFormDefinition(formModel, formSummary);
    info("Form succesfully migrated");
}
Also used : DataObjectFormModel(org.kie.workbench.common.forms.data.modeller.model.DataObjectFormModel) FormModel(org.kie.workbench.common.forms.model.FormModel)

Aggregations

FormModel (org.kie.workbench.common.forms.model.FormModel)11 FormDefinition (org.kie.workbench.common.forms.model.FormDefinition)5 ArrayList (java.util.ArrayList)2 List (java.util.List)2 Test (org.junit.Test)2 DataObjectFormModel (org.kie.workbench.common.forms.data.modeller.model.DataObjectFormModel)2 FormModelSynchronizationResult (org.kie.workbench.common.forms.editor.model.FormModelSynchronizationResult)2 FormModelHandler (org.kie.workbench.common.forms.editor.service.backend.FormModelHandler)2 ModelProperty (org.kie.workbench.common.forms.model.ModelProperty)2 Path (org.uberfire.backend.vfs.Path)2 FileAlreadyExistsException (org.uberfire.java.nio.file.FileAlreadyExistsException)2 File (java.io.File)1 HashMap (java.util.HashMap)1 Optional (java.util.Optional)1 Set (java.util.Set)1 Predicate (java.util.function.Predicate)1 Collectors (java.util.stream.Collectors)1 DataBindingEditor (org.kie.workbench.common.forms.editor.client.editor.properties.binding.DataBindingEditor)1 DynamicFormModel (org.kie.workbench.common.forms.editor.client.editor.properties.binding.DynamicFormModel)1 StaticFormModel (org.kie.workbench.common.forms.editor.client.editor.properties.binding.StaticFormModel)1