提交 c294ed8e 编写于 作者: D Daniel Beck

Merge pull request #1604 from daniel-beck/JENKINS-27414

[JENKINS-27414] Don't offer to restart if unsupported
......@@ -28,10 +28,17 @@ THE SOFTWARE.
<l:layout title="Restart Jenkins">
<st:include page="sidepanel.jelly" />
<l:main-panel>
<form method="post" action="restart">
${%Are you sure about restarting Jenkins?}
<f:submit value="${%Yes}" />
</form>
<j:choose>
<j:when test="${app.lifecycle.canRestart()}">
<form method="post" action="restart">
${%Are you sure about restarting Jenkins?}
<f:submit value="${%Yes}" />
</form>
</j:when>
<j:otherwise>
${%Jenkins cannot restart itself as currently configured.}
</j:otherwise>
</j:choose>
</l:main-panel>
</l:layout>
</j:jelly>
\ No newline at end of file
......@@ -28,10 +28,17 @@ THE SOFTWARE.
<l:layout title="Safely Restart Jenkins">
<st:include page="sidepanel.jelly" />
<l:main-panel>
<form method="post" action="safeRestart">
${%Are you sure about restarting Jenkins? Jenkins will restart once all running jobs are finished.}
<f:submit value="${%Yes}" />
</form>
<j:choose>
<j:when test="${app.lifecycle.canRestart()}">
<form method="post" action="safeRestart">
${%Are you sure about restarting Jenkins? Jenkins will restart once all running jobs are finished.}
<f:submit value="${%Yes}" />
</form>
</j:when>
<j:otherwise>
${%Jenkins cannot restart itself as currently configured.}
</j:otherwise>
</j:choose>
</l:main-panel>
</l:layout>
</j:jelly>
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册