1
0
mirror of https://gitlab.com/animath/si/plateforme-corres2math.git synced 2025-06-24 13:48:45 +02:00

Attribution des vidéos aux équipes (manuelle)

This commit is contained in:
galaxyoyo
2019-09-20 00:02:01 +02:00
parent c48b97cc6d
commit c3aa0386f2
14 changed files with 171 additions and 320 deletions

View File

@ -20,6 +20,28 @@ for ($i = 1; $i <= 5; ++$i) {
}
?>
<?php
if ($_SESSION["role"] == Role::ADMIN) { ?>
<hr />
<form method="POST">
<label for="other_teams">L'équipe va recevoir les questions des équipes suivantes (merci d'en sélectionner exactement 2) :</label>
<select style="width: 100%;" id="other_teams" name="other_teams[]" multiple>
<?php
/** @var Team $other_team */
foreach ($other_teams as $other_team) {
if ($other_team->getId() == $team->getId())
continue;
$team_name = $other_team->getName() . " (" . $other_team->getTrigram() . ")";
$team_id = $other_team->getId();
echo "<option value=\"$team_id\" " . (in_array($other_team->getId(), $team->getVideoTeamIds()) ? "selected" : "") . ">$team_name</option>\n";
}
?>
</select>
<input style="width: 100%;" type="submit" name="update_video_teams" value="Mettre à jour" />
</form>
<?php } ?>
<hr/>
<h2>Autorisations</h2>
@ -31,6 +53,7 @@ for ($i = 1; $i <= 5; ++$i) {
</form>
<?php if ($team->getValidationStatus() == ValidationStatus::WAITING && $_SESSION["role"] == Role::ADMIN) { ?>
<hr />
<form method="POST">
<input style="width: 100%;" type="submit" name="validate" value="Valider l'équipe"/>
</form>