Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Hi Community ,Can you please help me on ,how to add dynamic value in Scriptrunner JQL

cgadade
Contributor
May 18, 2020

My Req is ,

   I want to get existing assigned issues using JQL in scriptrunner for that I am using following code but my requirement is ,I want to store user in 1 custom field and want to pass that custom field to my JQL like below ,I am adding it but my code is not working ,Can anyone help me on priority basis or do we help me with another available code to do the same.Thanks in advance .

 

Collection<ApplicationUser> users= ComponentAccessor.getGroupManager().getUsersInGroup("AVO-support_Team")
def groupUsers = users.collect {
def userName =it.getUsername();

//First user
def query = jqlQueryParser.parseQuery('project = "BRD" AND (issuetype = "Incident" || issuetype = "Service Request") AND assignee in (userName)');

}

0 answers

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events