Conditionally Show or Hide a Section in your templates


Conditional tags in AutomatedDocs allow you to display content in your document based on specific criteria. Content enclosed between the opening and closing tags will only appear in the final document if the condition evaluates to true.


Usage:

  ${IF(condition)}
  Content to include if the condition is met.
  ${/IF}

Example:

${IF(acceptance_section eq yes)}

  This is the acceptance section of the document. Will only be shown in the final document if the value of acceptance_section is set to 'yes'. Otherwise this section will not be shown in the final document.

${/IF}

In the example above, the acceptance section of the document will only appear in the final document if the value of acceptance_section is set to 'yes'. If it is not, this section will be omitted.

Conditions Types

Automated Docs support the following conditions

AutomatedDocs supports the following conditions for evaluating data:

  • eq: Equals to.
  • neq: Not equal to.
  • contains: Checks if the text contains the specified value.
  • notContains: Checks if the text does not contain the specified value.