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

Scriptrunner Summary and Description are empty

Hello everyone!

I am currently working on a Post Function after the transition of a Service Desk ticket.

When the transition happens, i have a script creating a new Issue in another project. It is the same issue type. The issue is created and the custom fields filled in the service desk are copied in the new issue.

However, the summary and description fields do not work.

The problem is issue.summary is null and issue.description is null.

post("/rest/api/2/issue")
.header("Content-Type", "application/json")
.body(
[
fields: [
summary : issue.summary,
description: issue.description
]
])
.asString()

 I have removed the other fields since they were working, to lighten the code.

Is there a reason why they are empty when I see them in the Service Desk?

 

2 answers

1 accepted

1 vote
Answer accepted

Found my problem. 

The information is in issue.fields.summary and issue.fields.description

If the issue is already created and you change the issue object after that, you have to update the issue manually. mylonestar

Maybe I was unclear. 

The Service Desk issue already exists, and when I transition it, I have a script to create a new issue in another project. The 'issue' instance refers to the Service Desk issue, and the summary and description fields are null.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
Community showcase
Published in Jira Service Management

JSM Jira Automation: How to Send SLA Breached Notifications

Hi Everyone, In   this tutorial,  we will show you how you can monitor an SLA, and send notifications before or after the SLA has been breached.   SLA Threshold Trigger The SLA t...

688 views 5 12
Read article

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