source: trunk/root/templates/admin/default.tt @ 34

Last change on this file since 34 was 34, checked in by nanardon, 15 years ago
  • voting identifier is now the email
File size: 3.0 KB
Line 
1[% vote = c.model('Vote') %]
2
3[% IF vote.vote_status(voteid) == 'BEFORE' %]
4<table border="1">
5<tr><th>Vote</th><th>Possibilité de vote</th></tr>
6<tr>
7<td valign="TOP">
8<form action="[% c.uri_for(voteid) %]">
9
10[% thisvote = vote.vote_info(voteid) %]
11
12Label: <input type="text" name="label" value="[% c.req.param('label') || thisvote.label | html %]">
13<br>
14Description: <textarea name="description">[% c.req.param('description') || thisvote.description | html %]</textarea>
15<br>
16Debut du vote:
17<input type="text" name="start" value="[% c.req.param('start') || thisvote.start | html %]">
18<br>
19Fin du vote:
20<input type="text" name="end" value="[% c.req.param('end') || thisvote.end | html %]">
21<br>
22Nombre de choix possible:
23<input type="text" name="choice_count" value="[% c.req.param('choice_count') || thisvote.choice_count | html %]">
24<br>
25Nombre de choix libres:
26<input type="text" name="free_choice" value="[% c.req.param('free_choice') || thisvote.free_choice | html %]">
27<br>
28<input type="submit">
29</form>
30</td>
31<td valign="TOP">
32[% FOREACH choice = vote.vote_choices(voteid) %]
33<form action="[% c.uri_for(voteid) %]">
34[% loop.count %] - [% vote.choice_info(choice).label | html %]
35<input type="hidden" name="delch" value="[% vote.choice_info(choice).key %]">
36<input type="submit" name="del" value="Effacer">
37</form>
38<br>
39[% END %]
40<form action="[% c.uri_for(voteid) %]">
41Ajouter un choix:<br>
42<input type="text" name="addch">
43<input type="submit">
44</form>
45</td>
46</tr>
47</table>
48
49<hr>
50
51<table border="1">
52<tr>
53<td valign="TOP">
54[% signing = vote.vote_voting(voteid) %]
55[% FOREACH thisvoting = signing %]
56[% voting = vote.voting_info(thisvoting) %]
57<form action="[% c.uri_for(voteid) %]">
58<input type="hidden" name="delvoting" value="[% voting.vkey %]">
59[% voting.label | html %] [% voting.mail | html %]
60[% IF voting.passwd %]<i>(pass envoyé)</i>[% END %]
61<input type="submit" name="delete" value="delete"><br>
62</form>
63[% END %]
64</td>
65<td valign="TOP">
66<form action="[% c.uri_for(voteid) %]">
67Login: <input type="text" name="id"><br>
68Mail: <input type="text" name="mail"><br>
69<input type="submit">
70</form>
71<hr>
72<form method="POST" ENCTYPE="multipart/form-data" action="[% c.uri_for(voteid) %]">
73<input type="file" name="votinglist"><br>
74<input type="checkbox" name="delete">Effacer la liste des votants<br>
75<input type="submit">
76</form>
77<hr>
78<form action="[% c.uri_for(voteid) %]">
79<input type="submit" name="mailpasswd" value="Envoyer les mot de passe">
80</form>
81</td>
82</tr>
83</table>
84
85[% ELSE %]
86
87[% FOREACH bid = vote.list_vote_ballot_needvalid(voteid) %]
88    [% IF loop.first %]
89    <form action="[% c.uri_for(voteid) %]">
90    <table border="1">
91    [% END %]
92<tr>
93<td>[% bid %]</td>
94<td>
95[% FOREACH item = [ vote.ballot_items(bid) ] %]
96[% item.v %]<br>
97[% END %]
98</td>
99<td>
100<input type="radio" name="[% bid %]" value="valid">est valide<br>
101<input type="radio" name="[% bid %]" value="invalid">n'est pas valide<br>
102</td>
103</tr>
104    [% IF loop.last %]
105    </table>
106    <input type="submit">
107    </form>
108    [% END %]
109[% END %]
110[% END %]
Note: See TracBrowser for help on using the repository browser.