Use smarty plugins in mail templates.
[platal.git] / templates / xnetevents / admin.tpl
CommitLineData
0337d704 1{**************************************************************************}
2{* *}
5ddeb07c 3{* Copyright (C) 2003-2007 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
a7de4ef7 23<h1>{$asso.nom} : <a href='{$platal->ns}events'>Evénements</a> </h1>
0337d704 24
25<p>
40ca91d2
FB
26L'événement {$evt.intitule}
27{if $evt.titre} - {$evt.titre}
28{/if}
29{if $evt.titre || count($moments) eq 0}
30comptera {$evt.nb_tot} personne{if $evt.nb_tot > 1}s{/if}.
31{else}
32({$evt.nb} personne{if $evt.nb > 1}s{/if} ont réalisé leur inscription).
33{/if}
0337d704 34</p>
35
e7268252 36{if $evt.participant_list && $is_admin}
0337d704 37<p class="center">
a7de4ef7 38[<a href="mailto:?bcc={$evt.short_name}-participants@{#globals.xnet.evts_domain#}">envoyer un mail à ceux qui viennent</a>]
76bbde1c 39-
7d73bb7b 40[<a href="mailto:?bcc={$evt.short_name}-absents@{#globals.xnet.evts_domain#}">envoyer un mail aux membres non inscrits</a>]
0337d704 41</p>
42{/if}
43
5070a22d 44{if count($moments) > 1}
0337d704 45<p class="center">
f6bdd218 46[<a href="{$platal->ns}events/admin/{$evt.short_name|default:$evt.eid}"{if !$platal->argv[2]}class="erreur"{/if}>tout</a>]
0337d704 47{foreach from=$moments item=m}
f6bdd218 48[<a href="{$platal->ns}events/admin/{$evt.short_name|default:$evt.eid}/{$m.item_id}" {if $platal->argv[2] eq $m.item_id}class="erreur"{/if}>{$m.titre}</a>]
0337d704 49{/foreach}
50</p>
51{/if}
52
53<p class="center">
e979cd2b 54[<a href="{$platal->pl_self()}" {if !$smarty.request.initiale}class="erreur"{/if}>tout</a>]
0337d704 55{foreach from=$alphabet item=c}
e979cd2b 56[<a href="{$platal->pl_self()}?initiale={$c}"{if $smarty.request.initiale eq $c} class="erreur"{/if}>{$c}</a>]
0337d704 57{/foreach}
58</p>
59
d24c8a11 60{if $is_admin}{literal}
0337d704 61<script type="text/javascript">
62function remplitAuto(mail) {
63 document.getElementById('inscription').mail.value=mail;
8919c4e1 64 var f = document.getElementById('montant');
65 if (f)
66 f.mail.value=mail;
0337d704 67}
68</script>
69{/literal}
70
71{if $oublis}
72<p class="erreur">
a7de4ef7 73Ils ont payé mais ont oublié de s'inscrire :
0337d704 74</p>
75
a7de4ef7 76<table summary="payé mais non inscrits" class="tinybicol">
0337d704 77 <tr>
a7de4ef7 78 <th>Prénom NOM</th>
0337d704 79 <th>Promo</th>
80 <th>Infos</th>
81 <th>Montant</th>
82 </tr>
83 {iterate from=$oubliinscription item=m}
98a7e9dc 84 <tr class="pair">
0337d704 85 <td>
d24c8a11 86 <a href="" {if $is_admin}onclick="return remplitAuto('{$m.email}')"{/if}>
88547449
FB
87 {if !$m.prenom && !$m.nom}
88 {$m.email}
89 {else}
90 {$m.prenom} {$m.nom}
91 {/if}
0337d704 92 </a>
93 </td>
94 <td>{$m.promo}</td>
95 <td>
7ac1ef77 96 <a href="https://www.polytechnique.org/profile/{$m.email}">{icon name=user_suit title="fiche"}</a>
97 <a href="https://www.polytechnique.org/vcard/{$m.email}.vcf">{icon name=vcard title="vcard"}</a>
7d73bb7b 98 <a href="mailto:{$m.email}@{#globals.mail.domain#}">{icon name=email title="mail"}</a>
0337d704 99 </td>
100 <td>{$m.montant}</td>
101 </tr>
102 {/iterate}
103</table>
104
105<hr />
106{/if}
107
108{/if}
109
110<table summary="participants a l'evenement" class="{if $tout}large{else}tiny{/if}">
111 <tr>
40ca91d2 112 {if $is_admin && $evt.paiement_id && $tout}
58591700 113 {assign var=height value='rowspan="2"'}
114 {/if}
115 <th {$height|smarty:nodefaults}>Prénom NOM</th>
116 <th {$height|smarty:nodefaults}>Promo</th>
117 <th {$height|smarty:nodefaults}>Info</th>
0337d704 118 {if $tout}
b479e26b 119 {if $moments}
120 {foreach from=$moments item=m}
58591700 121 <th {$height|smarty:nodefaults}>{$m.titre}</th>
b479e26b 122 {/foreach}
123 {else}
58591700 124 <th {$height|smarty:nodefaults}>Nombre</th>
b479e26b 125 {/if}
d24c8a11 126 {if $is_admin && $evt.money}
58591700 127 <th {$height|smarty:nodefaults}>Montant</th>
128 <th colspan="3">Payé</th>
0337d704 129 {/if}
130 {else}
58591700 131 <th {$height|smarty:nodefaults}>Nombre</th>
0337d704 132 {/if}
133 </tr>
40ca91d2 134 {if $is_admin && $evt.paiement_id && $tout}
58591700 135 <tr>
136 <th>Télépaiement</th>
137 <th>Autre</th>
138 <th>Total</th>
139 </tr>
140 {/if}
0337d704 141 {foreach from=$participants item=m}
ed21e24a 142 <tr>
0337d704 143 <td>
f97a955b 144 {if $is_admin}<a href="javascript:remplitAuto('{$m.email}')">{/if}
88547449 145 {if $m.femme}&bull;{/if}{if !$m.prenom && !$m.nom}{$m.email}{else}{$m.prenom} {$m.nom}{/if}
f97a955b 146 {if $is_admin}</a>{/if}
0337d704 147 </td>
148 <td>{$m.promo}</td>
149 <td>
150 {if $m.x}
7ac1ef77 151 <a href="https://www.polytechnique.org/profile/{$m.email}">{icon name=user_suit title="fiche"}</a>
152 <a href="https://www.polytechnique.org/vcard/{$m.email}.vcf">{icon name=vcard title="vcard"}</a>
7d73bb7b 153 <a href="mailto:{$m.email}@{#globals.mail.domain#}">{icon name=email title="mail"}</a>
0337d704 154 {else}
f7413044 155 <a href="mailto:{$m.email}">{icon name=email title="mail"}</a>
0337d704 156 {/if}
157 </td>
158 {if $tout}
b479e26b 159 {if $moments}
160 {foreach from=$moments item=i}
161 <td>{$m[$i.item_id]}</td>
162 {/foreach}
163 {else}
164 <td>{$m[1]}</td>
165 {/if}
d24c8a11 166 {if $is_admin && $evt.money}
0337d704 167 <td {if $m.montant > $m.paid}class="erreur"{/if}>{$m.montant}&euro;</td>
58591700 168 {if $evt.paiement_id}
169 <td>{$m.telepayment|default:0}&euro;</td>
170 <td>{$m.adminpaid|default:0}&euro;</td>
171 {/if}
172 <td {if $m.montant < $m.paid}class="erreur"{/if}>{$m.paid}&euro;</td>
0337d704 173 {/if}
174 {else}
175 <td>
176 {$m.nb}
177 </td>
178 {/if}
179 </tr>
180 {/foreach}
181</table>
182
183<p class="descr">
184{foreach from=$links item=ofs key=txt}
e979cd2b 185<a href="{$platal->pl_self()}?offset={$ofs}&amp;initiale={$smarty.request.initiale}"{if $smarty.request.offset eq $ofs} class="erreur"{/if}>{$txt}</a>
0337d704 186{/foreach}
187</p>
188
61664f8b 189{if $absents->total()}
190
191<hr />
192
193<p>Les personnes suivantes ont indiqué qu'elles ne viendraient pas à l'événement&nbsp;:</p>
194
195<table class="tinybicol">
196 <tr><th>Prénom NOM</th><th>Origine</th></tr>
197 {iterate from=$absents item=m}
198 <tr>
199 <td>
adcc7deb 200 {if $is_admin}<a href="javascript:remplitAuto('{$m.email}')">{/if}
61664f8b 201 {if $m.sexe}&bull;{/if}{$m.prenom} {$m.nom}
adcc7deb 202 {if $is_admin}</a>{/if}
61664f8b 203 </td>
204 <td>
205 {$m.promo}
206 </td>
207 </tr>
208 {/iterate}
209</table>
210
211{/if}
212
d24c8a11 213{if $is_admin}
0337d704 214
215<p class="descr">
a7de4ef7 216[<a href="{$platal->ns}events/csv/{$evt.eid}/{$platal->argv[2]}/{$evt.intitule}{if $evt.titre}.{$evt.titre}{/if}.csv">Télécharger le fichier Excel</a>]
0337d704 217</p>
218
219<hr />
220
221<p class="descr">
a7de4ef7 222En tant qu'administrateur, tu peux fixer la venue (accompagnée ou pas) d'un des membres du groupe.
ed21e24a 223Donne ici son mail, ainsi que le nombre de participants.
0337d704 224</p>
225
e979cd2b 226<form action="{$platal->pl_self()}" method="post" id="inscription">
0337d704 227 <p class="descr">
ed21e24a 228 <input type="hidden" name="adm" value="nbs" />
bd46a8e4 229
ed21e24a 230 Mail: <input name="mail" size="20" />
231
232 {if $platal->argv[2]}
233 {$evt.titre}: <input name="nb[{$platal->argv[2]}]" size="1" value="1" />
b479e26b 234 {else}
ed21e24a 235 {foreach from=$moments item=m}
236 {$m.titre}: <input name="nb[{$m.item_id}]" size="1" value="1"/>
237 {foreachelse}
238 Nombre: <input name="nb[1]" size="1" value="1" />
239 {/foreach}
b479e26b 240 {/if}
ed21e24a 241 <input type="submit" />
0337d704 242 </p>
243</form>
244
ed21e24a 245{if $evt.money}
246
0337d704 247<hr />
248
249<p class="descr">
a7de4ef7 250En tant qu'administrateur, tu peux entrer un paiement reçu par une autre source que le télépaiement
251du site X.org. Ce montant s'ajoutera aux montants déjà entrés. Si tu as fait une erreur, tu peux
252entrer un montant négatif.
0337d704 253</p>
254
255<p class="descr">
256Note que tu peux cliquer sur les noms des membres pour remplir automatiquement la case ci-dessous
257</p>
258
e979cd2b 259<form action="{$platal->pl_self()}" method="post" id="montant">
0337d704 260 <p class="descr">
0337d704 261 <input type="hidden" name="adm" value="prix" />
262 Mail: <input name="mail" size="20" />
263 montant: <input name="montant" size="3" value="0,00" /> &euro;
264 <input type="submit" />
265 </p>
266</form>
267{/if}
268
ed21e24a 269{/if}
270
a7de4ef7 271{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}