Merge commit 'origin/fusionax' into account
[platal.git] / templates / events / index.tpl
CommitLineData
0337d704 1{**************************************************************************}
2{* *}
8d84c630 3{* Copyright (C) 2003-2009 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
0337d704 23{if $ask_naissance}
24
25{include file='include/form_naissance.tpl'}
26
27{else}
28
1f7c3690 29<h1 id='pagetop'>
4182c6b5 30Bienvenue {$smarty.session.display_name}{if $birthday}
9e92370d 31 &nbsp;et joyeux anniversaire de la part de toute l'équipe !
d8de39c2 32{else},
0337d704 33{/if}
34</h1>
35
ccdbc270 36{if $smarty.session.host}
0337d704 37<div class="smaller">
d8de39c2 38 {if $birthday}T{else}t{/if}a connexion précédente date du
9e1743cd 39 <strong>{$smarty.session.lastlogin|date_format:"%x, %X"}</strong>
9e92370d 40 depuis la machine <strong>{$smarty.session.host}</strong>.
0337d704 41</div>
ccdbc270 42{/if}
43
44{if $smarty.session.no_redirect}
44b071c2
SJ
45<div class="errors">
46 <ul>
47 <li>
48 Tu n'as plus de redirection valide ce qui rend ton adresse Polytechnique.org
49 inutilisable. Rends-toi au plus vite sur <a href="emails/redirect">la page de
50 gestion des emails</a> pour corriger ce problème.
51 </li>
52 </ul>
53</div>
ccdbc270 54{/if}
55
3083bd93 56{if $smarty.session.mx_failures|@count}
44b071c2
SJ
57<div class="warnings">
58 {icon name=error} Des problèmes sont actuellement recontrés sur tes redirections suivantes :
59 <ul>
60 {foreach from=$smarty.session.mx_failures item=mail}
61 <li>
62 <span class="erreur">{$mail.mail}</span> :
63 <span class="explication">{$mail.text}</span>
64 </li>
65 {/foreach}
66 </ul>
67 <div style="text-align: center"><a href="emails/redirect">Gérer mes adresses de redirection</a></div>
68</div>
ccdbc270 69{/if}
70
44b071c2
SJ
71{if $fiche_incitation || $photo_incitation || ($geoloc_incitation > 0)}
72<div class="warnings">
73 <ul>
0337d704 74{if $fiche_incitation}
44b071c2
SJ
75 <li>
76 La dernière mise à jour de ta
c52838d6 77 <a href="profile/{$smarty.session.hruid}" class="popup2">fiche</a>
44b071c2
SJ
78 date du {$fiche_incitation|date_format}.
79 Il est possible qu'elle ne soit pas à jour.
80 Si tu souhaites la modifier, <a href="profile/edit">clique ici !</a>
81 </li>
0337d704 82{/if}
83
84{if $photo_incitation}
44b071c2 85 <li>
0337d704 86 Tu n'as pas mis de photo de toi sur ta fiche, c'est dommage.
7b2413f6 87 Clique <a href="photo/change">ici</a> si tu souhaites en ajouter une.
44b071c2 88 </li>
0337d704 89{/if}
90
91{if $geoloc_incitation > 0}
44b071c2 92 <li>
2f678da1 93 Parmi tes adresses, il y en a {$geoloc_incitation} que nous n'avons pas pu localiser.
7b2413f6 94 Clique <a href="profile/edit/adresses">ici</a> pour rectifier.
44b071c2
SJ
95 </li>
96{/if}
97 </ul>
98</div>
0337d704 99{/if}
0337d704 100
dc767839 101{include file="include/tips.tpl" full=true}
f75b2292 102
02838718 103 <table class="tinybicol" id="menu-evts">
104 {foreach from=$events name=events key=category item=evenement}
105 <tr class="pair" style="height: 18px">
106 <td class="half titre" style="height: 18px; padding-top: 1px; padding-bottom: 1px;">
107 {if $smarty.foreach.events.first}
84fc72ff
FB
108 {if $smarty.session.token}
109 <a href="rss/{$smarty.session.hruid}/{$smarty.session.token}/rss.xml" style="display:block;float:right" title="Annonces">
2200e510 110 {icon name=feed title='fil rss'}
111 </a>
112 {else}
113 <a href='prefs/rss?referer=events' style="display:block;float:right">
114 {icon name=feed_add title='Activer mon fil rss'}
115 </a>
02838718 116 {/if}
117 {/if}
9ed396c0 118 {if $category eq 'important'}
119 {icon name=error} Informations prioritaires&nbsp;:
120 {elseif $category eq 'news'}
d0e45ced 121 {icon name=bell} Nouvelles annonces&nbsp;:
122 {elseif $category eq 'end'}
123 {icon name=clock} Dernières minutes&nbsp;:
124 {else}
125 {icon name=magnifier} Mais encore...
126 {/if}
127 </td>
128 </tr>
c321aa99 129 {foreach item=ev from=$evenement}
d0e45ced 130 <tr class="impair">
f75b2292 131 <td class="half">
132 &bull;
a4a3af33 133 <a href="events{if !$ev.nonlu}/unread/{$ev.id}{else}#newsid{$ev.id}{/if}" id="link-evt{$ev.id}">
f75b2292 134 {if $ev.nonlu}<strong>{/if}
135 {tidy}
136 {$ev.titre|nl2br}
137 {/tidy}
138 {if $ev.nonlu}</strong>{/if}
139 </a>
140 </td>
141 </tr>
679c68da 142 {assign var="has_evts" value=true}
c321aa99 143 {/foreach}
d0e45ced 144 {/foreach}
679c68da 145 {if !$has_evts}
146 <tr>
4c5aa36a 147 <td class="half">
84fc72ff
FB
148 {if $smarty.session.token}
149 <a href="rss/{$smarty.session.hruid}/{$smarty.session.token}/rss.xml" style="display:block;float:right" title="Annonces">
4c5aa36a
FB
150 {icon name=feed title='fil rss'}
151 </a>
152 {else}
153 <a href='prefs/rss?referer=events' style="display:block;float:right">
154 {icon name=feed_add title='Activer mon fil rss'}
155 </a>
156 {/if}
157 Aucun article actuellement
158 </td>
679c68da 159 </tr>
160 {/if}
f75b2292 161 </table>
162
a4a3af33 163 <script type="text/javascript">
164 {literal}
20ac3913 165 <!--
a4a3af33 166 function readEvent(id) {
167 document.getElementById('content-evt'+id).style.display='none';
168 var link = document.getElementById('link-evt'+id);
169 link.setAttribute('href','events/unread/'+id);
170 for (var i=0; i < link.childNodes.length; i++)
171 if (link.childNodes[i].nodeName == 'STRONG') {
172 link.replaceChild(link.childNodes[i].firstChild,link.childNodes[i]);
173 }
174 Ajax.update_html(null, 'events/read/'+id);
175 return false;
176 }
20ac3913 177 -->
a4a3af33 178 {/literal}
179 </script>
d0e45ced 180
181 {foreach from=$events key=category item=evenement}
c321aa99
FB
182 {foreach item=ev from=$evenement}
183 {if $ev.nonlu}
a4a3af33 184 <div id="content-evt{$ev.id}">
8e95ff41 185 <br />
186
187 <table class="bicol">
188 <tr>
189 <th>
d0e45ced 190 <div style="float: left">
9ed396c0 191 {if $category eq 'important'}
192 {icon name=error title="Important"}
193 {elseif $category eq 'news'}
d0e45ced 194 {icon name=bell title="Nouvelle annonce"}
195 {elseif $category eq 'end'}
196 {icon name=clock title="Bientôt fini"}
197 {else}
198 {icon name=magnifier title="Annonce"}
199 {/if}
200 </div>
8e95ff41 201 <div style="float:right">
908db125 202 {if hasPerm('admin')}
8e95ff41 203 <a href="admin/events/edit/{$ev.id}">{icon name=page_edit title="Editer cet article"}</a>
204 {/if}
a4a3af33 205 <a href="events/read/{$ev.id}{if $previd}/newsid{$previd}{/if}" onclick="return readEvent('{$ev.id}')">{icon name=cross title="Cacher cet article"}</a>
8e95ff41 206 </div>
207 {assign var="previd" value=$ev.id}
208 <a id="newsid{$ev.id}"></a>
209 {tidy}
210 {$ev.titre|nl2br}
211 {/tidy}
212 </th>
213 </tr>
02838718 214 {cycle values="left,right" assign=position}
215 <tr class="impair">
216 <td class="half">
217 <div>
b2bffbe6 218 {if $ev.img}
02838718 219 <div style="float: {$position}; padding-{if $position eq right}left{else}right{/if}: 0.5em">
220 <img src="events/photo/{$ev.id}" alt="{$ev.title}" />
221 </div>
b2bffbe6 222 {/if}
02838718 223 <div style="text-align: justify">
794feea7 224 {if !$ev.wiki}
47ea918c 225 {$ev.texte|smarty:nodefaults|nl2br}
794feea7
FB
226 {else}
227 {$ev.texte|miniwiki|smarty:nodefaults}
228 {/if}
02838718 229 </div>
230 </div>
231 </td>
232 </tr>
233 <tr class="pair">
b2bffbe6 234 <td class="half smaller">
235 <div style="display:block; float: right; padding-left:1em">
b2bffbe6 236 {if $ev.post_id}
237 <a href="banana/{#globals.banana.event_reply#|default:#globals.banana.event_forum#}/read/{$ev.post_id}">
238 {icon name="comments" title="Discussion"}Suivre la discussion
239 </a> &bull;
240 {/if}
241 <a href="events#pagetop">
242 <img alt="Sommaire" title="Remonter tout en haut" src="images/up.png"/>
02838718 243 </a>
b2bffbe6 244 </div>
a087cc8d 245 Annonce proposée par {profile user=$ev.user_id sex=false promo=true}
8e95ff41 246 </td>
247 </tr>
248 </table>
a4a3af33 249 </div>
c321aa99
FB
250 {/if}
251 {/foreach}
d0e45ced 252 {/foreach}
8e95ff41 253
0337d704 254 <p class="smaller">
e8439508 255 Nota Bene&nbsp;: les informations présentées ici n'engagent que leurs auteurs
a7de4ef7 256 respectifs et sont publiées à leur initiative. L'association Polytechnique.org
257 ne pourrait en aucun cas être tenue responsable de la nature des propos relatés
258 sur cet espace d'expression et d'information. Elle se réserve le droit de
259 refuser ou de retirer toute information de nature diffamante ou pouvant être
260 interprétée comme polémique par un membre de la communauté polytechnicienne.
0337d704 261 </p>
262
d1c97e42 263 <p class="center">
1970c12b 264 {icon name=page_edit}&nbsp;
a7de4ef7 265 <a href="events/submit">Proposer une information événementielle</a>&nbsp;&bull;
1970c12b 266 <a href="nl/submit">Proposer un article pour la Lettre mensuelle</a>
0337d704 267 </p>
0337d704 268{/if}
269
a7de4ef7 270{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}