This article summarizes different functions you can place in source code to generate content from a data source and perform actions on that auto-generated content.

This article summarizes different functions you can place in source code to generate content from a data source and perform actions on that auto-generated content. The table below summarizes the auto-generated content attributes themselves, when you might use them, and where you can use them. Click on an attribute to jump to the article that details the attribute's syntax, possible use cases, and example code snippets demonstrating its use.


Attribute

Use Case

HTML elements you can use it on

data-source

Specify location from which to pull data

<table> Elements with data-show-if or data-hide-if to access field values within an array

data-group-by

roll-up summary data by grouping specific records

<table>; <tr> (within pricing table) Elements with data-repeat attribute

data-filter

filtering data by a user-defined criteria

<table>, <tr>, <tfoot>; <div>; <p> Elements with data-repeat attribute

data-show-if data-hide-if

Showing/hiding data based on some user-defined criteria

All HTML elements Elements with data-source (including auto-gen tables and data-repeat blocks)

data-repeat

looping through a number of records in an object array

Any HTML element that you want to display array content

data-format

formatting data

Anything within an auto generated content block (data-repeat, tables with data-source, etc.)

data-locale

deprecated - reference for historical documentation purposes


Math expressions can also be evaluated with auto-generated content. For more information, reference this article.

Syntax for Using Attributes

The syntax for all auto-gen content attributes can be seen below, where the placeholders are replaced with the actual names desired by the user.

<attribute>="<variable_name> <operator> '<value>'"Example: data-show-if="PricebookEntry.Product2.Name LIKE 'Test'"

Details on each component:

  • <attribute>: Auto-generated functionality as defined in the table above.

  • <variable_name>: The name of the variable used in the comparison statement.

    In the case of the data-repeat attribute, the <variable_name> is actually an arbitrary loop iteration variable that you define.

  • <operator>: The part of the statement that allows for a comparison to occur, such as ==, !=, or LIKE.

    <operator> is not used in the data-sort, data-group-by, or data-source attributes.

  • <value>: The value to which the <variable_name> is compared using the <operator> .

    <value> is not used in the data-sort, data-group-by, or data-source attributes <value> is an array name in the data-repeat and data-source attributes.

Variable Syntax for Auto-Generated Content

Conga Collaborate searches for [square brackets] in order to identify a variable that will pull auto-gen content into the document. Because of this, every variable you want to access must be surrounded by a set of single open and closed brackets.

Example using an auto-generated table:

<table data-source="object_name"><thead> <tr><th>Field</th></tr></thead> <tbody><tr><td>[FieldName]</td></tr></tbody></table>