Freemarker context variables for item templates

Freemarker context variables for item templates#

Many templates, such as email templates and wiki inline templates, let you use Freemarker placeholders for item attributes. These templates use Freemarker as their language. The following table lists the available placeholders.

Template placeholders for email and wiki templates#

Name

Description

f<attributeID>

the (new) value of the item attribute identified by attributeID

<attributeName>

the (new) value of the attribute identified by the (non-localized) attribute name

f<attributeID>Old

the old value of the item attribute identified by attributeID

<attributeName>Old

the old value of the attribute identified by the (non-localized) attribute name

f<attributeID>Name

the name of the item attribute identified by attributeID

<attributeName>Name

the name of the attribute identified by the (non-localized) attribute name

f<attributeID>Label

the localized name of the item attribute identified by attributeID

<attributeName>Label

the localized name of the attribute identified by the (non-localized) attribute name

f<attributeID>Changed

boolean value indicating whether the item attribute identified by attributeID has just been changed

<attributeName>Changed

boolean value indicating whether the item attribute identified by the attribute name has just been changed

Each context variable is accessible through its id <attributeID> or its name <attributeName>.

You can find the attribute name under Administration > Items > Item attributes. If the name is changed, all email templates and wiki templates must be adjusted. The attribute ID cannot be changed, but it is harder to read and more difficult to determine (recommended via the REST API).