Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Scripted-field where we can see the JQL-filter`s results

Hello!

We have a case, need an opportunity to easily get results of dynamic JQL-filter just in issue.

For example, the field where we can see links to unresolved issues of current reporter. 

On my screen - it is "Description".

The field should contain results of JQL-filter or Groovy script that will take values from the tasks, for example, || reporter = "current reporter" and resolution = unresolved ||image.png

The filter will be global for the field, but dynamic - in relation to the values from the issue.

This is just an example for explaining the problem.
The overall goal is to get a tool that allows you to add fields with filter results to issues.

Is it possible to make it using ScriptRunner`s custom fields?

Or maybe you know any another solutions? Maybe plugins?

 

Thanks for help!

3 answers

3 accepted

1 vote
Answer accepted

Hi,

it seems the nfeed-Plugin can solve your problem. With nfeed you can query your jira instance based on JQL- and SQL-queries and populate custom fields with the result set.

 

Andreas

Hi! Thank you for answer! It is really interesting solution! 

The main thing is that this plugin has great potential for use!

1 vote
Answer accepted

Hi Alexander, 

you can definitely do this with scriptrunner. 

For example, have a look here at Hennings response for JQL in a scriptfield 

https://community.atlassian.com/t5/Jira-questions/Script-Runner-Get-All-Issues-Logged-User-with-Status-quot-in/qaq-p/258287

You can use fields from your issue in the JQL query. 

You can use MarkupBuilder to make it look pretty.

My only issue is what happens when e.g. users add the script field to the issue navigator and the query gets applied to 10's of thousands of issues at the same time...

Hi! Thank you for answer! 

The guys from the Scriptrunner`s support team helped me to display the results of the JQL-filter in a custom field in a table form.

But I don`t know how using JQL-functions get issues of "reporter of current issue", not "currentUser()"?

The main task - Agent of service desk during processing should see all unresolved tasks from the current reporter - This will help speed up their decision or identify duplicate tasks.

Hi Alexander,

You could the reporter of the current issue like so;

def reporter = issue.reporter.getName() 

and then use $reporter in your jql; e.g. "reporter = $reporter AND resolution = empty"

Like Alexander Bondarev likes this

@Bob , thank you a lot! 

it works!

0 votes
Answer accepted

I also found another solution - a free plugin Related Issues, no need in writing scripts - just the JQL and the basic capabilities of the plugin are enough.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Posted in Jira Core

How to manage many similar workflows?

I have multiple projects that use variations of the same base workflow. The variations depend on the requirements of the project or issue type. The variations mostly come in the form of new statuses ...

3,873 views 11 5
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you