Hello,
I'm using a script listener to make updates to a custom field on an Issue Update event. In order to do this I need the specific key to the issue from the event. I looked at documentation for event.issue. but don't see anything that says "key" or "id". What can I do here?
I use event.issue.key
event is an instance of IssueEvent
event.issue returns an issue object
And event.issue,key is a groovy shortcut for event.issue.getKey()
Colin -
When you say using a script listener are you meaning you are using an app like scriptrunner or power scripts to perform this?
If scriptrunner you should be able to use something like:
issue.getKey()
if Power Scripts you could use something like:
string[] fields;
fields = getIssueFields(key);
-Ed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you are using Script runner it should be
event.issue.key
Mike
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.