Skip to content

Presentation

This section describes the user interface–related configuration options available for the Entry classes — CreateEntry, UpdateEntry, DeleteEntry, and DisplayEntry.

These options allow consumers to control various aspects of the generated UI, including rendering order, visibilities for properties of Edm.Guid type.

Some configuration options may not be applicable to all Entry classes. Such limitations are clearly mentioned in the description of each feature.

Configurations can be applied in two ways:

  • In the constructor of the Entry class.
  • Via getter/setter methods through an instance of an Entry class.

Note

All examples in this section use the CreateEntry class for demonstration purposes. The same configuration applies to other Entry classes as long as the specific feature is supported.


Key Enforcement (keyEnforcementEnabled)

boolean

true

When keyEnforcementEnabled is set to true (default), all key properties defined in the OData metadata are:

  1. Always included in the generated form.
  2. Automatically positioned at the top of the form.

This ensures that essential identifying fields are always visible and prioritized for the end user.
If you want to exclude key properties or change their position, you must explicitly set this flag to false.

Entry Class Availability

Entry Class Available
CreateEntry ✅ Yes
UpdateEntry ✅ Yes
DeleteEntry ✅ Yes
DisplayEntry ✅ Yes

Implementation Mode Availability

Mode Available
Dialog Mode ✅ Yes
Component Mode ✅ Yes

Method Returns Description
getKeyEnforcementEnabled() boolean Returns whether key enforcement is enabled. Defaults to true.

Method Parameter Type Mandatory Description
setKeyEnforcementEnabled(newValue) newValue boolean ✅ Yes Enables or disables the enforcement of key properties in the generated form.

Example

Main.controller.ts
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
import Controller from "sap/ui/core/mvc/Controller";
import CreateEntry from "ui5/antares/pro/v2/entry/CreateEntry"; // Import the class

/**
 * @namespace your.apps.namespace
 */
export default class Main extends Controller {
    public onInit() {

    }

    public async onCreateProduct() {
        const entry = new CreateEntry({
            controller: this, 
            entitySet: "Products",
            keyEnforcementEnabled: false // Allow excluding or reordering key properties
        });
    }
}
Main.controller.js
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
sap.ui.define([
    "sap/ui/core/mvc/Controller",
    "ui5/antares/pro/v2/entry/CreateEntry" // Import the class
], (Controller, CreateEntry) => {
    "use strict";

    return Controller.extend("your.apps.namespace.Main", {
        onInit: function () {

        },

        onCreateProduct: async function () {
            const entry = new CreateEntry({
                controller: this, 
                entitySet: "Products",
                keyEnforcementEnabled: false // Allow excluding or reordering key properties
            });
        }
    });
});

Property Order (propertyOrder)

string[]

By default, property controls (e.g., Input, DatePicker) are rendered in the order they appear in the OData metadata.
The propertyOrder feature allows you to define a custom display sequence by listing property names in the desired order.

The first property in the array will be rendered first in the form, followed by the next, and so on.

Note

If keyEnforcementEnabled is set to true, key properties are always displayed first, regardless of their position in this array.

Entry Class Availability

Entry Class Available
CreateEntry ✅ Yes
UpdateEntry ✅ Yes
DeleteEntry ✅ Yes
DisplayEntry ✅ Yes

Implementation Mode Availability

Mode Available
Dialog Mode ✅ Yes
Component Mode ✅ Yes

Method Returns Description
getPropertyOrder() string[] Returns the current property order. If not explicitly set, returns an empty array.

Method Parameter Type Mandatory Description
setPropertyOrder(newValue) newValue string[] ✅ Yes Sets a custom property order for rendering fields in the generated form.

Example

Main.controller.ts
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import Controller from "sap/ui/core/mvc/Controller";
import CreateEntry from "ui5/antares/pro/v2/entry/CreateEntry"; // Import the class

/**
 * @namespace your.apps.namespace
 */
export default class Main extends Controller {
    public onInit() {

    }

    public async onCreateProduct() {
        const entry = new CreateEntry({
            controller: this, 
            entitySet: "Products",
            propertyOrder: [
                "ProductID",   // First field
                "ProductName", // Second field
                "Category"     // Third field
            ]
        });
    }
}
Main.controller.js
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
sap.ui.define([
    "sap/ui/core/mvc/Controller",
    "ui5/antares/pro/v2/entry/CreateEntry" // Import the class
], (Controller, CreateEntry) => {
    "use strict";

    return Controller.extend("your.apps.namespace.Main", {
        onInit: function () {

        },

        onCreateProduct: async function () {
            const entry = new CreateEntry({
                controller: this, 
                entitySet: "Products",
                propertyOrder: [
                    "ProductID",   // First field
                    "ProductName", // Second field
                    "Category"     // Third field
                ]
            });
        }
    });
});

Guid Visibility Mode (guidVisibilityMode)

GuidMode

NonKey

Controls the visibility of properties with Edm.Guid type in the generated form.

Supported modes:

  • All – Displays all Edm.Guid properties.
  • Key – Displays only key Edm.Guid properties.
  • NonKey – Displays only non-key Edm.Guid properties.
  • None – Hides all Edm.Guid properties.

Note

If keyEnforcementEnabled is set to true, all key properties (including Edm.Guid) are always displayed first in the form, even if guidVisibilityMode is set to hide them.

Entry Class Availability

Entry Class Available
CreateEntry ✅ Yes
UpdateEntry ✅ Yes
DeleteEntry ✅ Yes
DisplayEntry ✅ Yes

Implementation Mode Availability

Mode Available
Dialog Mode ✅ Yes
Component Mode ✅ Yes

Method Returns Description
getGuidVisibilityMode() GuidMode Returns the current visibility mode for Edm.Guid properties.

Method Parameter Type Mandatory Description
setGuidVisibilityMode(newValue) newValue GuidMode ✅ Yes Sets the visibility mode for Edm.Guid properties.

GuidMode Values

Value Description
All Show all properties with type Edm.Guid, regardless of whether they are key or non-key fields.
Key Show only those Edm.Guid properties that are keys in the entity.
NonKey Show only Edm.Guid properties that are not keys (e.g., foreign keys, reference IDs).
None Hide all Edm.Guid properties from the generated form.

Example

Main.controller.ts
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
import Controller from "sap/ui/core/mvc/Controller";
import CreateEntry from "ui5/antares/pro/v2/entry/CreateEntry"; // Import the class

/**
 * @namespace your.apps.namespace
 */
export default class Main extends Controller {
    public onInit() {

    }

    public async onCreateProduct() {
        const entry = new CreateEntry({
            controller: this, 
            entitySet: "Products",
            guidVisibilityMode: "All"
        });
    }
}
Main.controller.js
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
sap.ui.define([
    "sap/ui/core/mvc/Controller",
    "ui5/antares/pro/v2/entry/CreateEntry" // Import the class
], (Controller, CreateEntry) => {
    "use strict";

    return Controller.extend("your.apps.namespace.Main", {
        onInit: function () {

        },

        onCreateProduct: async function () {
            const entry = new CreateEntry({
                controller: this, 
                entitySet: "Products",
                guidVisibilityMode: "All"
            });
        }
    });
});

Property Settings (propertySettings)

PropertySettings[]

Entity-specific configuration for individual properties belonging to the specified EntitySet. This array allows consumers to define property-level behaviors, such as marking fields as required, readonly, or excluded from the generated form or table.

Entry Class Availability

Property CreateEntry UpdateEntry DeleteEntry DisplayEntry
label ✅ Yes ✅ Yes ✅ Yes ✅ Yes
required ✅ Yes ✅ Yes ❌ No ❌ No
readonly ✅ Yes ✅ Yes ❌ No ❌ No
excluded ✅ Yes ✅ Yes ✅ Yes ✅ Yes
textInEditModeSource ✅ Yes* ✅ Yes* ❌ No ❌ No
layoutData ✅ Yes ✅ Yes ✅ Yes ✅ Yes

*Requires formType to be SmartForm

Implementation Mode Availability

Mode Available
Dialog Mode ✅ Yes
Component Mode ✅ Yes

PropertySettings Type

Property Type Mandatory Description
name string ✅ Yes The technical name of the property in the entity.
label string ❌ No Consumer-defined label for the property. If not provided, the library tries to derive it in the following order:

1. Metadata labels (if metadataLabelEnabled is true in the Entry class).
2. ResourceModel (i18n) labels based on naming conventions.
3. Generated from the property’s naming style (camelCase, CONSTANT_CASE).
required boolean ❌ No Marks the property as required.
readonly boolean ❌ No Marks the property as read-only.
excluded boolean ❌ No Excludes the property from rendering in the generated UI.
textInEditModeSource TextInEditModeSource ❌ No Source of display text in edit mode. Only applies when formType is SmartForm.
layoutData LayoutData ❌ No Layout data applied to the generated control.

Method Returns Description
getPropertySettings() PropertySettings[] Returns the current property settings array.

Method Parameter Type Mandatory Description
setPropertySettings(newValue) newValue PropertySettings[] ✅ Yes Sets the property settings for the generated form or table.

Example

Main.controller.ts
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import Controller from "sap/ui/core/mvc/Controller";
import CreateEntry from "ui5/antares/pro/v2/entry/CreateEntry"; // Import the class

/**
 * @namespace your.apps.namespace
 */
export default class Main extends Controller {
    public onInit() {

    }

    public async onCreateProduct() {
        const entry = new CreateEntry({
            controller: this, 
            entitySet: "Products",
            propertySettings: [
                { name: "ProductID", required: true },
                { name: "ProductName", label: "Product Name" },
                { name: "Category", readonly: true }
            ]
        });
    }
}
Main.controller.js
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
sap.ui.define([
    "sap/ui/core/mvc/Controller",
    "ui5/antares/pro/v2/entry/CreateEntry" // Import the class
], (Controller, CreateEntry) => {
    "use strict";

    return Controller.extend("your.apps.namespace.Main", {
        onInit: function () {

        },

        onCreateProduct: async function () {
            const entry = new CreateEntry({
                controller: this, 
                entitySet: "Products",
                propertySettings: [
                    { name: "ProductID", required: true },
                    { name: "ProductName", label: "Product Name" },
                    { name: "Category", readonly: true }
                ]                    
            });
        }
    });
});