Is there any plugin for customizing resolutions based on the issue type?

Bharadwaj Jannu
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.
December 26, 2012

The requirement is :

I have some resolution field values.(Fix,Won't Fix,Duplicate,Cannot Complete,..)

I need to customize them based on the issue type

i.e.for Bug Issue Type(only Fix,Won't Fix) and for Task Issue Type(only Duplicate,Fix) and so on.

so is there any way to meet such requirement without plugin or using any plugin?

2 answers

1 accepted

0 votes
Answer accepted
dleng
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.
December 26, 2012

This has been asked already here: https://answers.atlassian.com/questions/30696/different-resolution-options-according-to-issue-type

do check out some of the comments for workarounds. (as of now this is not officially supported in JIRA)

0 votes
Mizan
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.
December 26, 2012

Does each issue type has a separate workflow ? If yes you can easily add a workflow property on the transition which will set the resolution .

IF No , then you will need set the resolution based on issue type , there might be other good ways of doing this but i would have used the Behaviours plugin (since i am more comfortable using it)

You will need to add a behaviour to the resolution field which will check for the issuetype and set the resolution accordingly (You will need to write a groovy script for this)

Renjith Pillai
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.
December 27, 2012
Bharadwaj Jannu
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.
December 27, 2012

Thanks Mizan

I don't understand how exactly Behaviors plugin works in JIRA 5.2.1

Could you briefly describe about it.

Bharadwaj Jannu
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.
December 27, 2012

Yes I read, but where is the add behavior option in Field Configuration Scheme?

Renjith Pillai
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.
December 27, 2012

It's not inside 'Field Configuration Scheme'

Copy paste from doc:

Create a new Behaviour. Go the Administration sceen, and click the Behaviours link, in the Schemes section.

Or press gg and type behaviours, you should get it.

Mizan
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.
December 27, 2012

The behaviours plugin allows an administrator to create one more or behaviours. A behaviour defines how fields(In your case the Resolution field) behave for issues in a given project/issue context.

Install this plugin in your test instance and go through the groovy examples given in the documentation .

You will need to show the issuetype field in the resolution screen then based on the value of issuetype you will need to set the resolution field .

Bharadwaj Jannu
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.
December 27, 2012

Hello Mizan, I got your point and issue type field is placed on the Resolve Issue Screen as you said.

Now, using behaviours plugin how to customize resolutions based on issue type.

Mizan
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.
December 27, 2012

Add a behaviour then add a mapping to this behaviour then add the resolution field in this behaviour .

Now you will need to write a groovy script and add it .

You script will be something like below (just for reference)

import com.onresolve.jira.groovy.user.FieldBehaviours
import com.onresolve.jira.groovy.user.FormField

FormField issueType = getFieldById("issuetype")
FormField resolutionField = getFieldByName("resolution")

if(issueType.getFormValue().equals("Bug"))
{
resolutionField.setFormValue(1)
}

if(issueType.getFormValue().equals("Task"))
{
resolutionField.setFormValue(2)
}

Suggest an answer

Log in or Sign up to answer