The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

Get Issue Status in a Behaviour

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
December 27, 2017

So, I'm somewhat new to ScriptRunner. I'm liking it though. Especially the behaviours section. I'm currently trying to write an initializer that would hide/show certain fields on the issue edit screen based on the current status in the workflow. It it possible to get the current status of an issue in a behaviour? Thanks.

3 answers

1 accepted

Suggest an answer

Log in or Sign up to answer
12 votes
Answer accepted
Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
December 27, 2017

Ok. I figured it out!!

underlyingIssue.getStatus().name
Jose Luis Casarrubias
June 19, 2020

it worked like a charm! 

Thank you!

Siva Kumar Veerla
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 16, 2021

Hi Davin,

It worked for me as well. where did you find 

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
July 16, 2021
Like • Dirk Ronsmans likes this
0 votes
Ben van den Berg
Contributor
March 16, 2024

Thanks, @Davin Studer. This seems to pertain to the Data Center / On-prem platform.
Do you or anyone else have any idea how to get the status on the Jira Cloud platform?

0 votes
Deleted user
August 29, 2023

Could you please share your code?

TAGS
AUG Leaders

Atlassian Community Events