This commit is contained in:
William 2022-03-16 13:46:30 +01:00
parent 1144fc16f6
commit 4a76b1ce81
2 changed files with 0 additions and 8 deletions

View File

@ -37,12 +37,6 @@
<input type="number" id="participants" name="participants" value="<?=htmlspecialchars($team->participants)?>" maxlength="32">
<br>
<label for="number">Runder:</label>
<br>
<input type="number" id="rounds" name="rounds" value="<?=htmlspecialchars($team->rounds)?>" maxlength="32">
<br>
<br>
<input type="submit" value="Lagre">
<span>[&nbsp;<a class="danger" href="index.php">Avbryt</a>&nbsp;]</span>

View File

@ -29,7 +29,6 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST')
$leader = filter_input(INPUT_POST, 'leader');
$phone = filter_input(INPUT_POST, 'phone', FILTER_VALIDATE_INT);
$participants = filter_input(INPUT_POST, 'participants', FILTER_VALIDATE_INT);
$rounds = filter_input(INPUT_POST, 'rounds', FILTER_VALIDATE_INT);
$team = new Team;
try {
@ -39,7 +38,6 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST')
$team->setLeader($leader);
$team->setPhone($phone);
$team->setParticipants($participants);
$team->setRounds($rounds);
} catch(InvalidArgumentException $e) {
$app->session->flash('Kunne ikke oppdatere lag: Validerings feil: ' . $e->getMessage() , 'danger');
$app->redirect('index.php');