Fix auth issues with Ajax
[platal.git] / templates / xnetevents / index.tpl
CommitLineData
d6d580ec 1{**************************************************************************}
2{* *}
3{* Copyright (C) 2003-2006 Polytechnique.org *}
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
f02eefd4 23{if !$admin}
d6d580ec 24<h1>{$asso.nom} : Evénements</h1>
f02eefd4 25{else}
26<h1>
27 {$asso.nom} :
28 {if $archive}[<a href="{$platal->ns}events">Evénements</a>] {else}Evénements {/if}
29 {if $archive}Archives {else}[<a href="{$platal->ns}events/archive">Archives</a>] {/if}
30</h1>
d6d580ec 31
99544d53 32{if !$archive}
d6d580ec 33<p class="center">
7b2413f6 34 [<a href="{$platal->ns}events/edit">Annoncer un nouvel événement</a>]
d6d580ec 35</p>
36{/if}
99544d53 37{/if}
d6d580ec 38
39{foreach from=$evenements item=e}
40
7ac1ef77 41<table class="bicol" cellspacing="0" cellpadding="0">
d6d580ec 42 <colgroup>
43 <col width='25%' />
44 </colgroup>
45 <tr>
cb24457f 46 <th colspan="2"{if !$e.inscr_open} class="grayed"{/if}>
99544d53 47 <a href="{$platal->ns}events/ical/{$e.eid}/{$e.short_name}.ics" style="display: block; float: left;">
48 {icon name=calendar_view_day title="Evénement iCal"}
11d8a183 49 </a>
99544d53 50 {$e.intitule}
cb24457f 51 {if !$e.inscr_open}
52 (<span class="error">Inscriptions closes</span>)
53 {/if}
d6d580ec 54 {if $admin}
55 <br />
7b2413f6 56 [<a href="{$platal->ns}events/edit/{$e.eid}">
d6d580ec 57 modifier
25edb442 58 {icon name=date_edit title="Edition de l'événement"}</a>]
f02eefd4 59 &nbsp;
60 [<a href="javascript:dynpostkv('{$platal->pl_self()}', {if !$archive}'archive'{else}'unarchive'{/if}, {$e.eid})">
61 {if !$archive}
62 archiver
63 {icon name=package_add title="Archivage"}</a>]
64 {else}
65 désarchiver
66 {icon name=package_delete title="Désarchivage"}</a>]
67 {/if}
68 &nbsp;
7b2413f6 69 [<a href="javascript:dynpostkv('{$platal->ns}events', 'del', {$e.eid})"
d6d580ec 70 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 ?')">
71 supprimer
a72a67b9 72 {icon name=delete title='Suppression'}</a>]
d6d580ec 73 {/if}
74 </th>
75 </tr>
76
77 <tr>
78 <td class="titre">date :</td>
79 <td>
80 {if $e.fin and $e.fin neq $e.debut}
81 {if $e.debut_day eq $e.fin_day}
82 le {$e.debut|date_format:"%d %B %Y"} de {$e.debut|date_format:"%H:%M"} à {$e.fin|date_format:"%H:%M"}
83 {else}
84 du {$e.debut|date_format:"%d %B %Y à %H:%M"}<br />
85 au {$e.fin|date_format:"%d %B %Y à %H:%M"}
86 {/if}
87 {else}
88 le {$e.debut|date_format:"%d %B %Y à %H:%M"}
89 {/if}
90 </td>
91 </tr>
92
93 <tr>
94 <td class="titre">annonceur :</td>
95 <td>
1f0d8e19 96 <a href='https://www.polytechnique.org/profile/{$e.alias}' class='popup2'>{$e.prenom} {$e.nom} ({$e.promo})</a>
d6d580ec 97 </td>
98 </tr>
99
cb24457f 100 {if $admin || $e.show_participants || ($e.deadline_inscription && $e.inscr_open)}
d6d580ec 101 <tr>
102 <td class="titre">Informations :</td>
103 <td class='actions'>
104 {if $admin || $e.show_participants}
7b2413f6 105 <a href="{$platal->ns}events/admin/{$e.eid}">
d6d580ec 106 consulter la liste des participants
7ac1ef77 107 {icon name=group title="Liste des participants"}
d6d580ec 108 </a><br />
109 {/if}
cb24457f 110 {if $e.deadline_inscription && $e.inscr_open}
111 dernières inscriptions
112 le {$e.deadline_inscription|date_format:"%d %B %Y"}
d6d580ec 113 {/if}
114 </td>
115 </tr>
cb24457f 116 {/if}
d6d580ec 117
118 <tr>
119 <td class="titre">
120 État inscription
121 {if $e.inscr_open}
122 <input type="hidden" name="evt_{counter}" value="{$e.eid}" />
123 {/if}
124 </td>
125 <td>
126 {if !$e.inscrit}
127 <span class='error'>Non inscrit</span><br />
128 {else}
129 {foreach from=$e.moments item=m}
130 {if !$m.nb}
131 Tu ne viendras pas
132 {elseif $m.nb eq 1}
133 Tu viendras seul
134 {else}
135 Tu viendras avec {$m.nb} personne{if $m.nb > 2}s{/if}
136 {/if} à <em>{$m.titre}</em><br />
137 {/foreach}
138 {/if}
139
140 {if $e.topay}
141 <span class="error">
142 Tu dois payer {$e.topay|replace:'.':','}&nbsp;&euro;
143 {if $e.paid > 0}
144 (tu as déjà payé {$e.paid|replace:'.':','}&nbsp;&euro;)
145 {/if}
146 {if $e.paiement_id}
147 [<a href="https://www.polytechnique.org/payment/{$e.paiement_id}?montant={$e.topay}}">
148 Payer en ligne</a>]
149 {/if}
150 </span>
151 {/if}
152 </td>
153 </tr>
154
9ece1588 155 {if $e.inscr_open}
d6d580ec 156 <tr>
157 <td colspan='2' class='center'>
158 <strong>
7b2413f6 159 <a href='{$platal->ns}events/sub/{$e.eid}'>
d6d580ec 160 gérer mon inscription
161 </a>
162 </strong>
163 </td>
164 </tr>
165 {/if}
166
167</table>
168
169<br />
170
171{foreachelse}
172
99544d53 173
d6d580ec 174<p class="descr">
99544d53 175{if $archive}
176 Aucun événement n'a été archivé par les animateurs du groupe.
177{else}
d6d580ec 178 Aucun événement n'a été référencé par les animateurs du groupe.
99544d53 179{/if}
d6d580ec 180</p>
181
182{/foreach}
183
99544d53 184{if $evenements}
185<p class="descr">
186 En cliquant sur l'icône {icon name=calendar_view_day title="Evénement iCal"} associée à un événement
187 tu peux télécharger la version iCal de l'événement qui permet de l'ajouter dans ton agenda électronique
188</p>
189{/if}
190
d6d580ec 191{* vim:set et sw=2 sts=2 sws=2: *}