Approvers Report Assistance

Hey team,

Happy 2026.

I am presently challenged by creating a report to track the Tasks/Issues in Jira that have an Approver assigned.

In our Jira, we have a field in our Task form called Approvers. When I do a report using :

Page Filter

Approvers

Rows

Issues

I get a number of results, but when I filter on the “Approvers” I get issues that field Approvers is Blank, yet somehow they turn up in the report when I filter on an individual.

What am I doing wrong?

Thanks in advance for any advice.

Cheers

Dave

Hi @David_Horne

If this “Approvers” field is part of Jira Service Management features, you can try a slightly different approach.

Maybe you can define a new global calculated field, to import user who approved the ticket ( just replace customfield_xxxxx with the actual custom field ID from JIRA for the custom field “Approvals”) in new dimension to let you filter report by users who approved the tickets.

## New JSM approved by field ###
[jira.customfield_eazybiapprovers]
name = "Approved by"
data_type = "string"
multiple_values = true
split_by = ","
dimension = true
json_fields = ['customfield_xxxxx']
javascript_code = '''
if (issue.fields.customfield_xxxxx){
    var approvals = issue.fields.customfield_xxxxx;
    for(item of approvals){
        if(item.name == 'Waiting for approval' && item.finalDecision == 'approved'){
        var listofapprover = []
            for(user of item.approvers){
                if(user.approverDecision == 'approved'){
                    approver = user.approver.displayName;
                    listofapprover.push(approver)
                }
             
            } return listofapprover.join(", ")
        }
    }
}

'''

Then import this calculated field as a new dimension from the import options page.

If you don’t have access to define global calculated fields, you might want to check how to define them as account-specific calculated fields for your eazyBI account.

If this workaround doesn’t help, please reach out to support@eazybi.com and provide more details about your case, including your report screenshots, report definition and some information from your Jira Cloud site where we can see the field used in Jira

In addition to this calculated field, you can add two more calculated fields and import them as dimensions to let you filter tickets that have pending approval or were declined

Just don’t forget to update the code and replace the customfield_xxxxx with customfield_ID for the “Approvals” field.

### New JSM pending on field ###
[jira.customfield_eazybipendingaproval]
name = "Pending approval on"
data_type = "string"
multiple_values = true
split_by = ","
dimension = true
json_fields = ['customfield_xxxxx']
javascript_code = '''
if (issue.fields.customfield_xxxxx){
    var approvals = issue.fields.customfield_xxxxx;
    for(item of approvals){
        if(item.name == 'Waiting for approval' && item.finalDecision == 'pending'){
        var listofapprover = []
            for(user of item.approvers){
                if(user.approverDecision == 'pending'){
                    approver = user.approver.displayName;
                    listofapprover.push(approver)
                }
             
            } return listofapprover.join(", ")
        }
    }
}

'''

### New JSM declined on field ###
[jira.customfield_eazybideclinedaproval]
name = "Declined by"
data_type = "string"
multiple_values = true
split_by = ","
dimension = true
json_fields = ['customfield_xxxxx']
javascript_code = '''
if (issue.fields.customfield_xxxxx){
    var approvals = issue.fields.customfield_xxxxx;
    for(item of approvals){
        if(item.name == 'Waiting for approval' && item.finalDecision == 'declined'){
        var listofapprover = []
            for(user of item.approvers){
                if(user.approverDecision == 'declined'){
                    approver = user.approver.displayName;
                    listofapprover.push(approver)
                }
             
            } return listofapprover.join(", ")
        }
    }
}
'''

Martins / eazyBI support

@martins.vanags thanks for this, I’ll need to send to our Admins as I don’t have permissions to do this. :slight_smile: