Improves last commit.
[platal.git] / templates / xnetgrp / annuaire.tpl
index ee05e60..f5a2796 100644 (file)
@@ -1,6 +1,6 @@
 {**************************************************************************}
 {*                                                                        *}
-{*  Copyright (C) 2003-2009 Polytechnique.org                             *}
+{*  Copyright (C) 2003-2010 Polytechnique.org                             *}
 {*  http://opensource.polytechnique.org/                                  *}
 {*                                                                        *}
 {*  This program is free software; you can redistribute it and/or modify  *}
@@ -34,6 +34,7 @@ Le groupe {$asso->nom} compte {$nb_tot} membres :
       Ajouter un membre
     </a>
   </li>
+  {if $asso->has_ml}
   <li>
     <a href="{$platal->ns}admin/annuaire">
       {icon name=wand title="Synchroniser"} 
@@ -41,6 +42,7 @@ Le groupe {$asso->nom} compte {$nb_tot} membres&nbsp;:
     </a>
   </li>
   {/if}
+  {/if}
   <li>
     <a href="{$platal->ns}annuaire/csv/{$asso->diminutif}.csv">
       {icon name=page_excel title="Fichier Excel"} 
@@ -100,19 +102,22 @@ Le groupe {$asso->nom} compte {$nb_tot} membres&nbsp;:
     <th>Actions</th>
     {/if}
   </tr>
+  {assign var=lostUsers value=false}
   {foreach from=$users item=user}
   <tr>
     <td>
+      {if $user->lost}{assign var=lostUsers value=true}{/if}
       {profile user=$user promo=false}
+    </td>
     <td>
-      {if $user->group_perms eq 'admin'}<strong>{/if}
+      {if $user->group_perms eq 'admin' && $user->promo()}<strong>{/if}
       {$user->promo()}
-      {if $user->group_perms eq 'admin'}</strong>{/if}
+      {if $user->group_perms eq 'admin' && $user->promo()}</strong>{/if}
     </td>
     {if $user->group_comm}
     <td>{$user->group_comm}</td>
     {/if}
-    <td class="right" {if !$user->group_comm}colspan="2"{/if}>
+    <td class="right"{if !$user->group_comm} colspan="2"{/if}>
       {if $user->hasProfile()}
       <a href="https://www.polytechnique.org/vcard/{$user->login()}.vcf">{icon name=vcard title="[vcard]"}</a>
       {/if}
@@ -120,7 +125,7 @@ Le groupe {$asso->nom} compte {$nb_tot} membres&nbsp;:
     </td>
     {if $is_admin}
     <td class="center">
-      <a href="{$platal->ns}member/{$user->login()}">{icon name=user_edit title="Edition du profil"}</a>
+      <a href="{$platal->ns}member/{$user->login()}">{icon name=user_edit title="Édition du profil"}</a>
       <a href="{$platal->ns}member/del/{$user->login()}">{icon name=delete title="Supprimer de l'annuaire"}</a>
     </td>
     {/if}
@@ -128,9 +133,9 @@ Le groupe {$asso->nom} compte {$nb_tot} membres&nbsp;:
   {/foreach}
 </table>
 
-{if $pages ge 1}
+{if $pages gt 1}
 <p class="descr" style="text-align: center">
-{section name="links" loop=$pages min=1}
+{section name="links" loop=$pages}
 {if $smarty.section.links.index eq $current}
 <span class="erreur">{$smarty.section.links.iteration}</span>
 {else}
@@ -146,7 +151,7 @@ Le groupe {$asso->nom} compte {$nb_tot} membres&nbsp;:
 </p>
 {/if}
 
-{if $broken}
+{if $lostUsers}
 <p class="smaller">
   {icon name=error}&nbsp;Un camarade signalé par ce symbole n'a plus d'adresse de redirection et ne peut donc
   plus être contacté via son adresse polytechnique.org. Si tu connais sa nouvelle adresse, tu peux nous la communiquer en