mirror of
https://github.com/MarijnDoeve/TijdVoorDeTest.git
synced 2026-03-06 04:44:19 +01:00
Add AbstractController, implement flash message handling, and refactor repositories
This commit is contained in:
@@ -36,4 +36,13 @@ class CandidateRepository extends ServiceEntityRepository
|
||||
->setParameter('name', $name)
|
||||
->getQuery()->getOneOrNullResult();
|
||||
}
|
||||
|
||||
public function save(Candidate $candidate, bool $flush = true): void
|
||||
{
|
||||
$this->getEntityManager()->persist($candidate);
|
||||
|
||||
if (true === $flush) {
|
||||
$this->getEntityManager()->flush();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user