[JIRA] (JENKINS-33326) Programmatic changes to Reactive Reference value do not cascade
Title: Message Title Bruno P. Kinoshita closed an issue as Not A Defect Closed as not a defect Jenkins / JENKINS-33326 Programmatic changes to Reactive Reference value do not cascade Change By: Bruno P. Kinoshita Status: Resolved Closed Add Comment This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c) -- You received this message because you are subscribed to the Google Groups "Jenkins Issues" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[JIRA] (JENKINS-33326) Programmatic changes to Reactive Reference value do not cascade
Title: Message Title Ioannis Moutsatsos resolved as Not A Defect We are providing a reasonable workaround but this is probably not a bug in the first place, but rather the expected behavior. After a programmatic value change we have to* trigger an on change event* for the new values to cascade to other AC parameters that reference the original parameter. Jenkins / JENKINS-33326 Programmatic changes to Reactive Reference value do not cascade Change By: Ioannis Moutsatsos Status: Open Resolved Resolution: Not A Defect Add Comment This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c) -- You
[JIRA] (JENKINS-33326) Programmatic changes to Reactive Reference value do not cascade
Title: Message Title Ioannis Moutsatsos commented on JENKINS-33326 Re: Programmatic changes to Reactive Reference value do not cascade So what Bruno P. Kinoshita suggested works. Thanks! However, the programmatic update of an Active Choice parameter via _javascript_ suffers from the luck of a stable parameter element identifier. Every time the configuration is updated the div id changes. Preferably, we will generate a stable element id for the formatted HTML element that the AC parameter generates and then use it to get the AC parameter ID dynamically. So, if we provide each of the input boxes generated from ACRR_1 and ACRR_2 (referencing ACRR_1) in the example above an id lets say id1, id2 respectively, we can use the following pattern: document.getElementById("id1").value = 'InputBox1_Value'; //now get the Active-Choice Reactive Reference ID programmatically-avoids luck of stable ID issue parentId=document.getElementById("id1").parentNode.id //the next line triggers an update to the ACRR_2 jQuery('#'+parentId).trigger('change') This strategy allows one to use _javascript_ to update Active Choice parameters and cascade these changes to other AC parameters that reference them. Add Comment This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c) -- You received this message because you are subscribed to the Google Groups "Jenkins