Skip to main content

Include Tables or Collections

Include Tables or Collections

Overview

There are two types of tables that can be included in emails: Static and Dynamic.

  • Static tables: These have a fixed number of columns and rows, defined at development time. The information is either fixed text or attributes from the data model without one-to-many relationships.

    Example of a static table in the Work Portal:
    Static Table Work Portal

    Example of how the static table appears in the email:
    Static Table Email

  • Dynamic tables: These display information stored in collections or one-to-many relationships, similar to how they appear as tables in the Work Portal.

    Example of a collection in the Work Portal:
    Dynamic Table Work Portal

    Example of how the dynamic table appears in the email:
    Dynamic Table Email


Example to Include a Static Table

Suppose you want to send an email confirming the products and delivery details of a Purchase Request after it has been approved. You need to include attributes like Purchase Justification, Delivery Date, and Delivery Address in a table for a structured look.

Example of information in the Work Portal and how it appears in the email:
Static Table Example

Steps:

  1. Insert a Static Table

    • Click the Static Table button in the ribbon and select the number of rows and columns (e.g., three columns and two rows).
      Insert Static Table
  2. Create the Table Header

    • Use the first row to define the column headers.
      Define Table Header
  3. Include Data Model Information

    • Place the cursor in a table field and insert data model attributes using angle brackets < > or the XPath Field button.
  4. Save the Email

    • When the email configuration is complete, click Save.
      Completed Static Table

Example to Include a Dynamic Table

Suppose you need to send an email to a client after their Loan Request is approved. The email will list approved loans (products) in a table.

Data Model Example
Notice the one-to-many relationship between the Process Entity, Request, and the Products entity.
Dynamic Table Data Model

Email Example
The email should display a table like this:
Dynamic Table Email Example

Steps:

  1. Insert a Dynamic Table

    • Place the cursor where the table should appear.
    • Click the Dynamic Table button in the ribbon.
      Insert Dynamic Table
  2. Configure Table Properties

    • A new window will appear with four tabs: Grid Data, Header Style, Body Style, and Table Style.
      Dynamic Table Properties

    • Grid Data:

      • Select the collection XPath (e.g., PurchaseRequest.ProductsRequested) and apply filters if necessary.
        Grid Data Tab

      • Define the columns to display and optionally customize their display names.
        Define Columns

    • Header Style:

      • Configure the header background color, text alignment, and font properties.
        Header Style Tab
    • Body Style:

      • Configure the body background color, text alignment, and font properties.
        Body Style Tab
    • Table Style:

      • Set table alignment (left, right, or centered) and enable headers.
        Table Style Tab
  3. Finalize the Table

    • Click OK to include the table in the email body.
      Dynamic Table Included
  4. Edit or Remove the Table

    • Double-click the table to edit it or delete it by selecting the table icon and pressing Backspace.
  5. Save the Email

    • Click Save to complete the email configuration.
      Completed Dynamic Table