1 {**************************************************************************}
3 {* Copyright (C) 2003-2011 Polytechnique.org *}
4 {* http://opensource.polytechnique.org/ *}
6 {* This program is free software; you can redistribute it and/or modify *}
7 {* it under the terms of the GNU General Public License as published by *}
8 {* the Free Software Foundation; either version 2 of the License, or *}
9 {* (at your option) any later version. *}
11 {* This program is distributed in the hope that it will be useful, *}
12 {* but WITHOUT ANY WARRANTY; without even the implied warranty of *}
13 {* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *}
14 {* GNU General Public License for more details. *}
16 {* You should have received a copy of the GNU General Public License *}
17 {* along with this program; if not, write to the Free Software *}
18 {* Foundation, Inc., *}
19 {* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *}
21 {**************************************************************************}
23 <script type="text/javascript">
25 function showInformations(box)
27 var state = (box.value != 'virtual') ? '' : 'none';
28 document.getElementById('prenom').style.display = state;
29 document.getElementById('sexe').style.display = state;
30 document.getElementById('make_X').style.display = state;
31 document.getElementById('password').style.display = state;
34 function showXInput(box)
37 document.getElementById('make_X_cb').style.display = 'none';
38 document.getElementById('make_X_login').style.display = '';
44 <h1>{$asso->nom} : gestion des membres</h1>
47 [<a href='{$platal->ns}annuaire'>Retour à l'annuaire</a>]
51 Édition du profil de {profile user=$user groupperms=false sex=false promo=true}
52 <a href="mailto:{$user->bestEmail()}">{icon name=email title="mail"}</a>
55 <form method="post" action="{$platal->ns}member/{$platal->argv[1]}">
57 <table cellpadding="0" cellspacing="0" class='tinybicol'>
61 Identifiant unique :
65 <a href="https://www.polytechnique.org/admin/user/{$user->hruid}">{icon name="user_edit" title="Administer"}</a>
74 <select name="group_perms">
75 <option value="membre" {if $user->group_perms eq 'membre'}selected="selected"{/if}>Membre</option>
76 <option value="admin" {if $user->group_perms eq 'admin'}selected="selected"{/if}>Animateur</option>
85 <select name="group_position">
86 <option value=""{if $user->group_position eq ''} selected="selected"{/if}></option>
87 {foreach from=$positions item=position}
88 <option value="{$position}"{if $user->group_position eq $position} selected="selected"{/if}>{$position}</option>
93 {if $user->type eq 'virtual' || ($user->type eq 'xnet' && !$user->perms)}
96 Type d'utilisateur :
99 <select name="type" onchange="showInformations(this); return true">
100 <option value="xnet" {if $user->type neq 'virtual'}selected="selected"{/if}>Personne physique</option>
101 <option value="virtual" {if $user->type eq "virtual"}selected="selected"{/if}>Personne morale</option>
106 <td class="titre">Nom complet :</td>
107 <td>{$user->fullName()}</td>
110 <td class="titre">Nom annuaire :</td>
111 <td>{$user->directoryName()}</td>
114 <td class="titre">Nom :</td>
116 <input type="text" value="{$user->lastname}" name="lastname" size="40" />
119 {if $user->type neq "virtual"}
121 <td class="titre">Prénom :</td>
123 <input type="text" value="{$user->firstname}" name="firstname" size="40" />
127 <td class="titre">Nom affiché :</td>
129 <input type="text" value="{$user->displayName()}" name="display_name" size="40" />
133 <tr id="sexe" class="impair" {if $user->type eq "virtual"}style="display: none"{/if}>
139 <option value="male"{if !$user->isFemale()} selected="selected"{/if}>Homme</option>
140 <option value="female"{if $user->isFemale()} selected="selected"{/if}>Femme</option>
150 <input type="text" value="{$user->forlifeEmail()}" name="email" size="40" />
160 <input type="text" name="comm" value="{$user->group_comm}" size="40" maxlength="255" /><br />
161 <small>Poste, origine… (accessible à toutes les personnes autorisées à consulter l'annuaire)</small>
170 <label>Inscrit<input type="radio" name="newsletter" value="1" {if $nl_registered eq 1}checked="checked"{/if} /></label>
172 <label><input type="radio" name="newsletter" value="0" {if $nl_registered eq 0}checked="checked"{/if} />Non inscrit</label>
176 {if $user->type eq 'xnet'}
179 <span id="make_X_cb">
180 <input type="checkbox" name="is_x" id="is_x" onclick="showXInput(this);" onchange="showXInput(this);" />
181 <label for="is_x">coche cette case s'il s'agit d'un X ou un master ou doctorant de l'X</label>
183 <span id="make_X_login" style="display: none">
184 <span class="titre">Identifiant (prenom.nom.promo) :</span>
185 <input type="text" name="login_X" value="" />
190 {if $user->type eq 'xnet' && $suggest}
194 <input type="checkbox" name="suggest" />
195 coche cette case si tu souhaites qu'un compte « Extérieur » soit créé
196 pour cette personne et que nous lui envoyions un email afin qu'il ait
197 accès aux nombreuses fonctionnalités de Polytechnique.net (inscription
198 aux évènements, télépaiement, modération des listes de diffusion…)
203 {if $user->type eq 'xnet' && $pending_xnet_account}
207 <input type="checkbox" name="again" />
208 Cette personne a un compte « Extérieur » en attente d'activation de sa part. Pour la relancer, il suffit
209 de cocher la case ci-contre.
216 <h2>Abonnement aux listes</h2>
218 <table cellpadding="0" cellspacing="0" class='large'>
225 {foreach from=$listes item=liste}
228 <input type='hidden' name='ml1[{$liste.list}]' value='{$liste.sub}' />
229 <input type='checkbox' name='ml2[{$liste.list}]' {if $liste.sub eq 2}checked="checked"{/if} />
232 <a href='{$platal->ns}lists/members/{$liste.list}'>{$liste.list}</a>
234 <td>{$liste.desc|smarty:nodefaults}</td>
235 <td class='right'>{$liste.nbsub}</td>
238 <tr><td colspan='4'>Pas de listes pour ce groupe</td></tr>
242 <h2>Abonnement aux alias</h2>
244 <table cellpadding="0" cellspacing="0" class='large'>
250 {foreach from=$alias key=address item=sub}
253 <input type='hidden' name='ml3[{$address}]' value='{$sub}' />
254 <input type='checkbox' name='ml4[{$address}]' {if $sub}checked="checked"{/if} />
257 <a href='{$platal->ns}alias/admin/{$address}'>{$address}</a>
261 <tr><td colspan='2'>Pas d'alias pour ce groupe</td></tr>
267 <input type="submit" name='change' value="Valider ces changements" onclick="return hashResponse('new_plain_password', false, false, false);" />
269 <input type="reset" value="Annuler ces changements" />
275 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}