--- title: "Create book entry from shipment" slug: "tsmt-create-time-slot-book-entry-header-from-shipment-configuration" updated: 2026-04-02T09:01:10Z published: 2026-04-02T09:01:10Z canonical: "docs.lobstersoftware.com/tsmt-create-time-slot-book-entry-header-from-shipment-configuration" --- > ## 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. # Create book entry from shipment *See also:* [Time slot management tool (Events)](/v1/docs/en/tsmt-tsmt-action-event) > [!NOTE] > Event action – Abstract > > **Purpose:** Creates a time slot booking based on a shipment, which can optionally be assigned static values for specific fields and attribute values from the shipment. > > > [!TIP] > > Tooltip > > > > - **Usage:** Typically, the event action is executed in the context of the ribbon macro command 'Time slot booking/Create' which triggers the event 'Create book entry from shipment'. Then the created (volatile) time slot booking automatically appears in a details form, which is shown as a modal window. It can then be edited and saved or canceled. > > - **Parameter:** > > - Static selection fields for specific characteristics of the time slot booking: **Package type**, **Type of vehicle**, **Kind of Goods**, **Mode of transport**. > > - **Copy attributes**: Repeating element for configuring value resolvers for attributes copied from the *reference object* (shipment) to the time slot booking. > > - **Output:** A new (volatile) entity of the time slot booking type with the assigned characteristics as the only element in a list in the `header` variable. ![images/download/attachments/177913538/image-2024-9-24_14-45-19-version-1-modificationdate-1727181918877-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_14-45-19-version-1-modificationdate-1727181918877-api-v2.png) The event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) will create an entity of the 'Time slot booking' type from an entity of the 'Shipment' type (see [Shipments](/v1/docs/en/shp-shipment)). The time slot booking created can be classified via static assignments for selection fields according to specific criteria for the [Time slot management](/v1/docs/en/orchestration-rules-tsmt). - The [Time slot management](/v1/docs/en/orchestration-rules-tsmt) module provides its own dynamic enumerations ([Package types](/v1/docs/en/tsmt-package-type), [Type of vehicle](/v1/docs/en/tsmt-type-of-vehicle), [Kinds of goods](/v1/docs/en/tsmt-kind-of-goods), [Mode of transport](/v1/docs/en/base-mode-of-transport)) in which user-defined values for this classification can be stored. In addition, the values of selected typed attributes can be transferred from the shipment to the newly created time slot booking via the **Copy attributes** tab. **NOTE:** 'Copying' only works for attribute types that are also supported for the 'Time slot booking' entity (see listing under [Input forms for time slot booking](/v1/docs/en/administration-designer-entity-form-time-slot-book-entry)). Further restrictions are described in the 'Configuration' section below. The event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) is typically executed to an event handler that reacts to the trigger 'Create book entry from shipment' (see [Time slot management tool (Events)](/v1/docs/en/tsmt-tsmt-action-event)). This event is triggered by the ribbon macro command 'Time slot booking/Create' (see [Available commands](/v1/docs/en/ribbon-commands)), which provides the following workflow for creating a time slot booking for an existing shipment: 1. A single selection within an overview or the opened input form identifies exactly one shipment for which a time slot booking is generated. 2. The command 'Time slot booking/Create' is executed within a ribbon macro (by clicking on a ribbon button) and triggers the event 'Create book entry from shipment'. 3. An event handler reacts to the event 'Create book entry from shipment' and executes the event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration). 4. Provided that the event action can successfully generate a time slot booking, a [Booking overview](/v1/docs/en/tsmt-time-slot-book-entry-header) is opened with the volatile data of the new time slot booking. 5. The user can edit the created time slot booking there and create or discard it via 'Save'. The actual 'booking', i.e. the scheduling of the generated time slot booking on a date for a specific loading point, takes place in a separate step within the [Booking overview](/v1/docs/en/tsmt-time-slot-book-entry-header). ## Configuration The event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) expects an entity of the type 'Shipment' (see [Shipments](/v1/docs/en/shp-shipment)) for which another entity of the type 'Time slot booking' is to be created. - In the typical use case (see above) of the event action, the shipment exists as a *reference object* and input value of the surrounding event handling. - However, the event action does not directly access the *reference object* (in the variable `entity`). Rather, it expects a list of shipments as the value of the `shipments` variable. - In a typical application, the `shipments` variable contains exactly one element, namely the shipment, which is also the *reference* *object*. - However, the preassignment of the `shipments` variable is only guaranteed if the event handling was triggered by the event 'Create book entry from shipment' (see [Time slot management tool (Events)](/v1/docs/en/tsmt-tsmt-action-event)). If the event action is to be used independently of the event 'Create book entry from shipment', an existing shipment can also be assigned to the variable shipments as an element of a list. - But then the `header` variable must also be initialized with an (empty) list object. The event action adds the newly created time slot booking instance to this list (if successful). - The `header` variable also allows 'post-processing' or saving the created entity if needed (per [Save changes later](/v1/docs/en/core-merge-later-once-actor)). If the `shipments` and `header` variables are not 'suitably' prepared in the context of the event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration), an error with *rollback* occurs at runtime. | The **Create book entry from shipment** tab contains one selection field each for the specific dynamic enumerations that the [Time slot management](/v1/docs/en/orchestration-rules-tsmt) module provides for the classification of time slot bookings. Each parameter corresponds to a field in the 'Time slot booking' data model, for which a static assignment can *optionally* be defined: | ![images/download/attachments/177913538/image-2024-9-24_14-45-29-version-1-modificationdate-1727181928837-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_14-45-29-version-1-modificationdate-1727181928837-api-v2.png) | | --- | --- | | **Parameter/Enumeration/Field** | **Field name (internal)** | | [Package types](/v1/docs/en/tsmt-package-type) | `packageType` | | [Type of vehicle](/v1/docs/en/tsmt-type-of-vehicle) | `typeOfVehicle` | | [Kinds of goods](/v1/docs/en/tsmt-kind-of-goods) | `kindOfGoods` | | [Mode of transport](/v1/docs/en/base-mode-of-transport) | `modeOfTransport` | | In the second tab **Copy attributes**, a [Repeatable element](/v1/docs/en/fre-duplicate-element-container-vo) *optionally* allows the configuration of multiple value resolvers for attributes whose value is copied from the shipment to the new time slot booking. **IMPORTANT:** Unsuitable configurations for **Copy attributes** lead to an error with a *rollback* at runtime. The following rules must be observed: 1. The attribute type must be applicable for the 'Time slot booking' entity type (see [Input forms for time slot booking](/v1/docs/en/administration-designer-entity-form-time-slot-book-entry) for applicable attribute types). 2. Plural attributes cannot be copied even if they are applicable to a 'Time slot booking' according to their type. The 'Example' (below) shows how they can be transferred. 3. The value resolver for [All attributes of one type](/v1/docs/en/core-attributes-resolver) cannot be used to copy attributes of a type across the board. | ![images/download/attachments/177913538/image-2024-9-24_14-46-41-version-1-modificationdate-1727182000862-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_14-46-41-version-1-modificationdate-1727182000862-api-v2.png) Via the symbols ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/add.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/add(32).svg) and ![images/s/-95e2zf/9012/8yg2g7/_/images/icons/emoticons/forbidden.svg](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/forbidden(20).svg) configurations for **Copy attributes** can be added or removed. Within each instance created, a value resolver must be used that returns a complete, single attribute of the shipment that is applicable by type to the time slot booking. Typically, a [Typed attribute resolver](/v1/docs/en/core-typed-attribute-resolver) is used for this purpose. | ## Example The [Time slot management](/v1/docs/en/orchestration-rules-tsmt) is used for scheduling acceptance processes for 'toxic waste' at discrete (un)loading points in a waste management company. For planned shipments with the [Shipment type](/v1/docs/en/shp-shipment-type) 'toxic waste disposal', it should be possible to create a 'time slot booking' at the push of a button. The time slot bookings created in this way result in a 'worklist' from which the controller responsible for unloading compiles a booking plan for the loading points. Characteristics of the shipment that are relevant for this detailed planning are to be automatically transferred for the time slot booking. Runtime example: | Shown on the right is a data input form for shipments of the 'Toxic waste disposal' [Shipment type](/v1/docs/en/shp-shipment-type) with the following characteristics: - Since a 'toxic waste' shipment in our case should always be 'bulk', only two numerical attributes **Gross volume** and **Gross** **weight** are provided. For planning the unloading, only the 'Gross volume' in the binding preset [Volume unit](/v1/docs/en/core-volume-unit) 'Cubic meter' is decisive. - The time attribute **Arrival date planned** provides information about the scheduled time of delivery. - The company attribute **Carrier** specifies the company responsible for the transport. - The following 'Reference attributes' qualifies various characteristics of the shipment, each of which can occur either once or multiple times. - A list of container identifiers in the plural text attribute **Container No** follows below, which makes it possible to trace the origin of the shipped waste if required. As far as this information is relevant for unloading, it should also be visible in a 'Time slot booking'. From the controller's point of view, this data should appear in the [Booking overview](/v1/docs/en/tsmt-time-slot-book-entry-header) as shown below: | ![images/download/attachments/177913538/image2021-8-30_9-29-51-version-1-modificationdate-1727181487716-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2021-8-30_9-29-51-version-1-modificationdate-1727181487716-api-v2.png) | | --- | --- | | ![images/download/attachments/177913538/image2021-8-30_9-35-57-version-1-modificationdate-1727181487714-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2021-8-30_9-35-57-version-1-modificationdate-1727181487714-api-v2.png) | Configuration: The following configuration applies to a typical usage scenario, i.e. a triggering of the event handling via the ribbon macro command 'Time slot booking/Create' (see [Available commands](/v1/docs/en/ribbon-commands)). However, the action part of the event handling also shows design options that are not part of the *typical* procedure. | An event handler for the **Triggering event** 'Create header from shipment' (see [Time slot management tool (Events)](/v1/docs/en/tsmt-tsmt-action-event) is created and configured as follows: - The **Validating rule** here combines a type check for the 'Shipment' entity type with an object field rule that checks whether the shipment type 'Toxic waste disposal' is specified. Details on this are omitted. **NOTE:** The **Triggering event** provides the same shipment as the only element of a list in the shipments variable. Only this is immediately processed by the event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration). The **Action on passed rule** is first shown here in overview and will be highlighted in more detail in the following sections: - In the first step, the event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) is executed to create a time slot booking for the shipment and initialize it using the means of the event action. - The following [Execute with](/v1/docs/en/core-with-actor) event action accesses the created time slot booking via the header variable, which should be present in it as the only element of a list after the [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) event action has been executed. In addition to adjustments to the time slot booking that are not directly possible via the default functions, a reference to the newly created time slot booking is also set up in the shipment data in the process. - Finally, the event action [Save changes later](/v1/docs/en/core-merge-later-once-actor) for must be executed with the shipment as the *reference object* so that the created reference is saved. | ![images/download/attachments/177913538/image-2024-9-24_16-36-50-version-1-modificationdate-1727188609418-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_16-36-50-version-1-modificationdate-1727188609418-api-v2.png) | | --- | --- | | The event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) is configured as shown on the right: - In the **Create book entry from shipment** tab, some of the *optional* parameters are used to define static assignments for fields of the new time slot booking. The following classification should apply to all shipments for which the **Validating rule** (see above) applies: - The delivery is always made by the [Type of vehicle](/v1/docs/en/tsmt-type-of-vehicle) 'Barge'. - The type of goods is always 'Bulk'. - The [Mode of transport](/v1/docs/en/base-mode-of-transport) is always 'Sea freight'. **NOTE:** The [Type of packaging](/v1/docs/en/base-type-of-packaging) is not set statically here. In the post-processing of the time slot booking, an assignment for the field could be made starting from data of the shipment. However, this is not necessary. In the second tab, **Copy attributes**, the [Typed attribute resolver](/v1/docs/en/core-typed-attribute-resolver) is used four times to specify attributes of the program as copy attributes: - Date attribute for the [Date type](/v1/docs/en/base-date-type) 'Arrival date planned'. - Company attribute for the [Company type](/v1/docs/en/base-company-type) 'Carrier'. - Numeric attribute for the [Numeric types](/v1/docs/en/base-numeric-value-type) 'Gross volume'. - Numeric attribute for the [Numeric types](/v1/docs/en/base-numeric-value-type) 'Gross weight'. At runtime, this configuration causes corresponding typed attributes to be created in the data of the new time slot booking, provided that the shipment contains corresponding data. **NOTE:** Whether the [Booking overview](/v1/docs/en/tsmt-time-slot-book-entry-header) contains elements for the display of corresponding details (see [Input forms for time slot booking](/v1/docs/en/administration-designer-entity-form-time-slot-book-entry)) is irrelevant for the creation of the attributes. However, it is crucial that only attribute types are used that are supported in principle for the 'time slot booking' entity. In the present example, against this background, on the one hand the 'Reference attributes' of the shipment are problematic, since this attribute type is basically not applicable in time slot bookings. On the other hand, the plural text attribute 'Container No' cannot be copied with the standard methodology. | ![images/download/attachments/177913538/image-2024-9-24_16-37-26-version-1-modificationdate-1727188645803-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_16-37-26-version-1-modificationdate-1727188645803-api-v2.png)**Copy attributes** tab:![images/download/attachments/177913538/image-2024-9-24_16-39-5-version-1-modificationdate-1727188744631-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image-2024-9-24_16-39-5-version-1-modificationdate-1727188744631-api-v2.png) | | Since not all data from the shipment can always be transferred to the newly created time slot booking using the default methodology, here are some options for specific 'post-treatment' of the entity: - Within the [Execute with](/v1/docs/en/core-with-actor) event action shown on the right, the time slot booking is first defined as a *different reference object* for the subsequent event actions. The event action [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) returns the time slot booking via the `header` variable as the only element of a list that was previously initialized when the event was executed (empty). The [List item](/v1/docs/en/core-list-item-resolver) value resolver concatenated with the [Variable](/v1/docs/en/core-storage-value) value resolver with the **Offset** value of 0 defines first (*here*: only) element of the list. - The following [Set value](/v1/docs/en/core-set-value-actor) event action assigns a string to the **Remarks** (`remarks`) field that is generated from a list of all reference attributes (see [All attributes of one type](/v1/docs/en/core-attributes-resolver)) via [Collect values](/v1/docs/en/core-collect-resolver) as a [Concat strings](/v1/docs/en/core-concat-string-resolver) of [Reference type](/v1/docs/en/base-reference-type) and the value of the 'reference' (`reference`) per attribute. The output can be seen in the runtime example above. Details are omitted. **NOTE:** The 'references' are only reproduced informatively by the concatenation. Systematic access to individual values is then only guaranteed to a limited extent. For the controller responsible for planning, the mirroring of the shipment data in this form should be sufficient. - The following [Set value](/v1/docs/en/core-set-value-actor) event action transfers the 'Container No' list from the plural text attribute of the shipment directly to the corresponding attribute of the time slot booking. Here, for source and destination, the [Plural typed attribute resolver](/v1/docs/en/core-typed-attributes-resolver) can be used successfully – unlike the **Copy attributes** tab of the [Create book entry from shipment](/v1/docs/en/tsmt-create-time-slot-book-entry-header-from-shipment-configuration) event action. - With [Save changes later](/v1/docs/en/core-merge-later-once-actor), the new time slot booking is then marked for saving at the end of the transaction. This will immediately assign an ID to it. Which is needed for the next step. - Per [Set value](/v1/docs/en/core-set-value-actor), the ID of the new time slot booking is noted as 'linkedEntityId' in a linked entity attribute (with the 'Time slot booking' type – `SHIPMENT_TO_BOOKING`) provided for this purpose in the shipment. | ![images/download/attachments/177913538/image2021-8-30_9-42-46-version-1-modificationdate-1727181487703-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2021-8-30_9-42-46-version-1-modificationdate-1727181487703-api-v2.png) | **NOTE:** In a data input form for 'Toxic waste' shipments, an element for the linked entity attribute can then be included, in which not only the reference to the time slot booking can be seen, but also, for example, its work status: ![images/download/attachments/177913538/image2021-8-30_9-51-29-version-1-modificationdate-1727181487682-api-v2.png](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/image2021-8-30_9-51-29-version-1-modificationdate-1727181487682-api-v2.png) - In the example, the booking overview with the data of the referenced time slot booking can also be opened via a [Button](/v1/docs/en/fre-button-vo) (at the very top right).