Skip to content

Commit

Permalink
[JENKINS-69489] - Hide restart checkbox if the controller doesn't sup…
Browse files Browse the repository at this point in the history
…port it (jenkinsci#7740)

[JENKINS-69489] Hide restart checkbox if the controller doesn't support it

(cherry picked from commit 1f382cb)
  • Loading branch information
NotMyFault authored and krisstern committed Apr 18, 2023
1 parent 91ff00c commit 67a2388
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions core/src/main/resources/hudson/model/UpdateCenter/body.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -49,18 +49,15 @@ THE SOFTWARE.
<l:icon class="icon-red icon-md"/>
<l:icon class="icon-nobuilt icon-md"/>
</div>
<p class="info jenkins-checkbox" style="font-weight: normal">
<p class="info">
<j:if test="${app.lifecycle.canRestart()}">
<j:if test="${app.isQuietingDown() or it.isRestartScheduled()}">
<input id="scheduleRestartCheckbox" type="checkbox" checked="checked" />
<f:checkbox checked="true" id="scheduleRestartCheckbox" name="scheduleRestart" title="${%warning}" />
</j:if>
<j:if test="${!app.isQuietingDown() and !it.isRestartScheduled()}">
<input id="scheduleRestartCheckbox" type="checkbox" />
<f:checkbox readonly="true" id="scheduleRestartCheckbox" name="scheduleRestart" title="${%warning}" />
</j:if>
</j:if>
<label for="scheduleRestartCheckbox">
${%warning}
</label>
</p>
</l:isAdmin>
</form>
Expand Down

0 comments on commit 67a2388

Please sign in to comment.