Forums

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

ScriptRunner CustomerRequestQuery$Builder.issue() problem

Michał Ezman July 19, 2019

Hi,
I have this code in Post Functions

 

CustomerRequestQuery customerRequestQuery = CustomerRequestQuery.Builder.issue(issue.id).build()
CustomerRequest customerRequest = ServiceDeskCustomerRequestService.getCustomerRequests(userManager.getUserByName("jira"), customerRequestQuery)right.results[0]
RequestParticipantUpdateParameters requestParticipantUpdateParameters = RequestParticipantUpdateParameters.Builder.customerRequest(customerRequest).build()

//And later in code:
RequestParticipantService.addRequestParticipants(user, requestParticipantUpdateParameters)

 And I have no errors in editor, I've got all needed imports. But when I made issue which use this post function, I got error (in logs):

2019-07-19 11:46:05,856 ERROR [workflow.ScriptWorkflowFunction]: *************************************************************************************
2019-07-19 11:46:05,856 ERROR [workflow.ScriptWorkflowFunction]: Script function failed on issue: IT-14477, actionId: 1, file: <inline script>
groovy.lang.MissingMethodException: No signature of method: static com.atlassian.servicedesk.api.request.CustomerRequestQuery$Builder.issue() is applicable for argument types: (java.lang.Long) values: [154533]
Possible solutions: use([Ljava.lang.Object;), isCase(java.lang.Object), is(java.lang.Object), sleep(long), inspect(), use(java.lang.Class, groovy.lang.Closure)
	at Script777.run(Script777.groovy:53)

 

Do anybody have idea how to fix it?

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, loom, loom for training, loom for teaching, video training, async learning, online education, screen recording, loom tutorials, loom use cases, atlassian learning, team training tools, instructional video, virtual training tools

🛗 Elevate Your Training and Enablement with Loom

Join us June 26, 11am PT for a webinar with Atlassian Champion Robert Hean & Loom’s Brittany Soinski. Hear tips, stories, and get your burning questions answered. Learn how Loom makes training and enablement easier. Don’t miss it!

Register today
AUG Leaders

Atlassian Community Events