Versions Compared

Key

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

...

Tip
titleWhy on Earth would I need something like this?

A typical use for this workflow condition is when you can reach a certain Status from several other Statuses (through the same Transition) and want to be able to return to the originating Status.
Consider the following partial workflow :

JIRA will allow you to create a single Transition from both Open and In Progress statuses to the Waiting for clarification status. But how do you create the transition (Provide info) back to Open and In Progress? And, more importantly, how do you make sure the issue is transitioned back to the originating status?
Here's the trick:

  1. create two Provide info transitions, one from Waiting for clarification to Open, and another from Waiting for clarification to In Progress (just add a space at the end of the name of one of the two transitions so that JIRA doesn't complain about duplicate transition names).
  2. on the first transition, add a Previous Status Condition to make the transition available only if the previous status was Open (don't forget to check the "Most recent status only" checkbox).
  3. on the second transition, add a Previous Status Condition to make the transition available only if the previous status was In Progress (don't forget to check the "Most recent status only" checkbox).

And voilà! Your users will see only one transition from the Waiting for clarification status, and it will transition the ticket back to the originating status.

Note that you could also use an advanced feature of JIRA that allows you to define "conditional-result" elements in the XML definition of a transition, but you need to edit the workflow XML and this is definitely not for the faint of heart.

You can also restore the previous Assignee by saving it in a custom field during the Request clarification transition and then restoring it during the Provide info transition (see Copy Value From Other Field workflow function in JIRA Suite Utilities). Alternatively, you can use the Assign to last role member function described below to assign the issue to the last user in the Users role.

...

A workflow condition that enforces separation of duties (for SAS-70 70  compliance), i.e. that makes sure the same user cannot trigger two incompatible transitions on the same issue.
For example, you can prevent a user who has triggered the "Resolve Issue" transition on an issue to trigger the "Close" issue.

...

A workflow validator that ensures that the current issue's parent issue is in one of the specified Statuses. This is useful only for sub-tasks.

Anchor
functions
functions
Post-functions

Note
titleUsing Post-functions in the _Create_ transition

If you insert a Post-function in the Create transition, you must make sure that you move it down to after the Creates the issue originally built-in function.

Assign to role member (new in 1.2)

...

This can be used for scenarios like: "when a developer resolves the issue, assign the issue to the QA lead".

The Skip if Assignee option allows you to prevent the automatic assignation to the role member if the user specifies an explicit Assignee in the workflow screen.

Assign to last role member (new in 1.2) (updated in 1.5.1)

...

This can be used for scenarios like: "when QA fails assign the issue to the last developer who worked on it".

The Skip if Assignee option allows you to prevent the automatic assignation to the last role member if the user specifies an explicit Assignee in the workflow screen.

Increase value of field Function

...

A workflow function that sets a field to the value of a User Property.

A typical use is to store the country, or department, or other such information, of the Reporter of an issue into the issue itself (so that it can be displayed, searched, or used by the workflow).

When setting the Issue Security field, the user property must contain the numerical id of the Issue Security Level, which you can find by looking at the links associated with the Add/Default/Delete operations on the desired Security Level (on the Edit Issue Security Levels screen).

Copy Field Value to Parent Function (new in 1.3.2)

...