Skip to content

Commit

Permalink
Merge pull request #94 from jenkinsci/revert-85-Issue-Fix-#83
Browse files Browse the repository at this point in the history
Revert "Display message when next execution widget doesn't contains any executions"
  • Loading branch information
jonesbusy authored Feb 21, 2024
2 parents a4ecf45 + 146a832 commit f833440
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public List<NextBuilds> getBuilds() {
Jenkins j = Jenkins.getInstanceOrNull();

if (j == null) {
return null;
return nblist;

Check warning on line 74 in src/main/java/hudson/plugins/nextexecutions/NextExecutionsWidget.java

View check run for this annotation

ci.jenkins.io / Code Coverage

Not covered line

Line 74 is not covered by tests
}

DescriptorImpl d = (DescriptorImpl) (j.getDescriptorOrDie(NextBuilds.class));
Expand Down Expand Up @@ -129,10 +129,6 @@ else if (getShowParameterizedWidget()) {
return nblist;
}

public String getWidgetEmptyMessage() {
return Messages.NextExec_EmptyWidgetMessage();
}

public String getWidgetName() {
return Messages.NextExec_WidgetName();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
Format.Error=The date format pattern is not valid.
timeToGo=(in {0})
NextExec.WidgetName=Next Executions
NextExec.EmptyWidgetMessage=No next executions found
NextExecComputer.WidgetName=Next Executions tied to this agent
PossibleNextExec.WidgetName=Possible Next Executions
ParameterizedExec.WidgetName=Parameterized Next Executions
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,12 @@
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">
<j:if test="${it.showWidget()}">
<l:pane width="2" title="${it.widgetName}" id="${it.widgetId}">
<j:if test="${it.builds() == null}">
<j:forEach var="w" items="${it.builds}">
<tr>
<td class="pane">${it.widgetEmptyMessage}</td>
<td class="pane"><a tooltip="${w.name}" href="${w.url}">${w.name}</a></td>
<td class="pane" tooltip="${w.timeToGo}">${w.date}</td>
</tr>
</j:if>
<j:if test="${it.builds() != null}">
<j:forEach var="w" items="${it.builds}">
<tr>
<td class="pane"><a tooltip="${w.name}" href="${w.url}">${w.name}</a></td>
<td class="pane" tooltip="${w.timeToGo}">${w.date}</td>
</tr>
</j:forEach>
</j:if>
</j:forEach>
</l:pane>
</j:if>
</j:jelly>
Expand Down

0 comments on commit f833440

Please sign in to comment.