How to hide a version picker custom field using javascript?


Can anyone please provide a sample of how to do this?


2 answers

This widget could not be displayed.

Why do you need Javascript to do it? You can do it in field configurations or take it off from the screens.

But if you must do it using Javascript, here is a snippet that will work for any custom field including version picker.


Where customfield id is 10000.

It is not working for me, not sure if it's because I am using Jira 5

I think I should specify few more things, I want to hide it even in view screen, here is my current code

<script type="text/javascript">

version = document.getElementById('customfield_10609');



if you want to hide the field in view screen just remove the field from view screen,

But I only want to hide it from certain users

The above code does it only for edit. Try Prasad's solution if you want to hide it from View as well.

This widget could not be displayed.
Try with following code

$("#customfield_10571").closest('div.field-group').hide(); $("#customfield_10571").closest('div.field-group').show();

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Posted Wednesday in New to Jira

Are you planning to trial, or are currently trialling Jira Software? - We want to talk to you!

Hello! I'm Rayen, a product manager at Atlassian. My team and I are working hard to improve the trial experience for Jira Software Cloud. We are interested in   talking to 20 people planning t...

135 views 2 0
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you