aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Controller/TagController.php
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2015-08-07 18:17:23 +0200
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2015-08-07 18:17:23 +0200
commit3f3fbef11f86968a991426c2a052ad42e0c16d44 (patch)
tree23c1796279ba1d44e17ed15922db737822484bad /src/Wallabag/CoreBundle/Controller/TagController.php
parent6ecdd48a3fadf076e062b6c634ae80f261c43e23 (diff)
downloadwallabag-3f3fbef11f86968a991426c2a052ad42e0c16d44.tar.gz
wallabag-3f3fbef11f86968a991426c2a052ad42e0c16d44.tar.zst
wallabag-3f3fbef11f86968a991426c2a052ad42e0c16d44.zip
Add tags list display
Diffstat (limited to 'src/Wallabag/CoreBundle/Controller/TagController.php')
-rw-r--r--src/Wallabag/CoreBundle/Controller/TagController.php33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/Wallabag/CoreBundle/Controller/TagController.php b/src/Wallabag/CoreBundle/Controller/TagController.php
new file mode 100644
index 00000000..89284231
--- /dev/null
+++ b/src/Wallabag/CoreBundle/Controller/TagController.php
@@ -0,0 +1,33 @@
1<?php
2
3namespace Wallabag\CoreBundle\Controller;
4
5use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
6use Symfony\Bundle\FrameworkBundle\Controller\Controller;
7use Symfony\Component\HttpFoundation\Request;
8use Wallabag\CoreBundle\Entity\Tag;
9
10class TagController extends Controller
11{
12 /**
13 * Shows tags for current user.
14 *
15 * @Route("/tag/list", name="tag")
16 *
17 * @return \Symfony\Component\HttpFoundation\Response
18 */
19 public function showTagAction()
20 {
21 $tags = $this->getDoctrine()
22 ->getRepository('WallabagCoreBundle:Tag')
23 ->findTags($this->getUser()->getId());
24
25 return $this->render(
26 'WallabagCoreBundle:Tag:tags.html.twig',
27 array(
28 'tags' => $tags
29 )
30 );
31 }
32
33}