Blame view

orga.php 12.2 KB
bd5b1d78   Geoffrey PREUD'HOMME   [Orga] Fix commit...
1
2
3
4
5
6
7
8
  <?php
  
  if(session_id() == '') {
      session_start();
  }
  
  ?>
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
9
  <h3> Organisation </h3>
97d25235   Erwan Nanrocki   ajout d un titre ...
10
  
27f3beb9   Geoffrey Bontoux-Preud-Homme   Ajout de orga.php
11
  <?php
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
12
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
13
14
  $time = time();
  
27f3beb9   Geoffrey Bontoux-Preud-Homme   Ajout de orga.php
15
  # e_ : est
e6faaa33   Geoffrey PREUD'HOMME   [Orga] Oublié ses...
16
  
d70dd0a0   Geoffrey PREUD'HOMME   [Orga] Intégratio...
17
18
19
  $e_connecte = isset($_SESSION["connected"]) && $_SESSION["connected"];
  $e_admin = isset($_SESSION["admin"]) && $_SESSION["admin"];
  
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
20
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
21
  if ($e_connecte) {
d70dd0a0   Geoffrey PREUD'HOMME   [Orga] Intégratio...
22
      if ($e_admin) {
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
23
24
          $droits  = array('voir', 'voter', 'ajouter', 'proposer', 'annuler', 'supprimer', 'modifier', 'valider');
      } else {
e6faaa33   Geoffrey PREUD'HOMME   [Orga] Oublié ses...
25
          $droits = array('voir', 'voter', 'proposer');
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
26
27
28
29
30
      }
  } else {
      $droits = array('voir');
  }
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
31
  $lastID = 0; // TODO Est-ce que cela mérite-t-il d'exister ?
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
32
33
34
  
  class Evenement
  {
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
35
36
37
      // TODO Mettre tout en privé et utiliser __get et __set
      public $id = 0;
      public $creationTime = 0;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
38
  
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
39
40
41
42
      public $nom = "Sans nom";
      public $description = "Sans description";
      public $annule = false;
      public $valide = false;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
43
44
      public $duree = 3600;
      public $supprime = false;
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
45
46
  
      public $dates = array();
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
47
      public $datesVotes = array();
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
48
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
49
50
51
52
53
54
55
56
57
58
59
60
61
62
      function __construct($id = 0) {
          global $lastID;
          if ($id == 0) { // Nouvel évènement
              $lastID += 1;
              $this->id = $lastID;
              $this->creationTime = time();
          } else { // Évènement existant : on charge
              // TODO SQL Select
              $this->id = $lastID + 1; // TODO DEBUG SQL Récupération id
              if ($this->id > $lastID) {
                  $lastID = $this->id;
              }
              // TODO SQL Récupération du reste des propriétés
          }
1d6e24f7   Geoffrey PREUD'HOMME   [Orga] Envoi des ...
63
64
65
66
67
68
      }
  
      public function sauvegarder() {
          // TODO SQL
      }
  
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
69
      public function html() {
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
70
          $html = '<li id="ev_li_'.$this->id.'" class="ev_li list-group-item';
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
71
72
73
74
          if ($this->annule) {
              $html .= ' list-group-item-danger';
          }
          $html .= '">';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
75
76
  
          # Titre
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
77
          $html .= '<h4 class="list-group-item-heading">'.$this->nom;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
78
          if ($this->p_annuler()) {
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
79
              $html .= ' <button type="button" class="ev_annuler btn btn-warning"><span class="glyphicon glyphicon glyphicon-remove"></span> Annuler</button>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
80
          }
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
81
          if ($this->p_supprimer()) {
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
82
              $html .= ' <button type="button" class="ev_supprimer btn btn-danger"><span class="glyphicon glyphicon glyphicon-trash"></span> Supprimer</button>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
83
          }
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
84
          $html .= '</h4>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
85
86
87
88
  
          # Description
          $html .= '<div class="panel panel-default">';
          $html .= '<div class="panel-heading">';
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
89
          $html .= '<h5 class="panel-title">Informations';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
90
          if ($this->p_modifier()) {
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
91
              $html .= ' <button type="button" class="ev_modifier btn btn-default"><span class="glyphicon glyphicon-pencil"></span> Modifier</button>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
92
          }
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
93
          $html .= '</h5>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
94
95
          $html .= '</div>';
          $html .= '<div class="panel-body">';
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
96
          $html .= '<p class="ev_description">';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
97
98
99
100
          $html .= nl2br(htmlspecialchars($this->description));
          $html .= '</p>';
          // $html .= '<hr/>';
          $html .= '<p>';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
101
102
103
          $heures = floor($this->duree/3600);
          $minutes = floor($this->duree%3600/60);
          $secondes = floor($this->duree%3600%60);
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
104
          $html .= 'Durée : <span class="ev_duree">'.($heures > 0 ? '<span class="ev_duree_h">'.$heures.'</span> heure'.($heures > 1 ? 's' : '').' ' : '').($minutes > 0 ? '<span class="ev_duree_m">'.$minutes.'</span> minute'.($minutes > 1 ? 's' : '').' ' : '').($secondes > 0 ? '<span class="ev_duree_s">'.$secondes.'</span> seconde'.($secondes > 1 ? 's' : '').' ' : '').'</span><br/>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
105
          if ($this->valide) {
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
106
              $html .= 'Date : le <span class="ev_date">'.date('j/m/o', $this->valide).' à '.date('H:i', $this->valide).'</span><br/>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
107
108
109
          }
          $html .= '</p>';
          if ($this->annule) {
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
110
              $html .= '<p><span class="label label-danger">Annulé</span></p>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
111
112
113
114
115
116
117
  
          }
          $html .= '</div>';
          $html .= '</div>';
  
          # Dates
          if (!$this->valide && !$this->annule) {
3a23c07d   Geoffrey PREUD'HOMME   [Orga] Ajout d'év...
118
              $html .= '<div class="ev_pos panel panel-default">';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
119
              $html .= '<div class="panel-heading">';
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
120
              $html .= '<h5 class="panel-title">Dates possibles';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
121
              if ($this->p_proposer()) {
3a23c07d   Geoffrey PREUD'HOMME   [Orga] Ajout d'év...
122
                  $html .= ' <button type="button" class="ev_pos_proposer btn btn-default"><span class="glyphicon glyphicon-plus"></span> Proposer une date</button>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
123
              }
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
124
              $html .= '</h5>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
125
126
              $html .= '</div>';
              $html .= '<div class="panel-body">';
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
127
128
129
              if ($this->p_voter()) {
                  $html .= '<p>Sélectionnez les dates qui vous conviennent.</p>';
              }
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
130
131
              $html .= '<div class="list-group">';
              $time = time();
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
132
              foreach ($this->dates as $dateIndex => $date) { // TODO À faire fonctionner (après que le reste fonctionne)
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
133
134
135
136
                  $html .= '<a href="#"class="list-group-item';
                  if ($date < $time) {
                      $html .= ' disabled';
                  }
3a23c07d   Geoffrey PREUD'HOMME   [Orga] Ajout d'év...
137
                  $html .= '">Le <span class="ev_pos_date">'.date('j/m/o', $date).' à '.date('H:i', $date).'</span> (<span class="ev_pos_nb">'.$this->datesVotes[$dateIndex].'</span> <span class="glyphicon glyphicon-user"></span>)</a>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
138
              }
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
139
140
              $html .= '</div>';
              if ($this->p_valider()) {
3a23c07d   Geoffrey PREUD'HOMME   [Orga] Ajout d'év...
141
                  $html .= '<p><button type="button" class="ev_pos_valider btn btn-primary"><span class="glyphicon glyphicon-ok"></span> Valider la date</button></p>';
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
142
143
144
145
146
147
148
149
              }
              $html .= '</div>';
              $html .= '</div>';
          }
  
          $html .= '</li>';
          return $html;
      }
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
  
      public function passe() {
          global $time;
          if ($this->valide) {
              return $this->valide+$this->duree < $time;
          } else {
              return false;
          }
      }
  
      # p_ : Il est possible de ...
      function p_annuler() {
          global $droits;
          return in_array('annuler', $droits) && !$this->annule && !$this->passe();
      }
  
      function p_supprimer() {
          global $droits;
          return in_array('supprimer', $droits) && !$this->valide;
      }
  
      function p_modifier() {
          global $droits;
          return in_array('modifier', $droits);
      }
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
176
177
178
179
180
      function p_voter() {
          global $droits;
          return in_array('voter', $droits) && !$this->valide;
      }
  
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
181
182
      function p_proposer() {
          global $droits;
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
183
          return in_array('proposer', $droits) && !$this->valide;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
184
185
186
187
      }
  
      function p_valider() {
          global $droits;
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
188
          # TODO Et si un nombre suffisant de personnes est ok avec la date la plus disponible 
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
189
190
191
192
193
          return in_array('valider', $droits) && !$this->valide;
      }
  
  }
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
194
195
  # a_ : Récupérer depuis la base de donnée (ou pas)
  function a_evenements() {
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
196
197
      # DEBUG
      $test1 = new Evenement;
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
198
      $test1->duree = 12345;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
199
      $test1->nom = 'Évènement de test n°1';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
200
      $test1->description = 'Description de l\'évènement de test n°1';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
201
202
203
      $test1->valide = time();
      
      $test2 = new Evenement;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
204
      $test2->nom = 'Évènement de test n°2';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
205
206
      $test2->description = 'Description de l\'évènement de test n°2';
      $test2->duree = 36000;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
207
208
209
210
      $test2->valide = time();
      $test2->annule = true;
      
      $test3 = new Evenement;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
211
      $test3->nom = 'Évènement de test n°3';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
212
      $test3->description = 'Description de l\'évènement de test n°3';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
213
214
215
216
217
218
219
220
      $test3->dates[] = 1415482197;
      $test3->datesVotes[] = 42;
      $test3->dates[] = time();
      $test3->datesVotes[] = 5;
      $test3->dates[] = time()+365*24*3600;
      $test3->datesVotes[] = 1;
      
      $test4 = new Evenement;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
221
      $test4->nom = 'Évènement de test n°4';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
222
      $test4->description = 'Description de l\'évènement de test n°4';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
223
224
225
226
227
228
229
230
      $test4->dates[] = time();
      $test4->datesVotes[] = 5;
      $test4->dates[] = time()+365*24*3600;
      $test4->datesVotes[] = 1;
      $test4->dates[] = time();
      $test4->annule = true;
  
      $test5 = new Evenement;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
231
      $test5->nom = 'Évènement de test n°5';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
232
      $test5->description = 'Description de l\'évènement de test n°5';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
233
234
235
236
237
      $test5->dates[] = time();
      $test5->datesVotes[] = 0;
      $test5->supprime = true;
  
      $test6 = new Evenement;
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
238
      $test6->nom = 'Évènement de test n°6';
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
239
      $test6->description = 'Description de l\'évènement de test n°6';
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
240
241
242
243
244
      $test6->valide = 1415452197;
  
      return array($test1, $test2, $test3, $test4, $test5, $test6);
  }
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
245
  $evenements = a_evenements();
1d6e24f7   Geoffrey PREUD'HOMME   [Orga] Envoi des ...
246
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
247
248
249
250
251
252
253
254
  function a_evenement($id) {
      global $evenements;
      foreach ($evenements as $evenement) {
          if ($evenement->id == $id) {
              return $evenement;
          }
      }
  }
1d6e24f7   Geoffrey PREUD'HOMME   [Orga] Envoi des ...
255
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
256
  # TRAITEMENT DES DONNEES POST
1d6e24f7   Geoffrey PREUD'HOMME   [Orga] Envoi des ...
257
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
  function mauvaiseRequete($code = 0) {
      echo '<div class="alert alert-danger" role="alert">Le serveur n\'a pas compris votre requête <small>(code d\'erreur n°'.$code.')</small>.</div>';
  }
  
  function bonneRequete($message = 'Action correctement effectuée.') {
      echo '<div class="alert alert-success" role="alert">'.$message.'</div>';
  }
  
  if (isset($_POST['action'])) {
  
      switch ($_POST['action']) {
          case 'modifier':
              if (isset($_POST['id']) && isset($_POST['description']) && isset($_POST['duree'])) {
                  if ($evenement = a_evenement($_POST['id'])) {
                      if (($duree = intval($_POST['duree'])) >= 0) {
                          $evenement->description = $_POST['description']; // TODO Protection nécessaire pour SQL
                          $evenement->duree = $duree;
                          bonneRequete('Élement correctement modifié.');
                      } else {
                          mauvaiseRequete(4);
                      }
                  } else {
                      mauvaiseRequete(3);
                  }
              } else {
                  mauvaiseRequete(2);
              }
              break;
  
          case 'annuler':
              if (isset($_POST['id'])) {
                  if ($evenement = a_evenement($_POST['id'])) {
                      $evenement->annule = true;
                      bonneRequete('Évènement annulé.');
                  } else {
                      mauvaiseRequete(3);
                  }
              } else {
                  mauvaiseRequete(2);
              }
              break;
  
          case 'supprimer':
              if (isset($_POST['id'])) {
                  if ($evenement = a_evenement($_POST['id'])) {
                      $evenement->supprime = true;
                      bonneRequete('Évènement supprimé.');
                  } else {
                      mauvaiseRequete(3);
                  }
              } else {
                  mauvaiseRequete(2);
              }
              break;
          
          default:
              mauvaiseRequete(1);
              break;
      }
1d6e24f7   Geoffrey PREUD'HOMME   [Orga] Envoi des ...
317
318
319
320
321
  }
  
  
  # AFFICHAGE DE LA PAGE
  
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
322
  # Tri des évènements
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
323
324
325
326
  $evenementsPlanifies = array();
  $evenementsAPlanifier = array();
  $evenementsPasses = array();
  
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
327
328
329
330
331
332
333
334
335
336
337
338
  foreach ($evenements as $evenement) {
      if (!$evenement->supprime) {
          if ($evenement->valide) {
              if ($evenement->passe()) {
                  $evenementsPasses[] = $evenement;
              } else {
                  $evenementsPlanifies[] = $evenement;
              }
          } else {
              $evenementsAPlanifier[] = $evenement;
          }
      }
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
339
340
  }
  
3fde9691   Geoffrey PREUD'HOMME   [Orga] Interpréta...
341
  # Affichage
27f3beb9   Geoffrey Bontoux-Preud-Homme   Ajout de orga.php
342
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
343
344
345
346
347
348
349
350
351
  if (!$e_connecte) {
  ?>
  <div class="alert alert-warning" role="alert">Connectez-vous afin de pouvoir agir sur les évènements.</div>
  <?php    
  }
  ?>
  <?php
  if (in_array('voir', $droits)) {
  ?>
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
352
353
  <h3>Évènements plannifiés <?php if (in_array('ajouter', $droits)) { ?><button id="ev_ajouter_fixe" type="button" class="btn btn-primary"><span class="glyphicon glyphicon-plus"></span> Ajouter un évènement avec une date fixée</button><?php } ?></h3>
  <ul id="ev_ul_planifies" class="list-group">
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
354
  <?php
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
355
356
357
  foreach ($evenementsPlanifies as $evenement) {
      echo $evenement->html();
  }
27f3beb9   Geoffrey Bontoux-Preud-Homme   Ajout de orga.php
358
  ?>
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
359
360
  </ul>
  
27f3beb9   Geoffrey Bontoux-Preud-Homme   Ajout de orga.php
361
  
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
362
363
  <h3>Évènements à plannifier <?php if (in_array('ajouter', $droits)) { ?><button id="ev_ajouter_choix" type="button" class="btn btn-primary"><span class="glyphicon glyphicon-plus"></span> Ajouter un évènement avec une date à choisir</button><?php } ?></h3>
  <ul id="ev_ul_aplanifier" class="list-group">
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
364
  <?php
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
365
366
367
  foreach ($evenementsAPlanifier as $evenement) {
      echo $evenement->html();
  }
f84e30e3   Geoffrey PREUD'HOMME   [Orga] Retravail
368
369
370
371
  ?>
  </ul>
  
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
372
  <h3>Évènements passés</h3>
6884541c   Geoffrey PREUD'HOMME   [Orga] Ajout d'id...
373
  <ul id="ev_ul_passes" class="list-group">
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
374
  <?php
5f2f48c7   Geoffrey PREUD'HOMME   [Orga] Modificati...
375
376
377
378
  foreach ($evenementsPasses as $evenement) {
      echo $evenement->html();
  }
  ?>
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
379
380
  </ul>
  
fab2252b   Geoffrey PREUD'HOMME   [Orga] Réponse ad...
381
  <script type="text/javascript" src="js/orga.js"></script>
3a23c07d   Geoffrey PREUD'HOMME   [Orga] Ajout d'év...
382
  
e4f5453d   Geoffrey PREUD'HOMME   [Orga] Meilleure ...
383
384
385
386
387
388
389
  <?php
  } else {
  ?>
  <div class="alert alert-danger" role="alert">Vous ne pouvez pas voir les évènements.</div>
  <?php
  }
  ?>