This is an automated email from the ASF dual-hosted git repository.
sbp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-release.git
The following commit(s) were added to refs/heads/main by this push:
new 806ff03 Show the form to set a revision as latest conditionally
806ff03 is described below
commit 806ff032d54c2bf4dc4c7dba970c1016771701f4
Author: Sean B. Palmer <[email protected]>
AuthorDate: Wed Apr 9 17:17:07 2025 +0100
Show the form to set a revision as latest conditionally
---
atr/templates/draft-revisions.html | 18 ++++++++++--------
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/atr/templates/draft-revisions.html
b/atr/templates/draft-revisions.html
index 22ac1a6..e144f93 100644
--- a/atr/templates/draft-revisions.html
+++ b/atr/templates/draft-revisions.html
@@ -71,14 +71,16 @@
{% endif %}
{% endif %}
- <h3 class="fs-6 fw-semibold mt-3 atr-sans">Actions</h3>
- <div class="mt-3">
- <form method="post"
- action="{{ as_url(routes.draft.revision_set,
project_name=project_name, version_name=version_name) }}">
- <input type="hidden" name="revision_name" value="{{
revision.name }}" />
- <button type="submit" class="btn btn-sm btn-outline-danger">Set
this revision as latest</button>
- </form>
- </div>
+ {% if revision.name != latest_revision_name %}
+ <h3 class="fs-6 fw-semibold mt-3 atr-sans">Actions</h3>
+ <div class="mt-3">
+ <form method="post"
+ action="{{ as_url(routes.draft.revision_set,
project_name=project_name, version_name=version_name) }}">
+ <input type="hidden" name="revision_name" value="{{
revision.name }}" />
+ <button type="submit" class="btn btn-sm
btn-outline-danger">Set this revision as latest</button>
+ </form>
+ </div>
+ {% endif %}
</div>
</div>
{% endfor %}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]