This post function allows you to copy a field value from multiple issues to the current issue. Since potentially multiple values will be returned, the values can be aggregated or calculated.

By default, the field values from linked issues will be read. If sub-tasks should also be taken into account, the corresponding additional option has to be checked.

Configuration

Target fields

Select the target fields that will be set and the source values for each of them. The following options are available:

OptionDescription
Copy field from selected issues

The value(s) found in the issues specified through the filters will be copied to the target field as a comma separated list.

Since you are copying the values of potentially multiple linked issues or sub-tasks JWT can aggregate values, and offers additional options depending on the type of source field.

Calculated values

For date and date-time fields you can additionally choose to only return the:

  • Earliest date value among those being returned.
  • Latest date value among those being returned.

For numeric fields you can automatically return the following aggregated values:

  • Sum of values: sum of all the values being returned.
  • Lowest value: minimum value among those being returned.
  • Highest value: maximum value among those being returned.
  • Average value: arithmetic mean of values being returned.

When updating the Priority field you can additionally choose to only return the:

  • Highest priority value among those being returned.
  • Lowest priority value among those being returned.
Set field value manually (parser expression)

Set the value of the target field using an expression and optionally use field codes. The Parsing modes differ depending on the data type of the target field. 

You can either choose from the Advanced text mode or the Numeric mode.

Clear field valueChoose this option to clear the value of the target field. This option is not available for the Summary field.

Check the write protection option if you want to prevent a field to be updated, if it already has a value. If checked, only empty fields will be set.


Filter

If you choose to further filter the issues the values will be copied from, all filter criteria will be "and concatenated".

Values will only be copied from issues meeting all criteria will be considered.

Filter by project

Optionally specify specific projects, the linked issues or sub-tasks) must or must not belong to. The following options are available:

OptionDescription

Any project

By default, the linked issues or sub-tasks can be in any project.

Current project

Choose this option to make sure that all linked issues or sub-tasks are in the same project as the current issue.

Any but current project

Choose this option to make sure that all linked issues or sub-tasks are not in the same project as the current issue.

Filter by issue link type

If you select specific link typesall linked issues must be linked using the selected types. If issues linked with other link types are found, the condition will fail.

This filter is mandatory. If you only want to copy values from sub-tasks, leave this filter blank and check the additional option "Include sub-tasks matching the specified filter criteria".


Filter by issue type

You can optionally filter the issues to copy the values from by issue types. If you select values all linked issues or sub-tasks must be of any of the selected issue types


Filter by status

You can optionally filter the issues to copy the values from by status. If you select values all linked issues or sub-tasks must be in any of the selected statuses


Filter by field value

Optionally limit the issues you want to copy values from by their field values. To achieve this you must enter an expression in Logical mode. The expression must return  true or false

Examples: 

ExpressionDescription
%{seed.issue.assignee} != null 

All issues must be assigned to a user. If unassigned sub-tasks are found, the condition will fail.

Values in linked issues or sub-tasks have to be referenced by their seed field codes.

%{issue.dueDate} <= %{seed.issue.dueDate}

All issues must have a due date of equal to or later than the current issue's due date.

Values in linked issues or sub-tasks have to be referenced by their seed field codes.

Additional options
OptionDescription

Include sub-tasks matching the specified filter criteria

Choose this option, if you want to also or only copy the values from sub-tasks. This option only makes sense when the current issue itself is not a sub-task.

This option or the next option must be checked, if you leave the link type filter blank.

Include sibling sub-tasks matching the specified filter criteria

Choose this option, if you additionally want to copy the values from siblings of the sub-tasks that match the filter criteria.

This option or the previous option must be checked, if you leave the link type filter blank.

Include recursively linked issues or sub-tasks matching the specified filter criteria

Recursively linked issues or sub-tasks (e.g. which are linked to a directly linked issue) will also be included independent of the linking depth.

Include current issue

The value of the current issue will be included in the output.

Update issue immediately
Choose to update issues immediately if you want Jira to fire a separate "Issue updated" event for any field change.  This will also result in a dedicated issue history entry.


Conditional execution

You can optionally specify a logical expression to define the circumstances (or conditions) under which the post function should be executed.

The result of the logical expression must return a boolean value of either:

  • true → the post function will be executed
  • false → the post function will not be executed

Using the conditional operator, even complex or multi-layered conditions can be constructed.

Make sure to learn more about defining logical expressions and browse through the various examples here: Logical mode

Run as

Select which user will be used to execute this post function. By default this parameter is set to the current user. You can also use field codes to run the function as a dynamic user (e.g. current assignee).

Make sure that the user running the post function has all the relevant permissions to perform the actions defined in the configuration (e.g. "Update Issues")!

If you want to keep track the actions being performed automatically, we suggest to create a dedicated JWT account, granted all relevant permissions, and use it in the Run as parameter to identify which changes have been made with JWT.



If you still have questions, feel free to refer to our support team.