Hello,
I need to hide or not a "date and hour" field, I try the JS function (http://confluence.atlassian.com/display/JIRA/Displaying+a+Field+Based+on+Another+Field+Selection), but it only hide the text area and not the label and the datepicker.
A schema to explain what I have (left side) and what I need (right side) :
JS code :
<script type="text/javascript"> source = document.getElementById('customfield_10600'); if (source) { target = document.getElementById('customfield_10601'); if (source.value == 'Oui') target.style.display='none'; source.onchange=function() { if (this.value == 'Oui') { target.style.display = ''; } else { target.style.display='none'; } } } </script>
Hi, take the parent ot an element with id="customfield_10601", should be some <div/> and disable it.
YEAH !
Just need to modify the target :
target = document.getElementById('customfield_10601').parentNode;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.