summaryrefslogtreecommitdiffstats
path: root/extensions/BugModal/template
diff options
context:
space:
mode:
authorByron Jones <glob@mozilla.com>2015-04-28 06:41:44 +0200
committerByron Jones <glob@mozilla.com>2015-04-28 06:41:44 +0200
commit29e3eb8b03ba072fa4ce092b45fb98c2e2352744 (patch)
tree38c4ab19d0e5bf1a81c927fd713c417f0d31e908 /extensions/BugModal/template
parent283be21f66e638667bc2ec7720cab459ecf1f698 (diff)
downloadbugzilla-29e3eb8b03ba072fa4ce092b45fb98c2e2352744.tar.gz
bugzilla-29e3eb8b03ba072fa4ce092b45fb98c2e2352744.tar.xz
Bug 1153102: add hooks for bug bounty display and form
Diffstat (limited to 'extensions/BugModal/template')
-rw-r--r--extensions/BugModal/template/en/default/bug_modal/attachments.html.tmpl16
-rw-r--r--extensions/BugModal/template/en/default/bug_modal/edit.html.tmpl10
2 files changed, 19 insertions, 7 deletions
diff --git a/extensions/BugModal/template/en/default/bug_modal/attachments.html.tmpl b/extensions/BugModal/template/en/default/bug_modal/attachments.html.tmpl
index f9209d3bf..8e04392d8 100644
--- a/extensions/BugModal/template/en/default/bug_modal/attachments.html.tmpl
+++ b/extensions/BugModal/template/en/default/bug_modal/attachments.html.tmpl
@@ -8,11 +8,18 @@
[%#
# bug: (bug object) the main bug object
+ # active_attachments: array of active attachment objects
+ # obsolete_attachments: array of obsolete attachment objects
#%]
<table class="layout-table" id="attachments">
[% FOREACH attachment IN bug.attachments %]
- [% NEXT IF attachment.isprivate && !(user.is_insider || attachment.attacher.id == user.id) %]
+ [%
+ NEXT IF attachment.isprivate && !(user.is_insider || attachment.attacher.id == user.id);
+ attachment_rendered = 0;
+ Hook.process("row");
+ NEXT IF attachment_rendered;
+ %]
<tr class="
[%~ " bz_private" IF attachment.isprivate %]
[%~ " attach-obsolete" IF attachment.isobsolete %]
@@ -67,3 +74,10 @@
</tr>
[% END %]
</table>
+
+<div id="attachments-actions">
+ [% IF obsolete_attachments %]
+ <button type="button" id="attachments-obsolete-btn" class="minor">Show Obsolete Attachments</button>
+ [% END %]
+ [% Hook.process('actions') %]
+</div>
diff --git a/extensions/BugModal/template/en/default/bug_modal/edit.html.tmpl b/extensions/BugModal/template/en/default/bug_modal/edit.html.tmpl
index f9c93efd1..54ae9bec0 100644
--- a/extensions/BugModal/template/en/default/bug_modal/edit.html.tmpl
+++ b/extensions/BugModal/template/en/default/bug_modal/edit.html.tmpl
@@ -922,12 +922,10 @@
subtitle = sub.join(", ")
collapsed = active_attachments == 0
%]
- [% INCLUDE bug_modal/attachments.html.tmpl %]
- [% IF obsolete_attachments %]
- <div id="attachments-actions">
- <button type="button" id="attachments-obsolete-btn" class="minor">Show Obsolete Attachments</button>
- </div>
- [% END %]
+ [% INCLUDE bug_modal/attachments.html.tmpl
+ active_attachments = active_attachments
+ obsolete_attachments = obsolete_attachments
+ %]
[% END %]
[% END %]