From 4b3f99ad09407a6c145f39641257060035e71303 Mon Sep 17 00:00:00 2001 From: Frédéric Buclin Date: Wed, 26 Aug 2015 23:34:38 +0200 Subject: Bug 1197822: Do not display the "View" link for deleted attachments r=gerv a=sgreen --- template/en/default/attachment/edit.html.tmpl | 38 ++++++++++++++------------- 1 file changed, 20 insertions(+), 18 deletions(-) (limited to 'template') diff --git a/template/en/default/attachment/edit.html.tmpl b/template/en/default/attachment/edit.html.tmpl index 092f3e76a..d3d5dae95 100644 --- a/template/en/default/attachment/edit.html.tmpl +++ b/template/en/default/attachment/edit.html.tmpl @@ -46,9 +46,9 @@
- [% "[patch]" IF attachment.ispatch%] - - [% attachment.description FILTER html %] + [% IF attachment.ispatch %][patch][% END %] + + [%~ attachment.description FILTER html ~%] [% IF can_edit %] (edit details) @@ -293,25 +293,27 @@ [% END %]
- [% END %] -
+ [% END %] +
-
- Actions: - View - [% IF use_patchviewer %] - | Diff - [% END %] - [% IF Param("allow_attachment_deletion") - && user.in_group('admin') - && attachment.datasize > 0 %] - | Delete - [% END %] - [% Hook.process('action') %] -
+[% IF attachment.datasize %] +
+ Actions: + + [% IF attachment.is_viewable %]View[% ELSE %]Download[% END %] + + [% IF use_patchviewer %] + | Diff + [% END %] + [% IF Param("allow_attachment_deletion") && user.in_group('admin') %] + | Delete + [% END %] + [% Hook.process('action') %] +
+[% END %]
Attachments on [% "$terms.bug ${attachment.bug_id}" FILTER bug_link(attachment.bug_id) FILTER none %]: -- cgit v1.2.3-24-g4f1b