Hi,
You can use the following to retrieve the status name:
issue.getStatusObject().getName()
If you define a scripted field, you can quickly test such a condition with a specified issue key.
Kind regards,
Geert
Hi @Geert Graat,
Thanks for the response. I'm still a little unsure how to get this working properly. I've input the following now for the condition. Do I need to specify the issue key for getStatusObject()? Also, do I need to specify anything in the brackets for getName?
issue.getStatusObject().getName() == 'Approved-Company Car'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
issue.getStatusObject().getName() is exactly the same as issue.statusObject.name You don't specify any key because you have the issue in the "issue" variable...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Jamie Echlin [Adaptavist] Thanks, Jamie. Makes sense. It's still not working for me with condition= issue.statusObject.name == 'Approved-Company Car' This is a custom status I created. I tried removing the space between "company" and "car" to see if that would work... still nothing. I'm out of ideas now.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
maybe you have a trailing space or something on your status name. Is the condition tester there? If so try: assert issue.statusObject.name == 'Approved-Company Car' (just to test) and post the output.
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.