1
0
This commit is contained in:
Daniel Tartavel 2022-09-26 10:53:45 +02:00
parent 6383cedf89
commit 87e612e6f9
2 changed files with 10 additions and 2 deletions

View File

@ -35,7 +35,15 @@ if (!empty($idCandidat))
choixVote($path, $idVotation);
}else
{
print('<h3>Nouveau candidat pour le vote');
$votationName = $db->queryVotationName($idVotation);
$voteName = $db->queryVoteName($idVote);
$candidatsList = $db->queryCandidatsList($idVotation, $idVote);
print('<h3>Nouveau candidat pour le vote ' . $voteName . ' de la votation ' . $votationName . '</h3>');
print('Liste des candidats');
foreach($candidatsList as $line)
{
print($line["libelle"] . EOLH);
}
candidatsForm($path, $idVotation, $idVote);
}
print(' </div>

View File

@ -141,7 +141,7 @@ class dbcore
{
$query = "SELECT * FROM liste_candidats WHERE idVotation='" . $idVotation . "' AND idVote='" . $idVote . "'";
$this->query($query);
$candidats = $this->result->fetch_all();
$candidats = $this->result->fetch_all(MYSQL_ASSOC);
return $candidats;
}
}