Get By File Name

This commit is contained in:
Michael RICOIS 2016-07-25 17:42:54 +02:00
parent 7c459d76dc
commit d7ec1a3a03

View File

@ -35,4 +35,14 @@ class FluxFileoutRepository extends EntityRepository
return $query->getResult();
}
public function getByFilename($name)
{
$dql = "SELECT f FROM Application\Entity\FluxFileout f WHERE ".
"f.fileout=:name";
$query = $this->getEntityManager()->createQuery($dql)
->setParameter('name', $name);
return $query->getOneOrNullResult();
}
}