1
0
Fork 0
mirror of https://github.com/wallabag/wallabag.git synced 2025-10-20 19:52:09 +00:00

Add rss for entries

will fix #1000
This commit is contained in:
Jeremy 2015-03-28 14:27:45 +01:00
parent f98a2a0fc3
commit 0c83fd5994
13 changed files with 510 additions and 61 deletions

View file

@ -0,0 +1,26 @@
<?php
namespace Wallabag\CoreBundle\Repository;
use Doctrine\ORM\EntityRepository;
class UserRepository extends EntityRepository
{
/**
* Find a user by its username and rss roken
*
* @param string $username
* @param string $rssToken
*
* @return User|null
*/
public function findOneByUsernameAndRsstoken($username, $rssToken)
{
return $this->createQueryBuilder('u')
->leftJoin('u.config', 'c')
->where('c.rssToken = :rss_token')->setParameter('rss_token', $rssToken)
->andWhere('u.username = :username')->setParameter('username', $username)
->getQuery()
->getOneOrNullResult();
}
}