Documentation for JIRA 4.3. Documentation for other versions of JIRA is available too.
Most people scratch their head to know what parameters and Object
's are in the Velocity context, the links below may come into help:
For developers, who want to know more, the DefaultVelocityManager
creates a self-reference back to the VelocityContext
with these lines:
protected VelocityContext createVelocityContext(Map params) { if (params != null) { params.put("ctx", params); } ...
Therefore, doing this in the template will display the available parameters:
#foreach($p in $ctx.keySet().toArray()) $p.toString() - $ctx.get($p).getClass().getName().toString() #end
e.g.
textutils - com.opensymphony.util.TextUtils dateformatter - com.atlassian.jira.web.util.OutlookDate stringUtils - org.apache.commons.lang.StringUtils formatter - java.text.SimpleDateFormat constantsManager - com.atlassian.jira.config.DefaultConstantsManager buildutils - com.atlassian.jira.util.BuildUtils i - java.lang.Integer context - com.atlassian.jira.mail.TemplateContext jiraUserUtils - com.atlassian.jira.util.JiraUserUtils baseurl - java.lang.String security - $ctx.get($p).getClass().getName().toString() numdashes - java.lang.Integer ctx - java.util.HashMap jirakeyutils - com.atlassian.jira.util.JiraKeyUtils i18n - com.atlassian.jira.web.bean.I18nBean recipient - com.opensymphony.user.User velocityCount - java.lang.Integer attachments - java.util.ArrayList remoteUser - com.opensymphony.user.User userutils - com.atlassian.core.user.UserUtils applicationProperties - com.atlassian.jira.config.properties.ApplicationPropertiesImpl padSize - java.lang.Integer customFieldManager - com.atlassian.jira.issue.managers.DefaultCustomFieldManager issue - com.atlassian.jira.mail.TemplateIssue jirautils - com.atlassian.jira.util.JiraUtils params - java.util.HashMap projectManager - com.atlassian.jira.project.CachingProjectManager velocityhelper - com.atlassian.jira.util.JiraVelocityHelper timeSpentFieldId - java.lang.String