{**************************************************************************}
{* *}
-{* 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 *}
{if $smarty.post.u_kill_conf}
<form method="post" action="admin/user">
+ {xsrf_token_field}
<div class="center">
<input type="hidden" name="user_id" value="{$smarty.request.user_id}" />
Confirmer la suppression de {$smarty.request.user_id}
{else}
<form method="post" action="admin/user">
+ {xsrf_token_field}
<table class="tinybicol" cellspacing="0" cellpadding="2">
<tr>
<th>
Administrer
</th>
</tr>
- {if !$smarty.request.login && !$mr.forlife}
+ {if !$smarty.request.login && !$mr.hruid}
<tr class="pair">
<td class="center">
- Il est possible d'entrer ici n'importe quelle adresse mail : redirection, melix, ou alias.
+ Il est possible d'entrer ici n'importe quelle adresse email : redirection, melix, ou alias.
</td>
</tr>
{/if}
<tr>
<td class="center">
- <input type="text" name="login" size="40" maxlength="255" value="{$smarty.request.login|default:$mr.forlife}" />
+ <input type="text" name="login" size="40" maxlength="255" value="{$smarty.request.login|default:$mr.hruid}" />
</td>
</tr>
<tr>
{if $mr}
<p class="smaller">
-Derniére connexion le <strong>{$lastlogin|date_format:"%d %B %Y, %T"}</strong>
-depuis <strong>{$host}</strong>
+Dernière connexion le <strong>{$lastlogin|date_format:"%d %B %Y, %T"}</strong>
+depuis <strong>{$host}</strong>.
</p>
{literal}
document.forms.fwds.clean_fwd.value = fwd;
document.forms.fwds.submit();
}
+function ban_write()
+{
+ document.forms.bans.write_perm.value = "!xorg.*";
+}
+function ban_read()
+{
+ document.forms.bans.read_perm.value = "!xorg.*";
+}
+
// ]]>
</script>
{/literal}
<form id="auth" method="post" action="admin/user">
+ {xsrf_token_field}
<table cellspacing="0" cellpadding="2" class="tinybicol">
<tr>
<th colspan="2">
Mot de passe
</td>
<td>
- <input type="text" name="newpass_clair" size="10" maxlength="10" value="********" />
- <input type="hidden" name="passw" size="32" maxlength="32" value="{$mr.password}" />
- <input type="hidden" name="hashpass" value="" />
+ <div style="float: left">
+ <input type="text" name="newpass_clair" size="10" maxlength="10" value="********" />
+ <input type="hidden" name="passw" size="32" maxlength="32" value="{$mr.password}" />
+ <input type="hidden" name="hashpass" value="" />
+ </div>
+ <div style="float: left; margin-top: 5px;">
+ {checkpasswd prompt="newpass_clair" submit="dummy_none"}
+ </div>
</td>
</tr>
<tr class="pair">
Sexe
</td>
<td>
- femme <input type="radio" name="sexeN" {if $mr.sexe}checked="checked"{/if} value='1'/>
- <input type="radio" name="sexeN" {if !$mr.sexe}checked="checked"{/if} value='0'/> homme
+ <label>femme <input type="radio" name="sexeN" {if $mr.sexe}checked="checked"{/if} value='1'/></label>
+ <label><input type="radio" name="sexeN" {if !$mr.sexe}checked="checked"{/if} value='0'/> homme</label>
</td>
</tr>
<tr class="pair">
<td>
<input type="text" name="naissanceN" size="12" maxlength="10" value="{$mr.naissance}" />
{if $mr.naissance_ini neq '0000-00-00' && $mr.naissance neq $mr.naissance_ini}
- <span class="erreur smaller">({icon name=error}Date de naissance connue : {$mr.naissance_ini})</span>
+ <span class="erreur smaller">({icon name=error}Date de naissance connue : {$mr.naissance_ini})</span>
{elseif $mr.naiss_err}
<span class="erreur smaller">({icon name=error}Date de naissance incohérente)</span>
{/if}
<input type="text" name="promoN" size="4" maxlength="4" value="{$mr.promo}" />
</td>
</tr>
- <tr class "impair">
+ <tr class="impair">
<td class="titre">
Surveillance
</td>
<td>
- <input type="checkbox" name="watchN" {if $mr.watch}checked="checked"{/if} />
- Surveiller l'activité de ce compte<br />
+ <label><input type="checkbox" name="watchN" {if $mr.watch}checked="checked"{/if} />
+ Surveiller l'activité de ce compte</label><br />
<span class="smaller">Cette option permet d'avoir des logs complets de l'activité
- du compte via le logger, et d'être alerté lors des connexions de l'utilisateur</span>
+ du compte via le logger, et d'être alerté lors des connexions de l'utilisateur.</span>
</td>
</tr>
<tr class="impair">
{else}
<tr class="center">
<td>
- <a href="profile/{$mr.forlife}" class="popup2">[Voir fiche]</a>
+ <a href="profile/{$mr.hruid}" class="popup2">[Voir fiche]</a>
</td>
<td>
<input onclick="doEditUser(); return true;" type="submit" name="u_edit" value="UPDATE" />
Pour ceci changer ses permissions en 'disabled'.
</p>
<form id="alias" method="post" action="admin/user">
+ {xsrf_token_field}
<table class="tinybicol" cellpadding="2" cellspacing="0">
<tr>
<th class="alias" colspan="3">
- Alias e-mail
+ Alias email
</th>
</tr>
{iterate from=$aliases item=a}
</table>
</form>
-<p>
-<strong>* à ne modifier qu'avec l'accord express de l'utilisateur !!!</strong>
-</p>
+<p><strong>* à ne modifier qu'avec l'accord express de l'utilisateur !!!</strong></p>
+
+<form id="bans" method="post" action="admin/user">
+ {xsrf_token_field}
+ <table cellspacing="0" cellpadding="2" class="tinybicol">
+ <tr>
+ <th colspan="4">
+ Permissions sur les forums
+ </th>
+ </tr>
+ <tr class="impair">
+ <td class="titre">
+ Poster
+ </td>
+ <td>
+ <input type="text" name="write_perm" size="32" maxlength="255" value="{$bans.write_perm}" />
+ </td>
+ <td class="action">
+ <a href="javascript:ban_write()">Bannir</a>
+ </td>
+ </tr>
+ <tr class="pair">
+ <td class="titre">
+ Lire
+ </td>
+ <td>
+ <input type="text" name="read_perm" size="32" maxlength="255" value="{$bans.read_perm}" />
+ </td>
+ <td class="action">
+ <a href="javascript:ban_read()">Bannir</a>
+ </td>
+ </tr>
+ <tr class="impair">
+ <td class="titre">
+ Commentaire
+ </td>
+ <td colspan="2">
+ <input type="text" name="comment" size="40" maxlength="255" value="{$bans.comment}" />
+ </td>
+ </tr>
+ <tr class="center">
+ <td colspan="3">
+ <input type="hidden" name="user_id" value="{$mr.user_id}" />
+ <input type="submit" name="b_edit" value="Modifier" />
+ </td>
+ </tr>
+ </table>
+</form>
+
+{javascript name="ajax"}
+{test_email hruid=$user->login()}
<form id="fwds" method="post" action="admin/user#fwds">
+ {xsrf_token_field}
<table class="bicol" cellpadding="2" cellspacing="0">
<tr>
<th colspan="4">
Redirections
</th>
</tr>
- {assign var=actives value=false}
- {assign var=disabled value=false}
+ {assign var=actives value=false}
+ {assign var=disabled value=false}
{foreach item=mail from=$emails}
{cycle assign=class values="impair,pair"}
<tr class="{$class}">
- {if $mail->active}
+ {if $mail->active && $mail->has_disable()}
{assign var=actives value=true}
- {elseif $mail->disabled}
+ {elseif $mail->disabled && $mail->has_disable()}
{assign var=disabled value=true}
{/if}
<td class="titre">
</td>
<td>
{if $mail->broken}<span style="color: #f00">{/if}
- {$mail->email}
+ {if $mail->email == 'googleapps'}<a href="admin/googleapps/user/{$mr.hruid}">{/if}
+ {$mail->display_email}
+ {if $mail->email == 'googleapps'}</a>{/if}
{if $mail->broken}<em> (en panne)</em></span>{/if}
</td>
<td class="action">
+ {if $mail->is_removable()}
<a href="javascript:del_fwd('{$mail->email}')">delete</a>
+ {/if}
</td>
</tr>
{if $mail->panne && $mail->panne neq "0000-00-00"}
<tr class="{$class}">
<td colspan="3" class="smaller" style="color: #f00">
{icon name=error title="Panne"}
- Panne de {$mail->email} le {$mail->panne|date_format}
+ Panne de {$mail->display_email} le {$mail->panne|date_format}
{if $mail->panne neq $mail->last}confirmée le {$mail->last|date_format}{/if}
</td>
<td class="action">
{cycle assign=class values="impair,pair"}
<tr class="{$class}">
<td class="titre" colspan="2">
- Ajouter un email
+ Ajouter une adresse
</td>
<td>
<input type="text" name="email" size="29" maxlength="60" value="" />
<tr class="{$class}">
<td colspan="4" class="center">
{if $actives}
- <input type="submit" name="disable_fwd" value="Désactiver la redirection mail" />
+ <input type="submit" name="disable_fwd" value="Désactiver la redirection des emails" />
{/if}
{if $disabled}
- <input type="submit" name="enable_fwd" value="Réactiver la redirection mail" />
+ <input type="submit" name="enable_fwd" value="Réactiver la redirection des emails" />
{/if}
</td>
</tr>