How to change status colour based on resolution value

Ankuskum
Contributor
January 3, 2019

I want to changes my resolved status colour based on the resolution value.

Default colour is green.  If resolution is unsolved then colour should be different  

1 answer

1 accepted

0 votes
Answer accepted
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 4, 2019

That can't happen, directly.

The status colour is tied to the status, it has nothing to do with the resolution field.

In theory, you could actually write a script that changes the colour dynamically, so that when an issue changes from <no resolution> to <resolution set to something>, the colour of the status it is in changes, but that will give you massive problems, because the colour is part of the status, so ALL issues in that status will have their colour changed.  Which is going to be utterly wrong.

What you need to do is design your workflow with status and resolution being indirectly tied to each other.  Look at your workflow, and make sure each "ended" status is green, and the others are blue or yellow as appropriate.  Then set up the transitions in the workflow such that any going from a blue or yellow status to a green one set a resolution (either by putting it on a transition screen or setting it with a post-function), and any going from a green status to a blue or yellow one clears the resolution with a post-function.

Ankuskum
Contributor
January 4, 2019

Thank you for explanation, you have explained very well.

My requirement is to differentiate issues based on resolution values.

Like, we have different values in resolution field and my project manager want to differentiate based on the colour difference.

In epic section whenever we see all the issues linked to epic this shows Resolved issues green colour for all issues. This will not shows what was the resolution for Resolved tickets.

So here we want to differentiate or any option to add resolution in issue links column

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 4, 2019

Ok, your manager is not going to get that - the status colour belongs to status, not resolutions.

Two things I would look at:

  • Create a scripted field that looks at the resolution and decides on colour or flag that the PM can use - I would be tempted to have it show a short bit of text that can be searched and sorted on and formatted with colours too (using Scriptrunner or one of the others - I only use SR, so I can't speak for other scripting/automation apps)
  • With older versions of Jira, it was possible to make some minor changes to the .jsp file that renders the links section of an issue, which meant you could draw in other fields - this may be worth looking into again. 

I suspect the first option of a derived field will solve most of the problem though.

Ankuskum
Contributor
January 6, 2019

Hello @Nic Brough -Adaptavist-

Thank you for the suggestions.

I am also using script-runner only.

Let me try first option and try to solve this.

Thank you :)  

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events