diff options
Diffstat (limited to 'src/Wallabag/CoreBundle/Controller/EntryController.php')
-rw-r--r-- | src/Wallabag/CoreBundle/Controller/EntryController.php | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php index ba5bfbe2..2c4b5536 100644 --- a/src/Wallabag/CoreBundle/Controller/EntryController.php +++ b/src/Wallabag/CoreBundle/Controller/EntryController.php | |||
@@ -236,11 +236,25 @@ class EntryController extends Controller | |||
236 | } | 236 | } |
237 | 237 | ||
238 | /** | 238 | /** |
239 | * Shows entries with annotations for current user. | ||
240 | * | ||
241 | * @param int $page | ||
242 | * | ||
243 | * @Route("/with_annotations/list/{page}", name="with_annotations", defaults={"page" = "1"}) | ||
244 | * | ||
245 | * @return \Symfony\Component\HttpFoundation\Response | ||
246 | */ | ||
247 | public function showWithAnnotationsEntriesAction(Request $request, $page) | ||
248 | { | ||
249 | return $this->showEntries('with_annotations', $request, $page); | ||
250 | } | ||
251 | |||
252 | /** | ||
239 | * Shows random entry depending on the given type. | 253 | * Shows random entry depending on the given type. |
240 | * | 254 | * |
241 | * @param string $type | 255 | * @param string $type |
242 | * | 256 | * |
243 | * @Route("/{type}/random", name="random_entry", requirements={"type": "unread|starred|archive|untagged|all"}) | 257 | * @Route("/{type}/random", name="random_entry", requirements={"type": "unread|starred|archive|untagged|with_annotations|all"}) |
244 | * | 258 | * |
245 | * @return \Symfony\Component\HttpFoundation\RedirectResponse | 259 | * @return \Symfony\Component\HttpFoundation\RedirectResponse |
246 | */ | 260 | */ |
@@ -503,6 +517,9 @@ class EntryController extends Controller | |||
503 | case 'archive': | 517 | case 'archive': |
504 | $qb = $repository->getBuilderForArchiveByUser($this->getUser()->getId()); | 518 | $qb = $repository->getBuilderForArchiveByUser($this->getUser()->getId()); |
505 | break; | 519 | break; |
520 | case 'with_annotations': | ||
521 | $qb = $repository->getBuilderForAnnotationsByUser($this->getUser()->getId()); | ||
522 | break; | ||
506 | case 'unread': | 523 | case 'unread': |
507 | $qb = $repository->getBuilderForUnreadByUser($this->getUser()->getId()); | 524 | $qb = $repository->getBuilderForUnreadByUser($this->getUser()->getId()); |
508 | break; | 525 | break; |