As described in the previous chapter, forms are decoupled from the actual data. To be able to select the form, potentially consisting of subforms, there is the FormAssociation, which defines a set of rules through which the form is assigned to a list, an object, or an extent.

The Models

FormAssociation

In this instance of the form association, the rule set is defined.

Name Meaning

name

Name of the form association

formType

Type of the form that can be assigned. The possible types can be found in the table below.

metaClass

If the selected object or the list behind it is of this object type, this association can be selected.

extentType

If the extent is of this type, this association can be selected.

viewModeId

If the user is in this view, this association can be selected.

parentMetaClass

If elements of a list are selected and the owning object is of this type, this can be selected.

parentProperty

If elements of a list are selected and this list is in this property of the owning object, this can be selected.

form

This describes the form that can be selected if the properties above match, as far as they are chosen.

Form Types

Name Meaning Form

Detail

The form is displayed for the detail view of an item.

DetailForm, ExtentForm

TreeItemExtent

The form is displayed when the user has selected a specific extent and all elements of the extent should be displayed.

ExtentForm

TreeItemDetail

The form is displayed when the user has selected a specific element and this element should now be displayed in the tree view. This type differs from Detail in that the window was not created dedicatedly for the element.

ExtentForm

ObjectList

The form is displayed when all elements of a specific property are to be displayed in a sublist (SubElementField).

ListForm

TreeItemExtentExtension

This form is added to the ExtentForm if the description of the form association matches the displayed form.

Listform, DetailForm

TreeItemDetailExtension

This form is added to the ExtentForm if the description of the form association matches the displayed form.

Listform, DetailForm

Procedure Description

Detail View

In the detail view, the form association is searched for according to the following properties:

datenmeister detailform
Name Meaning

formType

DetailForm

metaClass

The metaclass of the object that has been selected.

extentType

Types (separated by spaces) of the extent in which the displayed object is located.

Extent View

In the extent view, the user can have either the extent itself or an element in the extent selected.

These form types are called TreeItemExtent and TreeItemDetail.

For the representation of the entire extent, the following properties are defined in the form association:

Extent Base Form for the Tree View

Name Meaning

formType

TreeItemExtent

extentType

Types of the extent to be displayed

viewModeId

The view selected by the user

Extent List Form for the Tree View

The ExtentForm consists of several tabs. If a tab is automatically generated, a metaclass can be specified, which then contains the contents.

Name Meaning

formType

TreeItemExtent

extentType

Types of the extent to be displayed

metaClass

Metaclass of the objects to be displayed

Extent Object Form for the Tree View

If the user selects an element in the tree view, the form association is searched for according to the following scheme (FormsPlugin.GetItemTreeFormForObject):

Name Meaning

formType

TreeItemDetail

extentType

Types of the extent to be displayed

metaClass

Metaclass of the object to be displayed

viewModeId

The view selected by the user. If a ViewMode is specified as a property in the package, then

Extent Object List Form for the Tree View

If forms for an object view are generated automatically, depending on the configuration (ConfigurationFormCreatorSeparateProperties), either a ListForm for each type and each property is generated, or a ListForm for each property, which then contains all object types.

The following properties are used here:

Name Meaning

formType

TreeItemDetail

extentType

Types of the extent to be displayed

parentMetaClass

The metaclass of the objects that are selected.

parentProperty

The name of the property of the objects.

Automatic Extension of Forms

After the form has been found, selected, and created, another query round defines whether further forms should be added.

For this purpose, the same form associations as shown above are used, but with a change in the form type:

  1. TreeItemExtent ⇒ TreeItemExtentExtension

  2. TreeItemDetail ⇒ TreeItemDetailExtension

A ListForm should be returned here.