Search in sources :

Example 1 with HiddenComponentPattern

use of com.qcadoo.view.internal.components.HiddenComponentPattern in project qcadoo by qcadoo.

the class FormComponentPattern method getVersionField.

private FieldComponentPattern getVersionField(ComponentPattern parent) {
    ComponentDefinition componentDefinition = new ComponentDefinition();
    componentDefinition.setName(VersionableConstants.VERSION_FIELD_NAME);
    componentDefinition.setFieldPath("#{" + getReference() + "}." + VersionableConstants.VERSION_FIELD_NAME);
    componentDefinition.setSourceFieldPath(null);
    componentDefinition.setTranslationService(getTranslationService());
    componentDefinition.setApplicationContext(getApplicationContext());
    componentDefinition.setViewDefinition(getViewDefinition());
    componentDefinition.setParent(parent);
    componentDefinition.setContextualHelpService(getContextualHelpService());
    componentDefinition.setExtensionPluginIdentifier(getExtensionPluginIdentifier());
    FieldComponentPattern versionField = new HiddenComponentPattern(componentDefinition);
    versionField.setPersistent(true);
    return versionField;
}
Also used : FieldComponentPattern(com.qcadoo.view.internal.components.FieldComponentPattern) HiddenComponentPattern(com.qcadoo.view.internal.components.HiddenComponentPattern) ComponentDefinition(com.qcadoo.view.internal.ComponentDefinition)

Aggregations

ComponentDefinition (com.qcadoo.view.internal.ComponentDefinition)1 FieldComponentPattern (com.qcadoo.view.internal.components.FieldComponentPattern)1 HiddenComponentPattern (com.qcadoo.view.internal.components.HiddenComponentPattern)1