migrate events.
[platal.git] / templates / xnet / groupe / evenements.tpl
CommitLineData
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
23<h1>{$asso.nom} :
0337d704 24Evénements
0337d704 25</h1>
26
27{if !$logged}
28 <p class="descr">
29 Aucune manifestation publique n'a été saisie par ce groupe pour l'instant...
30 </p>
0337d704 31{else}
32
bd46a8e4 33{if $admin}
34<p class="center">
35[<a href="{rel}/{$platal->ns}events/edit">Annoncer un nouvel événement</a>]
36</p>
37{/if}
0337d704 38
bd46a8e4 39{if !$evenements}
0337d704 40
bd46a8e4 41<p class="descr">
42 Aucun événement n'a été référencé par les animateurs du groupe.
43</p>
0337d704 44
bd46a8e4 45{else}
0337d704 46
bd46a8e4 47<form action="{rel}/{$platal->ns}events" method="post">
258b9710 48 {foreach from=$evenements item=e}
bd46a8e4 49 <table class="bicol" cellspacing="0" cellpadding="0">
05370ed3 50 <tr {popup caption=$e.intitule" text=$e.descriptif}>
0337d704 51 <th colspan="2">
52 {$e.intitule}
0337d704 53 {if $admin}
bd46a8e4 54 <a href="{rel}/{$platal->ns}events/edit/{$e.eid}?mod=1"><img src="{rel}/images/profil.png" title="Edition de l'événement" alt="Edition de l'événement" /></a>
55 <a href="{rel}/{$platal->ns}events/edit/{$e.eid}?sup=1" onclick="return confirm('Supprimer l\'événement effacera la liste des inscrits et des paiements.\n Es-tu sûr de vouloir supprimer l\'événement ?')"><img src="{rel}/images/del.png" alt="Suppression de {$e.intitule}" title="Suppression de {$e.intitule}" /></a>
0337d704 56 {/if}
57 </th>
58 </tr>
258b9710 59 <tr {popup caption=$e.intitule text=$e.descriptif}>
0337d704 60 <td class="titre">date :</td>
61 <td>
258b9710 62 {if $e.fin and $e.fin neq $e.debut}
63 {if $e.debut_day eq $e.fin_day}
64 le {$e.debut|date_format:"%d %B %Y"} de {$e.debut|date_format:"%H:%M"} à {$e.fin|date_format:"%H:%M"}
65 {else}
66 du {$e.debut|date_format:"%d %B %Y à %H:%M"}<br />
67 au {$e.fin|date_format:"%d %B %Y à %H:%M"}
68 {/if}
0337d704 69 {else}
258b9710 70 le {$e.debut|date_format:"%d %B %Y à %H:%M"}
0337d704 71 {/if}
72 </td>
73 </tr>
258b9710 74 <tr {popup caption=$e.intitule text=$e.descriptif}>
0337d704 75 <td class="titre">annonceur :</td>
76 <td>
e8599c21 77 <a href='https://polytechnique.org/profile/{$e.alias}' class='popup2'>{$e.prenom} {$e.nom} ({$e.promo})</a>
0337d704 78 </td>
79 </tr>
258b9710 80 {if $admin || $e.show_participants}
81 <tr {popup caption=$e.intitule text=$e.descriptif}>
82 <td class="titre" colspan="2">
bd46a8e4 83 <a href="{rel}/{$platal->ns}events/admin/{$e.eid}">
258b9710 84 Liste des participants
85 <img src="{rel}/images/loupe.gif" title="Liste des participants" alt="Liste des participants" />
86 </a>
0337d704 87 </td>
88 </tr>
258b9710 89 {/if}
90 {assign var="montant" value=0}
91 {if !$e.membres_only or $is_member or $e.inscrit}
92 {if $e.inscr_open}
93 <tr>
94 <td colspan="2">
95 Je viendrai...
96 <input type="hidden" name="evt_{counter}" value="{$e.eid}" />
97 </td>
98 </tr>
99 {/if}
100 {iterate from=$e.moments item=m}
101 {assign var="montant" value=$montant+$m.montant*$m.nb}
102 <tr {if $m.titre or $m.details or $m.montant}{popup caption="`$m.titre` (`$m.montant` &#x20AC;)" text=" `$m.details` "}{/if}>
103 <td>{$m.titre}</td>
104 <td>
105 {if $e.inscr_open}
106 <input type="radio" name="moment{$e.eid}_{$m.item_id}" value="0"
107 {if !$m.nb}checked="checked"{/if}/>non
a8c3c073 108 {if $e.noinvite}
109 <input type="radio" name="moment{$e.eid}_{$m.item_id}" value="1"
110 {if $m.nb eq 1}checked="checked"{/if}/>oui
111 {else}
112 <input type="radio" name="moment{$e.eid}_{$m.item_id}" value="1"
113 {if $m.nb eq 1}checked="checked"{/if}/>seul<br />
114 <input type="radio" name="moment{$e.eid}_{$m.item_id}" value="2"
115 {if $m.nb > 1}checked="checked"{/if}/>avec <input size="2" name="personnes{$e.eid}_{$m.item_id}" value="{if $m.nb > 1}{math equation="x - y" x=$m.nb y=1}{else}1{/if}"/> personnes
116 {/if}
258b9710 117 {else}
118 {if !$m.nb}
d8aa3c51 119 Je ne viendrai pas.
258b9710 120 {elseif $m.nb eq 1}
a8c3c073 121 Je viendrai{if !$e.noinvite} seul{/if}.
258b9710 122 {else}
d8aa3c51 123 Je viendrai avec {$m.nb} personne{if $m.nb > 2}s{/if}
258b9710 124 {/if}
125 {/if}
126 </td>
127 </tr>
128 {/iterate}
129 {if $e.deadline_inscription}
130 <tr>
131 <td colspan="2" class="center">
132 {if $e.inscr_open}
133 dernières inscriptions
134 le {$e.deadline_inscription|date_format:"%d %B %Y"}
135 {else}
136 Inscriptions closes.
137 {/if}
138 </td>
139 </tr>
140 {/if}
141 {if $montant > 0 || $e.paid > 0}
142 <tr>
143 <td colspan="2" {if $montant > $e.paid}class="erreur"{/if}>
144 Tu dois payer {$montant|replace:'.':','}&nbsp;&euro;{if $e.paid > 0}, et tu as déjà payé {$e.paid|replace:'.':','}&nbsp;&euro;{/if}.
145 {if $e.paiement_id && $montant > $e.paid}
a2558f2b 146 [<a href="https://www.polytechnique.org/payment/{$e.paiement_id}?montant={math equation="x - y" x=$montant y=$e.paid}">Payer en ligne</a>]
258b9710 147 {/if}
148 </td>
149 </tr>
150 {/if}
151 {/if}
0337d704 152 </table>
258b9710 153 {if (!$e.membres_only or $is_member or $e.inscrit) and $e.inscr_open}
154 <p style="text-align:center">
155 <input type="submit" value="Valider mes inscriptions" />
156 </p>
82ab5344 157 {else}
158 <p>&nbsp;</p>
258b9710 159 {/if}
160 {/foreach}
0337d704 161
258b9710 162 <div>
163 <input type="hidden" name="ins" />
164 </div>
bd46a8e4 165</form>
166{/if}
0337d704 167
168{/if}
169
170{* vim:set et sw=2 sts=2 sws=2: *}