0337d704 |
1 | {**************************************************************************} |
2 | {* *} |
50a40a33 |
3 | {* Copyright (C) 2003-2006 Polytechnique.org *} |
0337d704 |
4 | {* http://opensource.polytechnique.org/ *} |
5 | {* *} |
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. *} |
10 | {* *} |
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. *} |
15 | {* *} |
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 *} |
20 | {* *} |
21 | {**************************************************************************} |
22 | |
d02b8359 |
23 | {include file="core/table-editor.tpl"} |
0337d704 |
24 | |
25 | <h1>Administration Polytechnique.org</h1> |
26 | |
27 | {literal} |
28 | <script type="text/javascript"> |
29 | <!-- |
30 | function new_grade() { |
31 | document.forms.form_grade.act.value = "new"; |
32 | document.forms.form_grade.submit(); |
33 | return true; |
34 | } |
35 | |
36 | function del_grade( myid ) { |
37 | if (confirm ("You are about to delete this entry. Do you want to proceed?")) { |
38 | document.forms.form_grade.act.value = "del"; |
39 | document.forms.form_grade.gid.value = myid; |
40 | document.forms.form_grade.submit(); |
41 | return true; |
42 | } |
43 | } |
44 | // --> |
45 | </script> |
46 | {/literal} |
47 | |
e7ae7df9 |
48 | <form method="post" action='{$t->pl}/edit/{$id}#form_grade' id='form_grade'> |
0337d704 |
49 | <table class='bicol'> |
50 | <tr> |
51 | <th>id</th> |
52 | <th>intitulé</th> |
53 | <th>ordre</th> |
54 | <th> </th> |
55 | </tr> |
56 | <tr> |
57 | <td colspan='3'> |
58 | Nouveau ... |
59 | </td> |
60 | <td class='action'> |
e7ae7df9 |
61 | <a href='javascript:new_grade()'>nouveau{icon name=add title='nouveau grade'}</a> |
0337d704 |
62 | </td> |
63 | </tr> |
64 | {iterate from=$grades item=g} |
65 | <tr class="{cycle values="pair,impair"}"> |
66 | <td>{$g.gid}</td> |
67 | <td> |
68 | <input type='text' size='65' value="{$g.text}" name="grades[{$g.gid}]" /> |
69 | </td> |
70 | <td> |
71 | <input type='text' maxlength='2' value="{$g.pos}" name="pos[{$g.gid}]" /> |
72 | </td> |
73 | <td class='action'> |
e7ae7df9 |
74 | <a href='javascript:del_grade({$g.gid})'>{icon name=delete title='supprimer grade'}</a> |
0337d704 |
75 | </td> |
76 | </tr> |
77 | {/iterate} |
78 | <tr class="{cycle values="impair,pair"}"> |
79 | <td colspan='4' class="center"> |
80 | <input type='hidden' name='frm_id' value='{$smarty.post.frm_id}' /> |
81 | <input type='hidden' name='action' value='{$smarty.post.action}' /> |
82 | <input type='hidden' name='act' value='' /> |
83 | <input type='hidden' name='gid' value='' /> |
84 | <input type='submit' name='gr_sub' value='Sauver' /> |
85 | </td> |
86 | </tr> |
87 | </table> |
88 | </form> |
89 | |
90 | {* vim:set et sw=2 sts=2 sws=2: *} |