function getPuzzleTeamsList() { $puzzles = getPuzzlesInTesting(); foreach ($puzzles as $p) { $pid = $p; $testteam = getPuzzleTestTeam($pid); $teamassignments["{$pid}"] = $testteam; } asort($teamassignments); return $teamassignments; }
exit(1); } echo "<h2>Test Queue</h2>"; ?> <form action="form-submit.php" method="post"> <input type="hidden" name="uid" value="<?php echo $uid; ?> " /> Enter Puzzle ID to testadmin: <input type="text" name="pid" /> <input type="submit" name="TestAdminPuzzle" value="Go" /> </form> <br /> <?php $inTesting = count(getPuzzlesInTesting()); $numNeedAdmin = count(getPuzzlesNeedTestAdmin()); echo "There are currently <strong>{$inTesting} puzzles</strong> in testing<br/>"; echo "<strong>{$numNeedAdmin} puzzles</strong> need a testing admin</strong>"; echo "<br /><br />"; if (isTestingAdmin($uid)) { if (getPuzzleForTestAdminQueue($uid) == FALSE) { echo '<div class="emptylist">No Puzzles To Add</div><br/>'; } else { ?> <form action="form-submit.php" method="post"> <input type="hidden" name="uid" value="<?php echo $uid; ?> " /> <input type="submit" name="getTestAdminPuzz" value="Get Puzzle" />
function getAvailablePuzzlesToTestForUser($uid) { $puzzles = getPuzzlesInTesting(); $available = array(); echo "\n<br>\n"; foreach ($puzzles as $pid) { if (canTestPuzzle($uid, $pid) && !isInTargetedTestsolving($pid) && !isTesterOnPuzzle($uid, $pid) && !isFormerTesterOnPuzzle($uid, $pid) && canUseMoreTesters($pid)) { $available[] = $pid; } } return $available; }