🚀 JWT 3.0 is out 🚀 

The app was completely overhauled, and so was the documentation: Jira Workflow Toolbox (Server/Data Center) Home

The page you are viewing is still valid for all app versions prior to 3.0.

On this page


Features used to implement the example



Example: Set security level depending on reporter or creator

I want to set the Issue Security in the workflow based on the user who creates the issue.

Example:

  • User belongs to "Group A" set "Security Level A".
  • User belongs to "Group B" set "Security Level B".

This behavior can be implemented using post-function Set a field as a function of other fields with the following configuration:


Note that:

  • %{00006} is field code for Reporter
  • You could also use field Creator (field code %{00148}) instead, which is the actual user who created the issue, Field Reporter can be edited, while Creator can't
  • You could use function "isInRole(string user_name,string role_namestring project_key) : boolean" to make it dependent on project role. You should use field Project Key (field code %{00018}) in the third argument

Once configured, the transition will look like this:





Other examples of that function