Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Incremental counter on transition to itself

harshal patel
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 19, 2020

I am creating advanced workflow which contains exams and retest if failed. I need a number of attempt counter on transition back to itself aka (Retest in my case). Below is an example of what it looks like. Any help would be much appreciated! 

Addons - JSU and Automation for Jira 

Capture.PNG

1 answer

2 votes
Sam Harding
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 29, 2020

Hi,

I think a possible solution here would be to add a custom field to your Issues. You can add a 'Number Field' as a custom field, call it a name like 'Retest Count', then in Automation for Jira, you can have it set up to:
1. Trigger on 'Issue Transitioned' from 'Testing' to 'Retest'
2. 'Edit Issue', fields to set: 'Retest Count', and for the value, set it to the smart value:

{{#=}}{{issue.customfield_XXX}} + 1{{/}}

Where XXX is the field id of 'Retest Count'. The field id can be found by going to 'Edit details' of the custom field, and observing the last section of the browser's url. More details can be found here https://community.atlassian.com/t5/Jira-questions/To-find-the-Custom-Field-id-for-a-particular-custom-field/qaq-p/243305

Hope that helps!

Suggest an answer

Log in or Sign up to answer