This function adds or substracts days to/from any given date.
addDays(timestamp, numberOfDays, timeZone) #Output: Number
You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 19 Next »
This function adds or substracts days to/from any given date.
addDays(timestamp, numberOfDays, timeZone) #Output: Number
Parser expression | Description |
---|---|
addDays({issue.duedate}, 2, LOCAL) | This example adds 2 days to the issue's due date. |
addDays({issue.duedate}, -2, LOCAL) | This example substracts 2 days from the issue's due date. |
addDays({issue.cf10100}, -6, USER_LOCAL) | This example substracts 6 days from a custom date-time field (with the ID 10100). Instead of the Jira server's local time this example uses the current user's time zone. |
Parameters used in this function
Parameter | Input (data type) | Description |
---|---|---|
timestamp | NUMBER | The parameter must be valid timestamp. Usually this value is retrieved from a field (e.g. due date, created date). |
| NUMBER | The number defined here will be the offset in days. Negative values are used to substract days. Internally JWT multiplies this value with the time macro |
timeZone | TIMEZONE | The time zone used for the calculation. |
This function returns a NUMBER representing a timestamp.
The output can be written into any Jira field of type Date Picker ore Date Time Picker.
Another very common use case is to use this function in a JWT calculated date-time fields.
Powered by Atlassian Confluence 8.5.16, themed by Refined 7.6.0 and Decadis AG