How to hide a custom field in issue view?

Yousif Al Rawahi April 17, 2024

Is there a way to hide a custom field in issue view, using scriptrunner?

2 answers

0 votes
Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 18, 2024

Hi @Yousif Al Rawahi

Only certain fields are supported on the issue view screen and you can see which ones are supported in the documentation page here.

If your field is a user picker field which it looks from the name then this is not supported on the Issue View screen whcih means it cant be hidden.

I hope this information helps.

Regards,

Kristian

0 votes
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 17, 2024

Hi Yousif, 

You would need the ScriptRunner Behaviours app. 

Matt Parks
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 Leaders.
April 17, 2024

It's my understanding that a Behavior can only hide fields on the Create, Edit, or transitions screens, but not the View screen. Has this changed recently? And is the behavior different between the Cloud and DC versions of ScriptRunner?

Yousif Al Rawahi April 17, 2024
I have used this script, but it didn't work as I wanted, nothing happened.
// Insert the jira UI modifications API script for the behaviour
const staffnameField = getFieldById("customfield_11638");

staffnameField.setVisible(false);
I thought it will work on view screen using scriptrunner. Is there any other way to hide it on view screen?
Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 18, 2024

@Matt Parks - Behaviours are different in Jira Cloud and only work on the Create and Issue Views, however in cloud the issue view is the edit screen that DC has.

Regards,

Kristian

Like John Funk likes this
Matt Parks
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 Leaders.
April 18, 2024

Is the method to hide a field different in Cloud than DC? In DC, it's setHidden(true) or setHidden(false), as opposed to setVisible()

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events