From: Jan Losinski Date: Tue, 17 Jan 2017 18:22:20 +0000 (+0100) Subject: Order tags by slug X-Git-Tag: 2.2.0~3^2~5^2 X-Git-Url: https://git.immae.eu/?a=commitdiff_plain;ds=sidebyside;h=32755d5091546af8f82bfed3ca77287b3fb232ce;p=github%2Fwallabag%2Fwallabag.git Order tags by slug This adds an orderBy clause to findAllTags(). This makes the list of tags more useful, as the tags appear in alphanumerical order instead of somehow random. Signed-off-by: Jan Losinski --- diff --git a/src/Wallabag/CoreBundle/Repository/TagRepository.php b/src/Wallabag/CoreBundle/Repository/TagRepository.php index 81445989..2182df25 100644 --- a/src/Wallabag/CoreBundle/Repository/TagRepository.php +++ b/src/Wallabag/CoreBundle/Repository/TagRepository.php @@ -49,6 +49,7 @@ class TagRepository extends EntityRepository ->leftJoin('t.entries', 'e') ->where('e.user = :userId')->setParameter('userId', $userId) ->groupBy('t.id') + ->orderBy('t.slug') ->getQuery() ->getArrayResult();