On this page:

How to hide transitions based on the Didit checklist metadata field

Permissions warning

You must have Jira admin permission in order to add a validator to a Jira workflow. If you do not have Jira admin permission, request assistance from the Jira admin of your instance. Please keep in mind the general best practices when editing Jira workflows. This workflow could be shared with other projects, try to be aware of how many projects you are changing.

This page shows you how to set up a condition in a Jira workflow to hide a transition based on the Didit metadata field. You can make certain text required in a checklist’s metadata in order to transition to a certain status.

This checklist metadata condition works well if you have a workflow that only requires certain steps if certain criteria within the checklist metadata are set. One example of this is in an onboarding workflow and checklist. If there is a repository access provisioning status you may only need it for people with an engineering role, so you could hide the transition for other roles. In our first example below we hide the transition to “Server admin access” to only checklists with the Job title set to “IT Admin.” You could also use this condition if you simply wanted the metadata field to be populated. For this see the second example below.

Job title metadata field required to equal IT Admin

  1. A Jira project with the project settings highlighted.
    A Jira project with the project settings highlighted.
  2. Go to the “Workflows” on the left side and click the pencil icon to edit the workflow.

    The workflow project settings with an arrow to the pencil to edit the icon.
    The workflow project settings with an arrow to the pencil to edit the icon.
  3. In the diagram view, click the transition you would like to hide.

    A workflow with an arrow to the target transition.
    A workflow with an arrow to the target transition.
  4. Select “Conditions” from the options.

    The workflow with a transition selected and an arrow to the conditions option.
    The workflow with a transition selected and an arrow to the conditions option.
  5. Click “Add condition.”

    The conditions screen with the add condition option selected.
    The conditions screen with the add condition option selected.
  6. Choose the condition “Value field” from the list and click “Add.”

    The value field condition selected.
    The value field condition selected.
  7. Choose the “Didit metadata” field.

    The value field condition editor with the field set to Didit metadata.
    The value field condition editor with the field set to Didit metadata.
  8. Choose ”=” as the qualifier for the condition.

    The value field condition editor with the condition set to equals.
    The value field condition editor with the condition set to equals.
  9. Finally, type the metadata value that you would like the Didit metadata field to be in order to show the transition. Remember, the Didit metadata field stores the metadata field name and the value, so your text will need to have both. In our example, we are using the “Job title” metadata, so our Value will say “Job title: IT Admin”. For the comparison type, choose “string” and click “Add.”

    The value field condition editor with the value and comparison type options highlighted.
    The value field condition editor with the value and comparison type options highlighted.
  10. Publish the draft to apply the changes and make them effective. If you think you may want to revert the change, you can always save a backup copy.

    The condition added with the publish draft button highlighted.
    The condition added with the publish draft button highlighted.
  11. Now, the transition will only show in the workflow if the Job title metadata has the value “IT Admin.”

    The condition in action.
    The condition in action.

Metadata is not empty

Follow steps 1-7 as above. When you get to step 8 choose ”!=” as the qualifier for the condition. Leave the “Value” field empty for step 9.

Metadata field empty condition.
Metadata field empty condition.

Then, follow steps 10 and 11 as above. This will hide the transition unless the Metadata field in your checklist is populated.

You can use these same methods for any status and any transition in a company managed project.

Short link to this page: https://seibert.biz/diditmetadatacondition