Uploaded image for project: 'SR for Jira - Development'
  1. SR for Jira - Development
  2. SRJIRA-1277

Show and hide a custom field based on another custom field

    Details

    • Type: Change
    • Status: Done
    • Priority: Blocker
    • Resolution: Support Request
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Critical Points:
      0

      Description

      I have a select list custom field A that has 3 values (a,b,c), if i select the b value from the custom field A, the custom field 2 (Radio buttons) must appear and if i select a or c, custom field 2 must disappear.

      I used this code :

      <script type="text/javascript">
      a= document.getElementById('customfield_10610');
      if (a) {
      billing = document.getElementById('customfield_10626').parentNode;
      if (a.value != 'b')) billing.style.display='none';

      a.onchange=function() {
      if (this.value == 'b')

      { billing.style.display = ''; }

      else

      { billing.style.display='none'; }

      }
      }
      </script>

      Could you please help ?
      Thanks

        Attachments

          Activity

            People

            Assignee:
            jechlin Jamie Echlin
            Reporter:
            nadim.jarjour Nadim
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: