Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JENKINS-74054] Extract inline script block in AbstractNameValueHeader/rowHeader.jelly #147

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
const buildId = document.querySelector('.pipeline-info .revision .title').dataset.buildId;
jQuery('#build-parameters-' + buildId).tooltip({
shlomomdahan marked this conversation as resolved.
Show resolved Hide resolved
bodyHandler: function() {
return jQuery('#build-parameters-' + buildId).html();
},
});
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<div class="pipeline-info">
<div class="revision rounded">
<div class="title">Pipeline ${buildGrid.get(0,0).getRevision()}</div>
<div class="title" data-build-id="${buildGrid.get(0,0).getId()}">Pipeline ${buildGrid.get(0,0).getRevision()}</div>
<j:choose>
<j:when test="${buildGrid.get(0,0).getParameters().isEmpty()}">
<div class="description">No parameters</div>
Expand All @@ -21,13 +21,7 @@
</j:forEach>
</ul>
</div>
<script>
jQuery('#build-parameters-trigger-${buildGrid.get(0,0).getId()}').tooltip({
bodyHandler: function() {
return jQuery('#build-parameters-${buildGrid.get(0,0).getId()}').html();
}
});
</script>
<st:adjunct includes="au.com.centrumsystems.hudson.plugin.buildpipeline.extension.AbstractNameValueHeader.build-parameters-tooltip"/>
</j:otherwise>
</j:choose>
</div>
Expand Down