Versions Compared

Key

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


 

Info
iconfalse

You must have the JIRA Jira System Administrators global permission before you can carry out the instructions on this page.

 


Info
iconfalse

The Conditional Rules Administration screen let you setup expression able to create Conditions that you can apply on: 

  • Approval Mappings and Single Issue Approval configurations, in order to
    • require the approvals, only if the condition returns true
    • let transition the issue if the condition returns true depending by the number of approbations or rejections
    • enable one, more Super Approvers when the conditional expression, evaluated for an issue, returns true
  • Approval E-mail Templates, in order to
    • send emails
    with
    • having high priority
    high
    • when the condition returns
    true.
    • true 
    • enable the usage of a given template for the Approval Request or Reply Emails when the condition returns true  (New with Version 4.41)
  • Approvals , in order to
    • enable the Approval when the conditional expression, evaluated for an issue, returns true
    • enable one, more Properties allowing to populate the selected user picker custom field when the conditional expression, evaluated for an issue, returns true

Notice that you can reuse a Conditional Rule across different Approval Mappings, Single Issue Approval and, Approval E-mail Templates and Approvals.

Info
iconfalse

Table of Contents

Overview

The Conditional Rules Administration screen looks like as follows:

The Conditional Rules Administration screen allows you to add, edit, delete and review your  Conditional Rule configurations.

Furthermore, when moving the mouse upon the data under the Assigned Approval, Assigned Template, Assigned Mapping, Assigned Issues columns , a window, detailing when the Conditional Rule is applied, shows up.

Image Removed

Image Removed

Image RemovedImage Added

Preliminary setup

Before you can create Conditional Rules, you must set up Conditional Rule Main Settings.

  1. Click Main Settings on the top of the Conditional Rules Administration screen.
  2. On the Conditional Rule Settings screen, fill the User field  with an username that the add-on can you must select the user that the app will use to evaluate the conditional ruleConditional rule .

    Info

    When updating the selected On selecting a different user, the add-on remove the update the permissions the app grants the permissions to the new user and revokes the permissions to the previous user accordingly.

    Image Removed

    The add-on will  grant the selected user browsing privileges on any project. Image Added

    By default, the app grants browsing permissions on all Jira Projects to the selected user.

    You can choose to disable this automatism by turning Off the Grant Browsing Permissions Automatically option.

 

How to create a Conditional Rule

  1. Click Add Conditional Rule to create a new Conditional Rule

  2. Fill the fields  showing up on the Conditional Rule Configuration screen
     
     
    1. Rule Name (Required, Not editable)
    2. Conditional Rule (Required), the fields expects a valid structured queries using the JIRA Jira Query Language (JQL) 
    3. User used to evaluate the conditional rule
      1. chose choose the option Super User, if you want that the Conditional Rule is evaluated via the credential of the user selected on the Conditional Rule Main Settings (Default)

      2. chose choose the option Current User, if you want that the Conditional Rule is evaluated via the logged user credentials

      3. chose choose the option Reporter, if you want that the Conditional Rule is evaluated via the reporter credentials
      4. chose choose the option Assignee, if you want that the Conditional Rule is evaluated via the assignee credentials
      5. chose choose the option Project Lead, if you want that the Conditional Rule is evaluated via the project lead credentials
      6. select a single user picker custom field, if you want that the Conditional Rule is evaluated via the user selected on the selected user picker Custom Field.

        Info
        iconfalse

        You can choose only one of the options listed above.

    Click the hand lens to to validate JQL syntax.  A window let you know if the Conditional Rule is valid.
    Image Removed
      1. Warning

        If the selected User used to evaluate the conditional rule is null (e.g. reporter= Anonymous, assignee=Unassigned, current user =null, user selected on the user picker Custom Field=null) the condition will return false.

  3. Click Save.  

Editing a Conditional Rule

You are able to update an existing Conditional Rule.

The majority of the filled fields can be updated, exception made for the Rule Name. 

Deleting a Conditional Rule 

When deleting a Conditional Rule not yet associated to any any Approval, Approval Mapping, Single Issue Approval configuration or email Template, the application doesn't ask to confirm.

If in any configuration, requiring the Conditional Rule existsRule, exists,  the the application asks to confirm the deletion of the Conditional Rule.

Validity of the Conditional Rule expression

Overview

Conditional Rule validity  is based on the following variables:

  • validity of the user selected on the Conditional Rule Main Settings 
  • validity of the Conditional Rule expression.

This section illustrates which changes have impact on Conditional Rule validity and how you can fix them. 

Notice that when a conditional rule is retrieved invalid the condition is assumed as not set and the user is alerted as showed on the following screenshot:

Image Added 

Validity of the user selected on the Conditional Rule Main Settings 

 

In order to evaluate a Conditional Rule via the credential of the user selected on the Conditional Rule Main Settings, the selected user needs Browsing permission on the Project using the Conditional Rule.

 

Changes having impact on user validity  and the correct way to restore Conditional rule validity are listed below:

 

  • user is deactivated 

    Info
    iconfalse
    titleSolution

    Upgrade  the Conditional Rule Main Settings by selecting a different user.

  • username is updated 

    Info

    When updating the selected user, the app automatically grants the selected user of the Browsing permission on all Projects.

  • user is deleted  

    Info
    iconfalse
    titleSolution

    Upgrade  the Conditional Rule Main Settings by selecting a different user.


  • user has no Browsing permission on a new Permission Schema

    Info
    iconfalse
    titleSolution

    You have two options: manually grants the user of the Browsing permission or just navigates the Conditional Rule Main Settings and click Save.

Validity of the Conditional Rule expression

The Conditional rule expression expects a query using the Jira Query Language (JQL) sintax.

When creating or updating a Conditional rule expression the JQL check button confirms the validity of the expression.

Image Added

You are able to save valid Conditional Rules exclusively.