1 {**************************************************************************}
3 {* Copyright (C) 2003-2007 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 {**************************************************************************}
25 <script type="text/javascript">//<![CDATA[
27 var year = gdt.getYear();
32 var oldMate = year >= {/literal}{$smarty.session.promo_sortie}{literal};
34 function printTitle(text)
37 document.write("ex-" + text);
45 var val = document.forms.prof_annu[type + '_sel'].value;
46 if (val == '0' || document.getElementById(type + '_' + val) != null) {
47 document.getElementById(type + '_add').style.display = 'none';
49 document.getElementById(type + '_add').style.display = '';
53 function remove(cat, id)
55 $('#' + cat + '_' + id).remove();
60 var cb = document.forms.prof_annu[cat + '_sel'];
62 var text = cb.options[cb.selectedIndex].text;
63 var html = '<tr id="' + cat + '_' + id + '">'
65 + ' <input type="hidden" name="' + cat + '[' + id + ']" value="' + text + '" />'
69 + ' <a href="javascript:remove(\'' + cat + '\', ' + id + ')">'
70 + ' <img src="images/icons/cross.gif" alt="cross" title="Supprimer ce groupe" />'
74 $('#' + cat).after(html);
81 <table class="bicol" summary="Profil: Informations Polytechniciennes">
84 Informations polytechniciennes
88 <td colspan="2" class="flags">
89 <span class="rouge"><input type="checkbox" name="accesX" checked="checked" disabled="disabled" /></span>
90 <span class="texte">privé</span>
95 <script type="text/javascript">printTitle("Section")</script>
98 <select name="section">
99 {select_db_table table="sections" valeur=$section}
106 <script type="text/javascript">printTitle("Binet(s)")</script>
109 <select name="binets_sel" onchange="update('binets')">
110 {select_db_table table="binets_def" valeur=0 champ="text" pad='1'}
112 <a id="binets_add" href="javascript:add('binets')">{icon name="add" title="Ajouter ce binet"}</a>
115 {foreach item=text key=bid from=$binets}
116 <tr id="binets_{$bid}">
118 <input type="hidden" name="binets[{$bid}]" value="{$text}" />
122 <a href="javascript:remove('binets', {$bid})">{icon name="cross" title="Supprimer ce binet"}</a>
128 <td class="titre">Groupe(s) X</td>
130 <select name="groupesx_sel" onchange="update('groupesx')">
131 {select_db_table table="groupesx_def" valeur=0 champ="text" pad='1'}
133 <a id="groupesx_add" href="javascript:add('groupesx')">{icon name="add" title="Ajouter ce groupe X"}</a>
136 {foreach item=text key=bid from=$groupesx}
137 <tr id="groupesx_{$bid}">
139 <input type="hidden" name="groupesx[{$bid}]" value="{$text}" />
143 <a href="javascript:remove('groupesx', {$bid})">{icon name="cross" title="Supprimer ce groupe X"}</a>
149 <script type="text/javascript">
154 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}