plset is not meant to know what it's dealing with, eg nom, promo...
[platal.git] / templates / survey / show_root.tpl
index 3e465be..8e6c20b 100644 (file)
@@ -1,6 +1,6 @@
 {**************************************************************************}
 {*                                                                        *}
-{*  Copyright (C) 2003-2007 Polytechnique.org                             *}
+{*  Copyright (C) 2003-2008 Polytechnique.org                             *}
 {*  http://opensource.polytechnique.org/                                  *}
 {*                                                                        *}
 {*  This program is free software; you can redistribute it and/or modify  *}
@@ -20,7 +20,7 @@
 {*                                                                        *}
 {**************************************************************************}
 
-<h1>Sondage : {$survey.title}</h1>
+<h1>Sondage&nbsp;: {$survey.title}</h1>
 <form action="survey/vote{if $survey_votemode}/{$survey.id}{/if}" method='post'>
 <table style="width: 100%">
   <tr>
         <td colspan="2">{$survey.description}</td>
       </tr>
       <tr>
-        <td class="titre">Fin du sondage :</td>
+        <td class="titre">Fin du sondage&nbsp;:</td>
         <td>{$survey.end|date_format:"%x"}</td>
       </tr>
       <tr>
-        <td class="titre">Type de sondage :</td>
+        <td class="titre">Type de sondage&nbsp;:</td>
         <td>{$survey_modes[$survey.mode]}</td>
       </tr>
       {if $survey.mode != Survey::MODE_ALL} 
       <tr>
-        <td class="titre">Promotions :</td> 
+        <td class="titre">Promotions&nbsp;:</td> 
         <td>
           {if $survey.promos eq "#"} 
           erreur 
     </p>
     {/if}
     </td>
-    {if $survey_editmode}
-      {assign var="survey_rooteditmode" value=true}
-      {if $survey.valid}
-        {assign var="survey_editmode" value=false}
-      {/if}
+    {if $survey_editmode && !$survey.valid}
+      {assign var="survey_editallmode" value=true}
     {/if}
     {if $survey_editmode}
-    <td>
-      {if $survey_rooteditmode}<a href='survey/edit/question/root'>{icon name=page_edit} Modifier la description</a><br />{/if}
-      <a href='survey/edit/add/0'>{icon name=add} Ajouter une question au d&#233;but</a>
+    <td class="smaller" style="width: 30%">
+      <a href='survey/edit/question/root'>{icon name=page_edit} Modifier la description</a>
+      {if $survey_editallmode}<br /><a href='survey/edit/add/0'>{icon name=add} Ajouter une question au d&#233;but</a>{/if}
     </td>
     {/if}
   </tr>
@@ -82,8 +79,8 @@
     <td>
       {include file='survey/show_question.tpl' squestion=$squestion}
     </td>
-    {if $survey_editmode}
-    <td>
+    {if $survey_editallmode}
+    <td class="smaller" style="width: 30%; vertical-align: middle">
       <a href='survey/edit/question/{$squestion.id}'>{icon name=page_edit} Modifier cette question</a><br />
       <a href='survey/edit/del/{$squestion.id}'>{icon name=delete} Supprimer cette question</a><br />
       <a href='survey/edit/add/{$squestion.id+1}'>{icon name=add} Ajouter une question apr&#232;s</a>
@@ -94,7 +91,7 @@
   {/if}
 </table>
 <p class="center">
-  {if $survey_rooteditmode}
+  {if $survey_editmode}
   <a href='survey/edit/valid'>
     {icon name=tick} 
     {if $survey_updatemode}Enregistrer les modifications{else}Proposer ce sondage{/if}