Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Section


Column
width30%600px


Panel
borderColor#333f48
bgColor#FFFFFF
titleColor#eeeeee
borderWidth1
titleBGColor#333f48
borderStylesolid
titleOn this page

Table of Contents
maxLevel1



Column




Features used to implement the example



Example: Set "Due date" with certain time offset from current date

I would like to update the Due date with Current date+2 while creating an issue. I have added the following post function through Jira Workflow Toolbox,

  • Option selected: Copy a parsed text to a field
  • Target Field : due date
  • Text to be parsed and then copied to target field: {Current date and time}+2*{DAY}

But it is not updating anything on the Due Date field. Please advise on the syntax to be used.


To do mathematical or time calculations like the one you are trying to do, you should use post-function Mathematical and date-time expression calculator.

If you use the formula {00057}+2*{DAY}, you will be adding to natural days to current date and time. Next version of the plugin (2.0.19) will provide function addDaysSkippingWeekends(t, n, time_zone). With this function you will be able to add "working days", i.e., you will be able to add days skipping the weekends.

Image Removed

Text to be parsed is: addDaysSkippingWeekends({00057},2,LOCAL)

Note that %{00057} is field code for "Current date and time".

Image Added


Once configured, the transition looks like this:


Image RemovedImage Added



Other examples of that function

Incoming Links
pageMathematical and date-time expression calculator
labelsexample



Related Usage Examples

Content by Label
showSpacefalse
cqllabel = "example" and label = "post-function"