From 6593431247965b1e589aa97c2173272ed3359a86 Mon Sep 17 00:00:00 2001 From: Florent Bruneau Date: Sun, 9 Mar 2008 15:27:01 +0100 Subject: [PATCH] Open the edition box via javascript (avoid a reload). Hide the comment box if no comment has been given yet. Signed-off-by: Florent Bruneau --- templates/admin/valider.tpl | 45 ++++++++++++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 11 deletions(-) diff --git a/templates/admin/valider.tpl b/templates/admin/valider.tpl index 5701f1d..3f226f3 100644 --- a/templates/admin/valider.tpl +++ b/templates/admin/valider.tpl @@ -15,13 +15,23 @@ {* *} {* You should have received a copy of the GNU General Public License *} {* along with this program; if not, write to the Free Software *} -{* Foundation, Inc., *} + {* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *} {* *} {**************************************************************************} +{javascript name="jquery"} + +

Validation

- + {if $vit->total()} @@ -52,9 +62,18 @@ {include file=$valid->formu()} {if $valid->editor()} + + {if $preview_id neq $valid->id()} +
+ {icon name="add"} +
+ {/if} + Editer + + + id()}style="display: none"{/if} id="edit_{$valid->id()}"> - {if $preview_id == $valid->id()} -
+
{include file=$valid->editor()} @@ -64,15 +83,19 @@
- {else} - - {icon name=page_edit}Editer cette demande avant validation - - {/if} {/if} - Commentaires + + + {if $valid->comments|@count eq 0} +
+ {icon name="add"} +
+ {/if} + Commentaires + + {foreach from=$valid->comments item=c} @@ -81,7 +104,7 @@ {$c[1]|nl2br} {/foreach} - + comments|@count eq 0}style="display: none"{/if} id="comment_{$valid->id()}">
-- 2.1.4