Skip to main content

3.10. Caption Templates

3.10.1. Document Caption

The system allows configuring a template for each document type that is used to generate document captions automatically.

To change the caption template, open the Studio workspace → Document Types → the required document type. Then, in the Caption Template field, select one of the following options:

  • Registration Number or Document Number (default) — if the document is registered, the registration number is used as the caption. Otherwise, the document number is used

  • Document Number — the document number is used as the caption

  • Expression — allows configuring a custom expression for generating the document caption

The caption template expression can include the following elements:

  • Registration Journal Counter
  • Character, string, and numeric constants (inserted into the caption exactly as specified in the expression)
  • Document attributes (system and custom attributes), where the attribute value is inserted into the caption
  • Dates (current date, date with an offset from the current date, current date in different formats)
  • Arithmetic operations for numeric attributes (addition, subtraction, multiplication, division (with configurable decimal precision displayed in the caption) by a constant or another numeric attribute)
  • String operations for text attributes (basic SQL string functions — substring extraction, concatenation, uppercase/lowercase conversion)
  • Selection of one of several values based on a key value (where the key is a document attribute, and the possible values can be either constants or document attribute values)

When configuring an expression, a helper with the expression language syntax and available functions is available. To open it, click the question mark button.

After changing the caption template and saving the document type, the system displays information about the template change and the need to update captions.

To update captions, click the Update Document Captions button. Notifications about the start and completion of the update process will be displayed. If the document type contains a large number of documents, it is recommended to run the update process outside working hours.

Note:

The system also includes the dfx.updateDocsCaptions scheduler, which automatically starts the caption update process for all document types every morning at 01:05.

After document captions are configured and updated, they are used:

  • as the document caption

  • in the native Caption attribute, which can be used on document/task forms or as a shortcut column

  • in the native Parent Document attribute, which can be used on the document form or as a shortcut column

  • in the native Document Relationships attribute when creating relationships, as well as in the Related Document column

  • in the native Child Documents attribute in the Parent Document column

  • as the Document Link on the Duplicate Documents Found form when duplicate document control rules are triggered

  • in the native Related Document attribute on the task form

3.10.2. Custom Dictionary Record Title

The system allows configuring a template for each custom dictionary that is used to generate titles for dictionary records automatically.

To change the title template, open the Studio workspace → Custom DictionariesCustom Dictionaries, and then open the required custom dictionary. In the Title Template field, select one of the following options:

  • Code Name (default) — the title consists of the record code and name

  • Name — the record name is used as the title

  • Expression — allows configuring a custom expression for generating the record title

The title template expression can include the following elements:

  • Record Counter — the sequential number of the record in the dictionary
  • Character, string, and numeric constants (inserted into the title exactly as specified in the expression)
  • Dictionary attributes (system and custom attributes), where the attribute value is inserted into the title
  • Dates (current date, date with an offset from the current date, current date in different formats)
  • Arithmetic operations for numeric attributes (addition, subtraction, multiplication, division (with configurable decimal precision displayed in the title) by a constant or another numeric attribute)
  • String operations for text attributes (basic SQL string functions — substring extraction, concatenation, uppercase/lowercase conversion)
  • Selection of one of several values based on a key value (where the key is a dictionary attribute, and the possible values can be either constants or attribute values)

When configuring an expression, a helper with the expression language syntax and available functions is available. To open it, click the question mark button.

After changing the title template and saving the dictionary, the system displays information about the template change and the need to update titles.

To update titles, click the Update Item Titles button. Notifications about the start and completion of the update process will be displayed. If the dictionary contains a large number of records, it is recommended to run the update process outside working hours.

Note:

The system also includes the frm.updateItemsCaptions scheduler, which automatically starts the title update process for all dictionary records every morning at 00:15.

After dictionary record titles are configured and updated, they are used:

  • as the dictionary record title

  • when selecting records in Reference / Multiple Reference attributes

  • in the Title column, which can be used in Custom Dictionary grids