Section |
---|
Column |
---|
A variable looks up a value from the template context. If you want to insert the value of a variable in your template, you can use the following syntax: {{ myVar }} . This looks up for the myVar variable from the context and displays it. Variable names can have dots in them which look up properties, just like in javascript. Variables available in JMWEJMWE makes the issue, transition, linkedIssue, parentIssue, now and currentUser variables available to templates. You can access their properties using "." or "[ ]". For example, you can access the current issue key using {{issue.key}} . |
Column |
---|
|
Panel |
---|
borderColor | silver |
---|
bgColor | #f5f5f5 |
---|
borderWidth | 1 |
---|
borderStyle | solid |
---|
| On this page: |
|
|
...
{{
now}}
returns the current date and time, e.g. 2016-09-30T13:57:23.608Z
User-defined variables
In addition to the above variables, you can also create your own variables within the template using the set Nunjucks tag.
For example:
{% set x = "High" %}
sets the value of the variable x to High. You can also set the variable to an object. For example: {% set assignee = issue.fields.assignee %}
...