diff --git a/registration-system/frameworks/medoo.php b/registration-system/frameworks/medoo.php index a21e84fba376d887bee8afcc4eba349e02948176..439433b8bc914f55aeabd95633682ce7be391821 100644 --- a/registration-system/frameworks/medoo.php +++ b/registration-system/frameworks/medoo.php @@ -129,14 +129,14 @@ class medoo public function query($query) { $this->queryString = $query; - + comm_verbose(3,$query); return $this->pdo->query($query); } public function exec($query) { $this->queryString = $query; - + comm_verbose(3,$query); return $this->pdo->exec($query); } diff --git a/registration-system/index.php b/registration-system/index.php index 463505b160bfd6ad61f98e1425672bd3e482dbbe..b1c53cc39bc2678e3186589e2c583ce12255ee14 100644 --- a/registration-system/index.php +++ b/registration-system/index.php @@ -63,6 +63,11 @@ function index_show_content(){ } +/** + * puts the dataarray into DB + * adds version = 1 and generates a unique hash for entry + * @param $data + */ function index_form_to_db($data){ global $index_db; $data['version'] = 1; @@ -320,12 +325,12 @@ function index_show_fahrtHeader($fahrt){ * show table of public registrations */ function index_show_signupTable($fid){ - global $index_db; - $data = $index_db->select('bachelor',array('pseudo','antyp','abtyp','antag','abtag','comment','studityp'), + global $index_db, $config_studitypen; + + $data = $index_db->select('bachelor',array("pseudo","antyp","abtyp","anday","abday","comment","studityp"), array("AND" => array( - "fahrt_id" => $fid, - "public" => 1, - "valid_version" => 1 + 'fahrt_id' => (int) $fid, + 'public' => 1 ))); if(!$data) echo'<div class="signups">Noch keine (sichtbaren) Anmeldungen!</div>'; @@ -336,20 +341,20 @@ function index_show_signupTable($fid){ <tr> <th></th> <th>Anzeigename</th> - <th>Anreiseart</th> <th>Anreisetag</th> - <th>Abreiseart</th> + <th>Anreiseart</th> <th>Abreisetag</th> + <th>Abreiseart</th> <th>Kommentar</th> </tr> </thead>'; foreach($data as $d){ echo '<tr> - <td>'.$d["studityp"].'</td> + <td>'.$config_studitypen[$d["studityp"]].'</td> <td>'.$d["pseudo"].'</td> - <td>'.$d["antag"].'</td> + <td>'.$d["anday"].'</td> <td>'.$d["antyp"].'</td> - <td>'.$d["abtag"].'</td> + <td>'.$d["abday"].'</td> <td>'.$d["abtyp"].'</td> <td>'.$d["comment"].'</td> </tr>'; diff --git a/registration-system/view/admin_template.html b/registration-system/view/admin_template.html index 9c35cbb24c8a30ff9631767d8b823c9e8ee580ac..88a02f4cec164cc5ad1d02204f4eb48343ebd41c 100644 --- a/registration-system/view/admin_template.html +++ b/registration-system/view/admin_template.html @@ -34,12 +34,14 @@ padding: 0 5px; } + #admin-content{ + } </style> </head> <body> -<div> +<div id="admin-content"> {text} </div>