Skip to content

Commit

Permalink
[JENKINS-24436] Use rootUrl rather that jobBaseUrl when linking to jo…
Browse files Browse the repository at this point in the history
…b results.
  • Loading branch information
uhafner committed Oct 25, 2014
1 parent 7fd072e commit 1a89911
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/main/java/hudson/plugins/cobertura/CoverageColumn.java
Expand Up @@ -49,7 +49,7 @@ public String getUrl(final Job<?, ?> project) {
return null;
}
else {
return action.getUrlName();
return project.getUrl() + action.getUrlName();
}
}

Expand Down
Expand Up @@ -5,7 +5,7 @@
${it.getCoverage(job)}
</j:if>
<j:if test="${it.hasUrl(job)}">
<a href="${jobBaseUrl}${job.shortUrl}${it.getUrl(job)}">${it.getCoverage(job)}</a>
<a href="${rootURL}/${it.getUrl(job)}">${it.getCoverage(job)}</a>

This comment has been minimized.

Copy link
@jglick

jglick Oct 25, 2014

Member

This looks better to me. I assume it works as desired, even when folders and/or views are in use? Then columns in Jenkins core ought to be fixed too—note to self.

This comment has been minimized.

Copy link
@uhafner

uhafner Oct 25, 2014

Author Member

Yes, tried with views and folders and mixed them. Also commented on https://issues.jenkins-ci.org/browse/JENKINS-23583 which describes same problem for other columns. I think all columns are affected that use relative links.

</j:if>
</td>
</j:jelly>
Expand Up @@ -9,7 +9,7 @@ MavenCoberturaPublisher.displayName=Publish Cobertura Coverage Report

CoverageColumn.columnName=Cobertura coverage
CoverageColumn.columnHeader=Coverage %
CoverageColumn.empty=n/a
CoverageColumn.empty=-
CoverageColumn.line={0}%
CoverageColumn.branch={0}%
CoverageColumn.both=L:{0}% - B:{1}%

0 comments on commit 1a89911

Please sign in to comment.