--- title: "Is new entity" slug: "frebehav-is-new-entity-behaviour" updated: 2026-05-04T08:32:55Z published: 2026-05-04T08:32:55Z canonical: "docs.lobstersoftware.com/frebehav-is-new-entity-behaviour" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # Is new entity > [!NOTE] > The behavior type [Is new entity](/v1/docs/en/frebehav-is-new-entity-behaviour) examines the element data of the executing element to determine whether it refers to a "new" – i.e. previously unsaved – instance of an *entity*. The *entity* in question can be a business object (see [Shipments](/v1/docs/en/shp-shipment), [Orders](/v1/docs/en/ord-order), [Manifests](/v1/docs/en/mfst-manifest), [Common business object](/v1/docs/en/orchestration-common-bto)), a line item of a business object, a configuration object or a master data object. Within a form, several entities of different types are often in a hierarchical relationship. A business object can contain line items and often uses typed attributes to refer to addresses or company accounts, which in turn use addresses. Starting from the executing element, the behavior type [Is new entity](/v1/docs/en/frebehav-is-new-entity-behaviour) always refers to the nearest parent entity. For [Input forms](/v1/docs/en/base-entity-form), there is at least a reference to the entity that provides the form data. [Portals](/v1/docs/en/portal-portal) and [Dashboard](/v1/docs/en/dashboard-1), on the other hand, are by definition not bound to any entity, but can contain data from entities, for example, if an entry form is embedded (see [Embed forms (Sub-forms)](/v1/docs/en/fre-embedded-forms)) or when data from an entity has been set for an [Element containers](/v1/docs/en/fre-element-container-vo) using [Populate element data](/v1/docs/en/freaction-populate-data). Only if the executing element fulfills all of the following conditions are the **Actions on "false"** executed, since a data object that is "not new" was detected: - The element data are directly or indirectly related to an entity. - The identified entity has a long value other than 0 in the ID (`id`) field. > [!NOTE] > **NOTE:** > > Whether the entity actually exists on the server side is not the subject of the check. Only the form data available at the client is evaluated. Conversely, the **Actions on "true"** are executed if one of these conditions is not met, i.e. either no reference to an entity exists (e.g. in a portal) or an entity has been detected to which no ID (`id`) has yet been assigned (*default value 0*). The behavior type does not expect any input data (`$input`) and passes this data directly to the respective actions if necessary. ## Examples Within the same entry form for [Shipments](/v1/docs/en/shp-shipment), the behavior type [Is new entity](/v1/docs/en/frebehav-is-new-entity-behaviour) should be used to demonstrate two different entities: 1. At header level ("Shipment"), it should be ensured that the required header data (required fields) have been filled in and saved before line item data can be edited. 2. When editing line items, any line items added since the shipment was last saved should be marked with a suitable symbol (![images/download/attachments/189432132/image2020-5-25_17-29-19-version-1-modificationdate-1727769117762-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2020-5-25_17-29-19-version-1-modificationdate-1727769117762-api-v2.png)). Runtime examples: ![images/download/attachments/189432132/image2020-5-26_10-37-48-version-1-modificationdate-1727769117790-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2020-5-26_10-37-48-version-1-modificationdate-1727769117790-api-v2.png) - When creating a new shipment, only an inactive "placeholder" appears for the line items. Once the header data has been filled in, access to line items (see below) can be obtained by "saving" and the note in the label disappears: ![images/download/attachments/189432132/image2020-5-26_10-40-43-version-1-modificationdate-1727769117792-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2020-5-26_10-40-43-version-1-modificationdate-1727769117792-api-v2.png) If the shipment is saved after entering the first line item, the symbol (![images/download/attachments/189432132/image2020-5-25_17-29-19-version-1-modificationdate-1727769117762-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2020-5-25_17-29-19-version-1-modificationdate-1727769117762-api-v2.png)) for the first row disappears and the newly added item can be distinguished: ![images/download/attachments/189432132/image2020-5-26_10-43-29-version-1-modificationdate-1727769117795-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2020-5-26_10-43-29-version-1-modificationdate-1727769117795-api-v2.png) Configuration: | ![images/download/attachments/189432132/image-2024-10-1_10-12-49-version-1-modificationdate-1727770370072-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-10-1_10-12-49-version-1-modificationdate-1727770370072-api-v2.png) | A behavior is configured for the form element, as shown on the left: - The **Triggering event** [Form data loaded](/v1/docs/en/fretrigger-form-data-loaded-element) becomes active when loading data into the form. --- - The **Behavior** **type** [Is new entity](/v1/docs/en/frebehav-is-new-entity-behaviour) can then check whether – e.g. by clicking the ribbon button "New" or "Copy", a new entity of the "Shipment" type has been made available. --- - Via the **Actions on "true"**, access to the line items is blocked for a new shipment object via the [Disable element](/v1/docs/en/freaction-disable) action. Conversely, the [Show element](/v1/docs/en/freaction-show) action reveals a [Label](/v1/docs/en/fre-label-vo) element that indicates the reason for being blocked (see above). --- - If the shipment object has been saved, which is only possible after all active mandatory fields have been filled in, then the **Actions on "false"** work inversely: An [Enable element](/v1/docs/en/freaction-enable) action allows the creation of line items, and the [Label](/v1/docs/en/fre-label-vo) with the hint is hidden by the [Hide element](/v1/docs/en/freaction-hide). | | --- | --- | | ![images/download/attachments/189432132/image-2024-10-1_10-16-7-version-1-modificationdate-1727770567369-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-10-1_10-16-7-version-1-modificationdate-1727770567369-api-v2.png) | The behavior shown on the left has been configured for the text field "Line item no." (see above) in the [Repeatable element](/v1/docs/en/fre-duplicate-element-container-vo) container for the "Line items". Therefore, the respective shipment line item is the essential entity for the behavior type: - The **Triggering event** [Form data loaded](/v1/docs/en/fretrigger-form-data-loaded-element) is active at line item level not only when the form data is loaded, but also when each additional row is added. --- - The **Behavior type** [Is new entity](/v1/docs/en/frebehav-is-new-entity-behaviour) checks each displayed item with respect to the `id` only visible in the data. --- - Via the **Actions on "true"**, the [Image/Icon](/v1/docs/en/fre-image-vo) linked as a **Target element** is set to visible for a newly recognized item with the [Show element](/v1/docs/en/freaction-show) action. --- - Via the **Actions on "false"**, the [Image/Icon](/v1/docs/en/fre-image-vo) linked as a **Target element** is set to invisible for an already saved position with the [Hide element](/v1/docs/en/freaction-hide) action. **NOTE:** It is not possible to see whether a previously saved position has been changed. |