Forums

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

Hide priority for all project roles exept Project Administrators

Klevis Dobra
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 29, 2022

Hello everyone, 

I would like to hide the system field 'Priority' for all the project roles exept for the Administrators. 

I need to have this also in a custom field called Priority (single select) but this is another task. 

I discovered that behaviors are not able to do this in a view screen so i can't use scriptrunner properly. 

Any idea how can i solve this problem 

Thank you very much 

2 answers

1 accepted

0 votes
Answer accepted
Max Foerster - K15t
Community Champion
July 29, 2022

Hey @Klevis Dobra, and welcome to the community!

We have two challenges here.

  • First, Jira is not offering anything like "field level security" as a feature.
  • Second, you are talking about a system field.

There are apps on the Atlassian Marketplace that offer this kind of configuration for custom fields, but right now, I don't think you will be able to implement something for a system field. Maybe others here have a solution, but I recommend trying to think about a workaround with a custom field. You can then go and hide it in the field configuration. Why do you want to hide it in the first place? 

Keep in mind how you want to deal with priorities regarding JQL. 🤔

Best, Max

Klevis Dobra
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 29, 2022

Hello Max , 

Thank you for your answer, 

Do you know any workaround for a custom field how can i make it visible in create/edit/view screen only for Project Administrators and hide it for all the other project Role? 

Thank's again 

Klevis 

Max Foerster - K15t
Community Champion
July 29, 2022

Hey @Klevis Dobra ,

Have a look at the marketplace. I did a little search on "field security," and a few products looked promising, offering permission management for custom fields very similar to permission schemes known from Jira. Maybe you give them a try.

Best, Max

0 votes
PD Sheehan
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.
July 29, 2022

If you want to stick with a strict behaviour/scriptrunner implementation, there is a slightly convoluted way to do it.

Keep in mind that nothing I'm about to offer will prevent non-admins from finding and viewing the field value either using the rest API or issue navigator. And even when hiding a field on an edit screen with behaviour, there is a chance the field will be visible for a second or two (especially if the user's CPU load is high)

1) Remove the field from the View screen. Keep it on the create/edit screens

2) Add a behaviour to conditionally (based on roles) hide the field on the create/edit screent

3) Create a custom scripted field that conditionally returns either null or the priority value if the user is a member of the admin role.

4) Add the customer scripted field to the view screen

This way, when viewing issues, admins will view the priority via that calculated field and non-admin will not see it.

And when creating/editing the issue, admins will see the normal priority field and be able to edit it. But non-admin will not see it.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events