Skip to content

Commit

Permalink
[FIXED JENKINS-23191] f:radio is not databinding-aware and does not c…
Browse files Browse the repository at this point in the history
…orrectly handle multiple configuration sections unless you make it.

(cherry picked from commit d660d60)

Conflicts:
	changelog.html
  • Loading branch information
jglick authored and olivergondza committed Jul 3, 2014
1 parent 84195ea commit bd378a1
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
Expand Up @@ -32,15 +32,15 @@ THE SOFTWARE.
</f:entry>
<j:if test="${descriptor.showEvenIfUnstableOption(targetType)}"> <!-- TODO JENKINS-16444 this will always be true when first adding step -->
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold==null || instance.threshold.toString()=='SUCCESS'}"
<f:radio name="BuildTrigger.threshold" checked="${instance.threshold==null || instance.threshold.toString()=='SUCCESS'}"
title="${%Trigger only if build is stable}" value="SUCCESS"/>
</f:entry>
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold.toString()=='UNSTABLE'}"
<f:radio name="BuildTrigger.threshold" checked="${instance.threshold.toString()=='UNSTABLE'}"
title="${%Trigger even if the build is unstable}" value="UNSTABLE"/>
</f:entry>
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold.toString()=='FAILURE'}"
<f:radio name="BuildTrigger.threshold" checked="${instance.threshold.toString()=='FAILURE'}"
title="${%Trigger even if the build fails}" value="FAILURE"/>
</f:entry>
</j:if>
Expand Down
Expand Up @@ -29,15 +29,15 @@ THE SOFTWARE.
<f:textbox autoCompleteDelimChar=","/>
</f:entry>
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold==null || instance.threshold.toString()=='SUCCESS'}"
<f:radio name="ReverseBuildTrigger.threshold" checked="${instance.threshold==null || instance.threshold.toString()=='SUCCESS'}"
title="${%Trigger only if build is stable}" value="SUCCESS"/>
</f:entry>
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold.toString()=='UNSTABLE'}"
<f:radio name="ReverseBuildTrigger.threshold" checked="${instance.threshold.toString()=='UNSTABLE'}"
title="${%Trigger even if the build is unstable}" value="UNSTABLE"/>
</f:entry>
<f:entry title="">
<f:radio name="threshold" checked="${instance.threshold.toString()=='FAILURE'}"
<f:radio name="ReverseBuildTrigger.threshold" checked="${instance.threshold.toString()=='FAILURE'}"
title="${%Trigger even if the build fails}" value="FAILURE"/>
</f:entry>
</j:jelly>
1 change: 1 addition & 0 deletions core/src/main/resources/lib/form/radio.jelly
Expand Up @@ -29,6 +29,7 @@ THE SOFTWARE.

Note that safari doesn't support onchange.

Beware that the name attribute should be uniquified among all radio blocks on the page, such as by prefixing it with "G0025." or whatever gensym.
<st:attribute name="name" />
<st:attribute name="checked" />
<st:attribute name="value" />
Expand Down

0 comments on commit bd378a1

Please sign in to comment.