Fix wiki cache generation with wiki_require_page on HTTPS.
[platal.git] / modules / events.php
CommitLineData
74e0093f 1<?php
2/***************************************************************************
5ddeb07c 3 * Copyright (C) 2003-2007 Polytechnique.org *
74e0093f 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
22class EventsModule extends PLModule
23{
24 function handlers()
25 {
26 return array(
1a828cd4 27 'events' => $this->make_hook('ev', AUTH_COOKIE),
8fc4efa3 28 'rss' => $this->make_hook('rss', AUTH_PUBLIC, 'user', NO_HTTPS),
9ed396c0 29 'events/preview' => $this->make_hook('preview', AUTH_PUBLIC, 'user', NO_AUTH),
f62bd784 30 'events/photo' => $this->make_hook('photo', AUTH_PUBLIC),
1a828cd4 31 'events/submit' => $this->make_hook('ev_submit', AUTH_MDP),
92423144 32 'admin/events' => $this->make_hook('admin_events', AUTH_MDP, 'admin'),
b829e258 33
9ed396c0 34 'ajax/tips' => $this->make_hook('tips', AUTH_COOKIE, 'user', NO_AUTH),
dc767839 35 'admin/tips' => $this->make_hook('admin_tips', AUTH_MDP, 'admin'),
74e0093f 36 );
37 }
38
02838718 39 private function get_tips($exclude = null)
dc767839 40 {
6ce5dee4 41 global $globals;
42 // Add a new special tip when changing plat/al version
43 if ($globals->version != S::v('last_version') && is_null($exclude)) {
44 XDB::execute('UPDATE auth_user_quick
45 SET last_version = {?}
46 WHERE user_id = {?}',
47 $globals->version, S::i('uid'));
48 return array('id' => 0,
49 'titre' => 'Bienvenue sur la nouvelle version du site !',
50 'text' => 'Le site a été mis à jour depuis ta dernière visite vers la version ' . $globals->version
51 . '. Nous t\'invitons à en découvrir les nouveautés en te rendant sur '
52 . '<a href="banana/xorg.m4x.innovation">nos forums</a> ou en consultant '
16703e55
FB
53 . '<a href="changelog">la liste exhaustive des modifications</a>.<br /><br />'
54 . 'Tu peux également consulter le <a href="review">panorama des services</a> '
55 . 'fournis par le site.',
6ce5dee4 56 'priorite' => 255,
57 'promo_min' => 0,
58 'promo_max' => 0,
59 'state' => 'active',
60 'special' => true);
61 }
62
dc767839 63 $exclude = is_null($exclude) ? '' : ' AND id != ' . $exclude . ' ';
64 $priority = rand(0, 510);
65 do {
66 $priority = (int)($priority/2);
67 $res = XDB::query("SELECT *
68 FROM tips
69 WHERE (peremption = '0000-00-00' OR peremption > CURDATE())
70 AND (promo_min = 0 OR promo_min <= {?})
71 AND (promo_max = 0 OR promo_max >= {?})
72 AND (priorite >= {?})
5d617d8d 73 AND (state = 'active')
dc767839 74 $exclude
75 ORDER BY RAND()
76 LIMIT 1",
77 S::i('promo'), S::i('promo'), $priority);
78 } while ($priority && !$res->numRows());
79 if (!$res->numRows()) {
80 return null;
eaf30d86 81 }
dc767839 82 return $res->fetchOneAssoc();
83 }
84
02838718 85 private function get_events($where, $order, array &$array, $name)
d0e45ced 86 {
87 // affichage des evenements
88 // annonces promos triées par présence d'une limite sur les promos
89 // puis par dates croissantes d'expiration
90 $promo = S::v('promo');
eaf30d86 91 $uid = S::i('uid');
d0e45ced 92 $sql = "SELECT e.id,e.titre, ev.user_id IS NULL AS nonlu
93 FROM evenements AS e
94 LEFT JOIN evenements_vus AS ev ON (e.id = ev.evt_id AND ev.user_id = {?})
9ed396c0 95 WHERE FIND_IN_SET('valide', e.flags) AND peremption >= NOW()
d0e45ced 96 AND (e.promo_min = 0 || e.promo_min <= {?})
97 AND (e.promo_max = 0 || e.promo_max >= {?})
98 AND $where
99 ORDER BY $order";
100 $sum = XDB::iterator($sql, $uid, $promo, $promo);
101 if (!$sum->total()) {
102 return false;
103 }
b2bffbe6 104 $sql = "SELECT e.id,e.titre,e.texte,e.post_id,a.user_id,a.nom,a.prenom,a.promo,l.alias AS forlife,
794feea7 105 p.x, p.y, p.attach IS NOT NULL AS img, FIND_IN_SET('wiki', e.flags) AS wiki
02838718 106 FROM evenements AS e
107 LEFT JOIN evenements_photo AS p ON (e.id = p.eid)
108 INNER JOIN auth_user_md5 AS a ON e.user_id=a.user_id
109 INNER JOIN aliases AS l ON ( a.user_id=l.id AND l.type='a_vie' )
d0e45ced 110 LEFT JOIN evenements_vus AS ev ON (e.id = ev.evt_id AND ev.user_id = {?})
9ed396c0 111 WHERE FIND_IN_SET('valide', e.flags) AND peremption >= NOW()
d0e45ced 112 AND (e.promo_min = 0 || e.promo_min <= {?})
113 AND (e.promo_max = 0 || e.promo_max >= {?})
114 AND ev.user_id IS NULL
115 AND $where
116 ORDER BY $order";
117 $evt = XDB::iterator($sql, $uid, $promo, $promo);
118 $array[$name] = array('events' => $evt, 'summary' => $sum);
119 return true;
120 }
121
02838718 122 private function upload_image(PlatalPage &$page, PlUpload &$upload)
123 {
124 if (@!$_FILES['image']['tmp_name'] && !Env::v('image_url')) {
125 return true;
126 }
127 if (!$upload->upload($_FILES['image']) && !$upload->download(Env::v('image_url'))) {
128 $page->trig('Impossible de télécharger l\'image');
129 return false;
130 } elseif (!$upload->isType('image')) {
131 $page->trig('Le fichier n\'est pas une image valide au format JPEG, GIF ou PNG');
132 $upload->rm();
133 return false;
134 } elseif (!$upload->resizeImage(200, 300, 100, 100, 32284)) {
135 $page->trig('Impossible de retraiter l\'image');
136 return false;
137 }
138 return true;
139 }
140
096f0dca 141 function handler_ev(&$page, $action = 'list', $eid = null, $pound = null)
1a828cd4 142 {
8b1f8e12 143 $page->changeTpl('events/index.tpl');
dc767839 144 $page->addJsLink('ajax.js');
145 $page->assign('tips', $this->get_tips());
146
08cce2ff 147 $res = XDB::query('SELECT date, naissance FROM auth_user_md5
d0e45ced 148 WHERE user_id={?}', S::v('uid'));
1a828cd4 149 list($date, $naissance) = $res->fetchOneRow();
150
a7de4ef7 151 // incitation à mettre à jour la fiche
1a828cd4 152
153 $d2 = mktime(0, 0, 0, substr($date, 5, 2), substr($date, 8, 2),
154 substr($date, 0, 4));
155 if( (time() - $d2) > 60 * 60 * 24 * 400 ) {
156 // si fiche date de + de 400j;
157 $page->assign('fiche_incitation', $date);
158 }
159
160 // Souhaite bon anniversaire
161
162 if (substr($naissance, 5) == date('m-d')) {
163 $page->assign('birthday', date('Y') - substr($naissance, 0, 4));
164 }
165
a7de4ef7 166 // incitation à mettre une photo
1a828cd4 167
08cce2ff 168 $res = XDB::query('SELECT COUNT(*) FROM photo
d0e45ced 169 WHERE uid={?}', S::v('uid'));
1a828cd4 170 $page->assign('photo_incitation', $res->fetchOneCell() == 0);
171
a7de4ef7 172 // Incitation à se géolocaliser
1a828cd4 173 require_once 'geoloc.inc.php';
cab08090 174 $res = localize_addresses(S::v('uid', -1));
1a828cd4 175 $page->assign('geoloc_incitation', count($res));
176
1a828cd4 177 // ajout du lien RSS
cab08090 178 if (S::has('core_rss_hash')) {
162370e7 179 $page->setRssLink('Polytechnique.org :: News',
180 '/rss/'.S::v('forlife') .'/'.S::v('core_rss_hash').'/rss.xml');
1a828cd4 181 }
182
183 // cache les evenements lus et raffiche les evenements a relire
4e61caea 184 if ($action == 'read' && $eid) {
eadff9f9 185 XDB::execute('DELETE evenements_vus.*
eaf30d86 186 FROM evenements_vus AS ev
eadff9f9 187 INNER JOIN evenements AS e ON e.id = ev.evt_id
188 WHERE peremption < NOW()');
08cce2ff 189 XDB::execute('REPLACE INTO evenements_vus VALUES({?},{?})',
096f0dca 190 $eid, S::v('uid'));
191 pl_redirect('events#'.$pound);
1a828cd4 192 }
193
4e61caea 194 if ($action == 'unread' && $eid) {
08cce2ff 195 XDB::execute('DELETE FROM evenements_vus
eadff9f9 196 WHERE evt_id = {?} AND user_id = {?}',
4e61caea 197 $eid, S::v('uid'));
096f0dca 198 pl_redirect('events#newsid'.$eid);
1a828cd4 199 }
200
d0e45ced 201 $array = array();
9ed396c0 202 $this->get_events('FIND_IN_SET(\'important\', e.flags)', 'e.creation_date DESC', $array, 'important');
203 $this->get_events('e.creation_date > DATE_SUB(CURDATE(), INTERVAL 2 DAY)
204 AND NOT FIND_IN_SET(\'important\', e.flags)',
d0e45ced 205 'e.creation_date DESC', $array, 'news');
206 $this->get_events('e.peremption < DATE_ADD(CURDATE(), INTERVAL 2 DAY)
9ed396c0 207 AND e.creation_date <= DATE_SUB(CURDATE(), INTERVAL 2 DAY)
208 AND NOT FIND_IN_SET(\'important\', e.flags)',
d0e45ced 209 'e.peremption, e.creation_date DESC', $array, 'end');
210 $this->get_events('e.peremption >= DATE_ADD(CURDATE(), INTERVAL 2 DAY)
9ed396c0 211 AND e.creation_date <= DATE_SUB(CURDATE(), INTERVAL 2 DAY)
212 AND NOT FIND_IN_SET(\'important\', e.flags)',
d0e45ced 213 'e.peremption, e.creation_date DESC', $array, 'body');
214 $page->assign_by_ref('events', $array);
1a828cd4 215 }
216
02838718 217 function handler_photo(&$page, $eid = null, $valid = null)
218 {
219 if ($eid && $eid != 'valid') {
220 $res = XDB::query("SELECT * FROM evenements_photo WHERE eid = {?}", $eid);
221 if ($res->numRows()) {
222 $photo = $res->fetchOneAssoc();
223 header('Content-Type: image/' . $photo['attachmime']);
224 echo $photo['attach'];
225 exit;
226 }
227 } elseif ($eid == 'valid') {
228 require_once 'validations.inc.php';
229 $valid = Validate::get_request_by_id($valid);
230 if ($valid && $valid->img) {
231 header('Content-Type: image/' . $valid->imgtype);
232 echo $valid->img;
233 exit;
234 }
235 } else {
236 $upload = new PlUpload(S::v('forlife'), 'event');
237 if ($upload->exists() && $upload->isType('image')) {
238 header('Content-Type: ' . $upload->contentType());
239 echo $upload->getContents();
240 exit;
241 }
242 }
243 global $globals;
244 header('Content-Type: image/png');
245 echo file_get_contents($globals->spoolroot . '/htdocs/images/logo.png');
246 exit;
247 }
248
d1c97e42 249 function handler_rss(&$page, $user = null, $hash = null)
eaf30d86 250 {
d1c97e42 251 require_once 'rss.inc.php';
eaf30d86 252
8b1f8e12 253 $uid = init_rss('events/rss.tpl', $user, $hash);
eaf30d86 254
d1c97e42 255 $rss = XDB::iterator(
f62bd784 256 'SELECT e.id, e.titre, e.texte, e.creation_date, e.post_id, p.attachmime IS NOT NULL AS photo,
d1c97e42 257 IF(u2.nom_usage = "", u2.nom, u2.nom_usage) AS nom, u2.prenom, u2.promo
258 FROM auth_user_md5 AS u
259 INNER JOIN evenements AS e ON ( (e.promo_min = 0 || e.promo_min <= u.promo)
260 AND (e.promo_max = 0 || e.promo_max >= u.promo) )
f62bd784 261 LEFT JOIN evenements_photo AS p ON (p.eid = e.id)
d1c97e42 262 INNER JOIN auth_user_md5 AS u2 ON (u2.user_id = e.user_id)
010268b2 263 WHERE u.user_id = {?} AND FIND_IN_SET("valide", e.flags)
d1c97e42 264 AND peremption >= NOW()', $uid);
265 $page->assign('rss', $rss);
db3bd146 266 }
267
268 function handler_preview(&$page)
269 {
db3bd146 270 $page->changeTpl('events/preview.tpl', NO_SKIN);
271 $texte = Get::v('texte');
272 if (!is_utf8($texte)) {
273 $texte = utf8_encode($texte);
274 }
db3bd146 275 $titre = Get::v('titre');
276 if (!is_utf8($titre)) {
277 $titre = utf8_encode($titre);
278 }
794feea7 279 $page->assign('texte', $texte);
db3bd146 280 $page->assign('titre', $titre);
281 header('Content-Type: text/html; charset=utf-8');
282 }
d1c97e42 283
1a828cd4 284 function handler_ev_submit(&$page)
74e0093f 285 {
8b1f8e12 286 $page->changeTpl('events/submit.tpl');
db3bd146 287 $page->addJsLink('ajax.js');
eaf30d86 288
db3bd146 289 require_once('wiki.inc.php');
290 wiki_require_page('Xorg.Annonce');
74e0093f 291
5e2307dc 292 $titre = Post::v('titre');
293 $texte = Post::v('texte');
294 $promo_min = Post::i('promo_min');
295 $promo_max = Post::i('promo_max');
296 $peremption = Post::i('peremption');
297 $valid_mesg = Post::v('valid_mesg');
298 $action = Post::v('action');
02838718 299 $upload = new PlUpload(S::v('forlife'), 'event');
300 $this->upload_image($page, $upload);
74e0093f 301
d1c97e42 302 if (($promo_min > $promo_max && $promo_max != 0)||
2086ab7f 303 ($promo_min != 0 && ($promo_min <= 1900 || $promo_min >= 2020)) ||
304 ($promo_max != 0 && ($promo_max <= 1900 || $promo_max >= 2020)))
305 {
306 $page->trig("L'intervalle de promotions n'est pas valide");
307 $action = null;
308 }
309
74e0093f 310 $page->assign('titre', $titre);
311 $page->assign('texte', $texte);
312 $page->assign('promo_min', $promo_min);
313 $page->assign('promo_max', $promo_max);
314 $page->assign('peremption', $peremption);
315 $page->assign('valid_mesg', $valid_mesg);
316 $page->assign('action', strtolower($action));
02838718 317 $page->assign_by_ref('upload', $upload);
74e0093f 318
02838718 319 if ($action == 'Supprimer l\'image') {
320 $upload->rm();
321 $page->assign('action', false);
322 } elseif ($action && (!trim($texte) || !trim($titre))) {
1970c12b 323 $page->trig("L'article doit avoir un titre et un contenu");
db3bd146 324 } elseif ($action) {
74e0093f 325 require_once 'validations.inc.php';
326 $evtreq = new EvtReq($titre, $texte, $promo_min, $promo_max,
02838718 327 $peremption, $valid_mesg, S::v('uid'), $upload);
74e0093f 328 $evtreq->submit();
329 $page->assign('ok', true);
02838718 330 } elseif (!Env::v('preview')) {
331 $upload->rm();
74e0093f 332 }
74e0093f 333 }
b829e258 334
dc767839 335 function handler_tips(&$page, $tips = null)
336 {
493b6abe 337 header('Content-Type: text/html; charset="UTF-8"');
dc767839 338 $page->changeTpl('include/tips.tpl', NO_SKIN);
339 $page->assign('tips', $this->get_tips($tips));
340 }
341
342 function handler_admin_tips(&$page, $action = 'list', $id = null)
343 {
344 $page->assign('xorg_title', 'Polytechnique.org - Administration - Astuces');
345 $page->assign('title', 'Gestion des Astuces');
346 $table_editor = new PLTableEditor('admin/tips', 'tips', 'id');
a7de4ef7 347 $table_editor->describe('peremption', 'date de péremption', true);
dc767839 348 $table_editor->describe('promo_min', 'promo. min (0 aucune)', false);
349 $table_editor->describe('promo_max', 'promo. max (0 aucune)', false);
350 $table_editor->describe('titre', 'titre', true);
5d617d8d 351 $table_editor->describe('state', 'actif', true);
dc767839 352 $table_editor->describe('text', 'texte (html) de l\'astuce', false);
a7de4ef7 353 $table_editor->describe('priorite', '0<=priorité<=255', true);
3851b0a6 354 $table_editor->list_on_edit(false);
dc767839 355 $table_editor->apply($page, $action, $id);
3851b0a6 356 if (($action == 'edit' && !is_null($id)) || $action == 'update') {
3032cbd8 357 $page->changeTpl('events/admin_tips.tpl');
358 }
dc767839 359 }
360
eaf30d86 361 function handler_admin_events(&$page, $action = 'list', $eid = null)
506a46ed 362 {
e2efba7d 363 $page->changeTpl('events/admin.tpl');
db3bd146 364 $page->addJsLink('ajax.js');
92423144 365 $page->assign('xorg_title','Polytechnique.org - Administration - Evenements');
506a46ed 366 $page->register_modifier('hde', 'html_entity_decode');
367
368 $arch = $action == 'archives';
369 $page->assign('action', $action);
02838718 370
371 $upload = new PlUpload(S::v('forlife'), 'event');
372 if ((Env::has('preview') || Post::v('action') == "Proposer") && $eid) {
373 $action = 'edit';
374 $this->upload_image($page, $upload);
375 }
376
377 if (Post::v('action') == 'Pas d\'image' && $eid) {
378 $upload->rm();
379 XDB::execute("DELETE FROM evenements_photo WHERE eid = {?}", $eid);
380 $action = 'edit';
381 } elseif (Post::v('action') == 'Supprimer l\'image' && $eid) {
382 $upload->rm();
383 $action = 'edit';
384 } elseif (Post::v('action') == "Proposer" && $eid) {
2086ab7f 385 $promo_min = Post::i('promo_min');
386 $promo_max = Post::i('promo_max');
1b602af5 387 if (($promo_min != 0 && ($promo_min <= 1900 || $promo_min >= 2020)) ||
388 ($promo_max != 0 && ($promo_max <= 1900 || $promo_max >= 2020 || $promo_max < $promo_min)))
2086ab7f 389 {
390 $page->trig("L'intervalle de promotions $promo_min -> $promo_max n'est pas valide");
391 $action = 'edit';
392 } else {
9ed396c0 393 $res = XDB::query('SELECT flags FROM evenements WHERE id = {?}', $eid);
394 $flags = new FlagSet($res->fetchOneCell());
794feea7 395 $flags->addFlag('wiki');
9ed396c0 396 if (Post::v('important')) {
397 $flags->addFlag('important');
398 } else {
399 $flags->rmFlag('important');
eaf30d86 400 }
794feea7 401
2086ab7f 402 XDB::execute('UPDATE evenements
eaf30d86 403 SET creation_date = creation_date,
9ed396c0 404 titre={?}, texte={?}, peremption={?}, promo_min={?}, promo_max={?},
405 flags = {?}
eaf30d86 406 WHERE id = {?}',
2086ab7f 407 Post::v('titre'), Post::v('texte'), Post::v('peremption'),
9ed396c0 408 Post::v('promo_min'), Post::v('promo_max'),
409 $flags->flags(), $eid);
02838718 410 if ($upload->exists() && list($x, $y, $type) = $upload->imageInfo()) {
411 XDB::execute('REPLACE INTO evenements_photo
412 SET eid = {?}, attachmime = {?}, x = {?}, y = {?}, attach = {?}',
413 $eid, $type, $x, $y, $upload->getContents());
414 $upload->rm();
415 }
eaf30d86 416 }
92423144 417 }
506a46ed 418
419 if ($action == 'edit') {
02838718 420 $res = XDB::query('SELECT titre, texte, peremption, promo_min, promo_max, FIND_IN_SET(\'important\', flags),
421 attach IS NOT NULL
422 FROM evenements AS e
423 LEFT JOIN evenements_photo AS p ON(e.id = p.eid)
506a46ed 424 WHERE id={?}', $eid);
02838718 425 list($titre, $texte, $peremption, $promo_min, $promo_max, $important, $img) = $res->fetchOneRow();
506a46ed 426 $page->assign('titre',$titre);
427 $page->assign('texte',$texte);
428 $page->assign('promo_min',$promo_min);
429 $page->assign('promo_max',$promo_max);
430 $page->assign('peremption',$peremption);
9ed396c0 431 $page->assign('important', $important);
02838718 432 $page->assign('eid', $eid);
433 $page->assign('img', $img);
434 $page->assign_by_ref('upload', $upload);
506a46ed 435
436 $select = "";
437 for ($i = 1 ; $i < 30 ; $i++) {
438 $p_stamp=date("Ymd",time()+3600*24*$i);
439 $year=substr($p_stamp,0,4);
440 $month=substr($p_stamp,4,2);
441 $day=substr($p_stamp,6,2);
442
eaf30d86 443 $select .= "<option value=\"$p_stamp\""
506a46ed 444 . (($p_stamp == strtr($peremption, array("-" => ""))) ? " selected" : "")
445 . "> $day / $month / $year</option>\n";
446 }
447 $page->assign('select',$select);
448 } else {
449 switch ($action) {
450 case 'delete':
451 XDB::execute('DELETE from evenements
452 WHERE id = {?}', $eid);
453 break;
454
455 case "archive":
456 XDB::execute('UPDATE evenements
457 SET creation_date = creation_date, flags = CONCAT(flags,",archive")
458 WHERE id = {?}', $eid);
459 break;
460
461 case "unarchive":
462 XDB::execute('UPDATE evenements
463 SET creation_date = creation_date, flags = REPLACE(flags,"archive","")
464 WHERE id = {?}', $eid);
465 $action = 'archives';
466 $arch = true;
467 break;
468
469 case "valid":
470 XDB::execute('UPDATE evenements
471 SET creation_date = creation_date, flags = CONCAT(flags,",valide")
472 WHERE id = {?}', $eid);
473 break;
474
475 case "unvalid":
476 XDB::execute('UPDATE evenements
477 SET creation_date = creation_date, flags = REPLACE(flags,"valide", "")
478 WHERE id = {?}', $eid);
479 break;
480 }
481
482 $pid = ($eid && $action == 'preview') ? $eid : -1;
483 $sql = "SELECT e.id, e.titre, e.texte,e.id = $pid AS preview,
92423144 484 DATE_FORMAT(e.creation_date,'%d/%m/%Y %T') AS creation_date,
485 DATE_FORMAT(e.peremption,'%d/%m/%Y') AS peremption,
486 e.promo_min, e.promo_max,
487 FIND_IN_SET('valide', e.flags) AS fvalide,
488 FIND_IN_SET('archive', e.flags) AS farch,
794feea7
FB
489 u.promo, u.nom, u.prenom, a.alias AS forlife,
490 FIND_IN_SET('wiki', flags) AS wiki
92423144 491 FROM evenements AS e
492 INNER JOIN auth_user_md5 AS u ON(e.user_id = u.user_id)
493 INNER JOIN aliases AS a ON (u.user_id = a.id AND a.type='a_vie')
494 WHERE ".($arch ? "" : "!")."FIND_IN_SET('archive',e.flags)
506a46ed 495 ORDER BY FIND_IN_SET('valide',e.flags), e.peremption DESC";
92423144 496 $page->assign('evs', XDB::iterator($sql));
497 }
506a46ed 498 $page->assign('arch', $arch);
9ed396c0 499 $page->assign('admin_evts', true);
eaf30d86 500 }
74e0093f 501}
502
a7de4ef7 503// vim:set et sw=4 sts=4 sws=4 foldmethod=marker enc=utf-8:
74e0093f 504?>