How can i have multiple types of "blocked" with in a project? And track lenth of time blocked?

LIndsay Kiefer November 22, 2019

For my project i have the need to have multiple different types of block i.e. "vendor blocked" "user blocked" "facilities blocked" etc. Currently We use labels to identify each type of blocked with one status that they move into in a single column.

From a Project management prospective i would like to know the length of time each one of these items is blocked.

The only way Jira will track is time in status. And this does not accumulate on how many times the issue became blocked. ( we use aresenal data plane which is not very helpful)

I want to be able to track this with out having to have 15+ "blocked" status to move into and out of making a very messy workflow.

Is there another way via JQL or script runner etc. If so can you give me an example of your solution.

1 answer

0 votes
Tuncay Senturk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 22, 2019

Hi @LIndsay Kiefer 

I do not think that there is a Jql solution for this, at least you can't get both duration and count using Jql. 

You can write your own script to count how many times issue gets in a status, and calculate time in that status. For instance status counter would be as below. (please bear in mind that I did not test the code).

int statusId = xxx; // where xxx is the status ID of the status that you want to count
List<ChangeItemBean> changeItems = changeHistoryManager.getChangeItemsForField(issue, IssueFieldConstants.STATUS);
int counter = 0;
for(ChangeItemBean changeItem: changeItems) {
if (statusId == Integer.parseInt(changeItem.getTo()) {
counter++;
}
}
return counter;

On the other hand, (as being one of the folks behind Snapbytes), I can introduce commonly used Enhancer Plugin's solutions, for both problems.

Also you can find other solutions but I don't know other app which solves both issues except Script Runner and Enhancer.

I hope it helps

LIndsay Kiefer December 5, 2019

Thank you for the response. I will go test this out and see if it works for what i need.

Tuncay Senturk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 5, 2019

Please don't stuck in the code if it does not run as expected. As I mentioned before I did not test it.

But I'll be here to assist if you need.

Suggest an answer

Log in or Sign up to answer