forked from wallabag/wallabag
this change adds an option to sort the feed entires by updated_at
There is now an option to sort the feed entires by updated_at, on the controler : a sort querystring argument that accepts either "created" or "updated".
This commit is contained in:
@ -343,9 +343,9 @@ class EntryRepository extends EntityRepository
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function findAllByTagId($userId, $tagId)
|
||||
public function findAllByTagId($userId, $tagId, $sort = 'createdAt')
|
||||
{
|
||||
return $this->getSortedQueryBuilderByUser($userId)
|
||||
return $this->getSortedQueryBuilderByUser($userId, $sort)
|
||||
->innerJoin('e.tags', 't')
|
||||
->andWhere('t.id = :tagId')->setParameter('tagId', $tagId)
|
||||
->getQuery()
|
||||
|
||||
Reference in New Issue
Block a user