From 1427884e689fa9c470f88bdefc7eabbb87b047c6 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Tue, 14 Aug 2007 17:34:45 +0000 Subject: Bug 392175: Move isViewable out of attachment.cgi + some other minor cleanup - Patch by Frédéric Buclin MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- template/en/default/attachment/edit.html.tmpl | 26 +++++++++++----------- .../en/default/attachment/show-multiple.html.tmpl | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) (limited to 'template/en') diff --git a/template/en/default/attachment/edit.html.tmpl b/template/en/default/attachment/edit.html.tmpl index d0a75b3fd..10438a7a5 100644 --- a/template/en/default/attachment/edit.html.tmpl +++ b/template/en/default/attachment/edit.html.tmpl @@ -286,7 +286,19 @@ [% IF !attachment.datasize %] The content of this attachment has been deleted. - [% ELSIF isviewable %] + [% ELSIF attachment.isurl %] + + + [% IF attachment.datasize < 120 %] + [% attachment.data FILTER html %] + [% ELSE %] + [% attachment.data FILTER truncate(80) FILTER html %] +  ... + [% attachment.data.match(".*(.{20})$").0 FILTER html %] + [% END %] + + + [% ELSIF attachment.is_viewable %] [% INCLUDE global/textarea.html.tmpl id = 'editFrame' @@ -317,18 +329,6 @@ //--> - [% ELSIF attachment.isurl %] - - - [% IF attachment.datasize < 120 %] - [% attachment.data FILTER html %] - [% ELSE %] - [% attachment.data FILTER truncate(80) FILTER html %] -  ... - [% attachment.data.match(".*(.{20})$").0 FILTER html %] - [% END %] - - [% ELSE %]

diff --git a/template/en/default/attachment/show-multiple.html.tmpl b/template/en/default/attachment/show-multiple.html.tmpl index 9c0fc57b0..3d5b3b4e8 100644 --- a/template/en/default/attachment/show-multiple.html.tmpl +++ b/template/en/default/attachment/show-multiple.html.tmpl @@ -86,7 +86,7 @@ - [% IF a.isviewable %] + [% IF a.is_viewable %]