forked from science-ation/science-ation
Show round+time with each team on the team editor
This commit is contained in:
parent
0661224a0b
commit
0dd1637415
@ -26,6 +26,22 @@ function getJudgingTeams()
|
||||
$lastteamid=$r->id;
|
||||
$lastteamnum=$r->num;
|
||||
|
||||
/* Load timeslots */
|
||||
$rounds = array();
|
||||
$tq = mysql_query("SELECT * FROM judges_teams_timeslots_link
|
||||
LEFT JOIN judges_timeslots ON judges_timeslots.id=judges_teams_timeslots_link.judges_timeslots_id
|
||||
WHERE judges_teams_timeslots_link.judges_teams_id='{$r->id}'");
|
||||
$teams[$r->id]['timeslots'] = array();
|
||||
$teams[$r->id]['rounds'] = array();
|
||||
while($ts = mysql_fetch_assoc($tq)) {
|
||||
$teams[$r->id]['timeslots'][] = $ts;
|
||||
$rounds[$ts['round_id']] = $ts['round_id'];
|
||||
}
|
||||
foreach($rounds as $round_id) {
|
||||
$tq = mysql_query("SELECT * FROM judges_timeslots WHERE id='{$round_id}'");
|
||||
$teams[$r->id]['rounds'][] = mysql_fetch_assoc($tq);
|
||||
}
|
||||
|
||||
//get the members for this team
|
||||
$mq=mysql_query("SELECT
|
||||
users.id AS judges_id,
|
||||
|
@ -295,6 +295,11 @@ function switchjudgeinfo()
|
||||
echo "<tr><th colspan=\"2\" align=\"left\">#".$team['num'].": ";
|
||||
echo $team['name'];
|
||||
echo "</th></tr>\n";
|
||||
echo "<tr><td colspan=\"2\">";
|
||||
foreach($team['rounds'] as $ts) {
|
||||
echo "{$ts['name']}: {$ts['starttime']} - {$ts['endtime']}<br />";
|
||||
}
|
||||
echo "</td></tr>";
|
||||
|
||||
if(count($team['members']))
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user