Count transitions from unresolved to claim fix

Hello,

I need to count the resolution transitions from unresolved to claim fixed through time.

I tried with 2 calculated custom fields, for a solution similar to the one proposed by Martin here: Counting issues transitioned from specific assignees to another one

but it’s not working.

I can’t count on my client’s Jira admin, is there anyway this can be done?

Thank you

Marilou

Hi @Marilou

Please try adding this code to the advanced settings

[jira.customfield_restrans]
name = "Resolution transition"
data_type="string"
dimension=true
separate_table=true

[jira.customfield_res_chcnt]
name="Resolution change count"
data_type="integer"
measure=true
multiple_dimensions=["Resolution transition","Time"]
javascript_code='''
var result=[];
for (hist of issue.changelog.histories) {
  for (item of hist.items){
    if (item.field=="Resolution") {
        result.push((item.fromString?item.fromString:"") + " => " 
                     + (item.toString?item.toString:"") + ","
                     +   hist.created.substr(0,10) + ",1"
                     );
    }
  }
}
return result.join("\n");

Then make sure you select both custom fields “Resolution transition” and “Resolution change count” from the import optons page with all checkboxes.

One will create a dimension, another a measure.

Then you can use both in report with “Time” dimension to count specific resolution transitions

Martins / eazyBI

1 Like

I have Data Admin permission to the account, is this something I can do or do I need assistance from the Jira admin?

Thanks

I believe you can try defining them as account-specific calculated fields.

Just in that case, you need to carefully add additional advanced settings and JavaScript separately.

Martins / eazyBI

1 Like