]> git.mjollnir.org Git - s9y.git/commitdiff
more breakfast attendees, order by name
authorPenny Leach <mjollnir@titania.local>
Mon, 26 Jun 2006 09:39:27 +0000 (21:39 +1200)
committerPenny Leach <mjollnir@titania.local>
Mon, 26 Jun 2006 09:39:52 +0000 (21:39 +1200)
plugins/serendipity_plugin_breakfast/admin.inc.php
plugins/serendipity_plugin_breakfast/lib.php

index dc9e88e5df7087d0d8d222e981b0521bdb7a3de6..fbab0617432f33dd04b46a2cf3982a909df4ed26 100644 (file)
@@ -4,6 +4,7 @@ if (IN_serendipity !== true) {
 }
 
 require_once(dirname(__FILE__).'/lib.php');
+$maxattendees = 15;
 
 switch ($serendipity['GET']['adminAction']) {
 
@@ -22,7 +23,7 @@ switch ($serendipity['GET']['adminAction']) {
               <td><textarea name="comment" rows="4" cols="70"></textarea></td>
           </tr>
 ';
-     for ($i = 0; $i < 10; $i++) {
+     for ($i = 0; $i < $maxattendees; $i++) {
      echo '
           <tr>
               <td><hr /></td>
@@ -68,7 +69,7 @@ echo '
              VALUES ('.$date.','.$cafeid.((!empty($_GET['comment'])) ? ',\''.$_GET['comment'].'\'' : '').')');
      $eventid = serendipity_db_insert_id();
 
-     for ($i = 0; $i < 10; $i++) {
+     for ($i = 0; $i < $maxattendees; $i++) {
          // person, meal, then scores.
          if (empty($_GET['person'.$i]) && empty($_GET['person_free'.$i])) {
              continue;
index e2cc0c4e4c673a897c4d04648b7b1a0429772c47..13349a8edca6dcbb04f7fee71802d15111a2a487 100644 (file)
@@ -231,7 +231,7 @@ function breakfast_generate_sql($latest=true,$date=0,$cafe=0,$person=0,$meal=0)
             $w = true;
         }
     }
-    return $sql .' ORDER BY e.date DESC';
+    return $sql .' ORDER BY e.date DESC, p.name';
 }
 
 ?>
\ No newline at end of file