[PATCH 6/6] templates: Add "download with dependencies" links
Stephen Finucane
stephen at that.guru
Tue Jan 31 09:59:44 AEDT 2017
This will allow users to download patches with any dependencies
included. Since a patch can belong to many series a dropdown is
used.
Signed-off-by: Stephen Finucane <stephen at that.guru>
---
patchwork/templates/patchwork/submission.html | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/patchwork/templates/patchwork/submission.html b/patchwork/templates/patchwork/submission.html
index 66c1159..da92e58 100644
--- a/patchwork/templates/patchwork/submission.html
+++ b/patchwork/templates/patchwork/submission.html
@@ -288,6 +288,18 @@ function toggle_div(link_id, headers_id)
<a href="{% url 'patch-mbox' patch_id=submission.id %}"
class="btn btn-default" role="button" data-toggle="tooltip"
title="Download patch mbox">mbox</a>
+ {% if submission.latest_series %}
+ <button type="button" class="btn btn-default dropdown-toggle"
+ data-toggle="dropdown">
+ <span class="caret"></span>
+ </button>
+ <ul class="dropdown-menu" role="menu">
+ {% for series in submission.series.all %}
+ <li><a href="{% url 'patch-mbox' patch_id=submission.id %}?series={{ series.id }}"
+ >{{ series }}</a></li>
+ {% endfor %}
+ </ul>
+ {% endif %}
</div>
</h2>
--
2.9.3
More information about the Patchwork
mailing list