Automation

Document Templates and Automation Rendering Service

Freemarker templating language (ftl)

**${Document}** - the context document. This is the document on which the rendering is done in the case the rendering is done on a single document. When the input is a list of document then this variable is undefined. ${This} - the rendering input. Will be a document in the case of a single document or a list of documents in th case of multiple documents. ${Session} - the current core session. **${Context}** - the context. ${CurrentDate} - the current date. See Use of MVEL in Automation chains (date wrapper) for details. ${Fn} - a collection of useful functions. See Use of MVEL in Automation chains (fn object) for details. **${Env}** - a hashmap containing Nuxeo environment variables. Example: Env["org.nuxeo.ecm.product.name"]. **${CurrentUser}** - the current user.

Note that **${CurrentUser}** is not correctly working for now in ftl templates - but only in mvel templates.

By using the freemarker templating engine, you also gain access to its whole functionalities. For example, using a document list could be done as following:

<#list This as doc>
  ${doc.title}

Have a look at the freemarker manual for more information about it.

MVEL

**${Document}** - the context document. This is the document on which the rendering is done in the case the rendering is done on a single document. When the input is a list of document then this variable is undefined.${This} - the rendering input. Will be a document in the case of a single document or a list of documents in th case of multiple documents. ${Session} - the current core session. **${Context}** - the context. ${CurrentDate} - the current date. See Use of MVEL in Automation chains (date wrapper) for details. ${Fn} - a collection of useful functions. See Use of MVEL in Automation chains (fn object) for details. **${Env}** - a hashmap containing Nuxeo environment variables. Example: Env["org.nuxeo.ecm.product.name"]. **${CurrentUser}** - the current user.

By using MVEL, you also gain access to its whole functionalities. For example, using a document list could be done as following:

@foreach{doc : This}
  @{doc.title}
@end{}

Have a look at the MVEL manual for more information about it.

3 months ago manonlumeau Relocated assets to fit new URL structure for 60 - fix
5 years ago Alain Escaffre 4
6 years ago Bertrand Chauvin 3
6 years ago Bertrand Chauvin 1
6 years ago Bertrand Chauvin 2
History: Created by Bertrand Chauvin

We'd love to hear your thoughts!

All fields required