aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Controller/EntryController.php
diff options
context:
space:
mode:
authorJeremy <jeremy.benoist@gmail.com>2015-01-31 19:09:34 +0100
committerJeremy <jeremy.benoist@gmail.com>2015-01-31 19:12:49 +0100
commit7df80cb32ca9b7d0fe452320ddc3563a1e373e2f (patch)
treec07eb79213d471aa33c49ef4e5819e41cc12f242 /src/Wallabag/CoreBundle/Controller/EntryController.php
parent1990517b2263a080946853ed697a6d687262ae80 (diff)
downloadwallabag-7df80cb32ca9b7d0fe452320ddc3563a1e373e2f.tar.gz
wallabag-7df80cb32ca9b7d0fe452320ddc3563a1e373e2f.tar.zst
wallabag-7df80cb32ca9b7d0fe452320ddc3563a1e373e2f.zip
CS
Diffstat (limited to 'src/Wallabag/CoreBundle/Controller/EntryController.php')
-rw-r--r--src/Wallabag/CoreBundle/Controller/EntryController.php19
1 files changed, 8 insertions, 11 deletions
diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php
index 25f18711..377a45ae 100644
--- a/src/Wallabag/CoreBundle/Controller/EntryController.php
+++ b/src/Wallabag/CoreBundle/Controller/EntryController.php
@@ -8,14 +8,12 @@ use Symfony\Component\HttpFoundation\Request;
8use Wallabag\CoreBundle\Repository; 8use Wallabag\CoreBundle\Repository;
9use Wallabag\CoreBundle\Entity\Entries; 9use Wallabag\CoreBundle\Entity\Entries;
10use Wallabag\CoreBundle\Service\Extractor; 10use Wallabag\CoreBundle\Service\Extractor;
11use Wallabag\CoreBundle\Helper\Tools;
12use Wallabag\CoreBundle\Helper\Url; 11use Wallabag\CoreBundle\Helper\Url;
13 12
14class EntryController extends Controller 13class EntryController extends Controller
15{ 14{
16
17 /** 15 /**
18 * @param Request $request 16 * @param Request $request
19 * @Route("/new", name="new_entry") 17 * @Route("/new", name="new_entry")
20 * @return \Symfony\Component\HttpFoundation\Response 18 * @return \Symfony\Component\HttpFoundation\Response
21 */ 19 */
@@ -32,7 +30,6 @@ class EntryController extends Controller
32 $form->handleRequest($request); 30 $form->handleRequest($request);
33 31
34 if ($form->isValid()) { 32 if ($form->isValid()) {
35
36 $content = Extractor::extract($entry->getUrl()); 33 $content = Extractor::extract($entry->getUrl());
37 34
38 $entry->setTitle($content->getTitle()); 35 $entry->setTitle($content->getTitle());
@@ -115,7 +112,7 @@ class EntryController extends Controller
115 /** 112 /**
116 * Shows entry content 113 * Shows entry content
117 * 114 *
118 * @param Entries $entry 115 * @param Entries $entry
119 * @Route("/view/{id}", requirements={"id" = "\d+"}, name="view") 116 * @Route("/view/{id}", requirements={"id" = "\d+"}, name="view")
120 * @return \Symfony\Component\HttpFoundation\Response 117 * @return \Symfony\Component\HttpFoundation\Response
121 */ 118 */
@@ -130,8 +127,8 @@ class EntryController extends Controller
130 /** 127 /**
131 * Changes read status for an entry 128 * Changes read status for an entry
132 * 129 *
133 * @param Request $request 130 * @param Request $request
134 * @param Entries $entry 131 * @param Entries $entry
135 * @Route("/archive/{id}", requirements={"id" = "\d+"}, name="archive_entry") 132 * @Route("/archive/{id}", requirements={"id" = "\d+"}, name="archive_entry")
136 * @return \Symfony\Component\HttpFoundation\RedirectResponse 133 * @return \Symfony\Component\HttpFoundation\RedirectResponse
137 */ 134 */
@@ -151,8 +148,8 @@ class EntryController extends Controller
151 /** 148 /**
152 * Changes favorite status for an entry 149 * Changes favorite status for an entry
153 * 150 *
154 * @param Request $request 151 * @param Request $request
155 * @param Entries $entry 152 * @param Entries $entry
156 * @Route("/star/{id}", requirements={"id" = "\d+"}, name="star_entry") 153 * @Route("/star/{id}", requirements={"id" = "\d+"}, name="star_entry")
157 * @return \Symfony\Component\HttpFoundation\RedirectResponse 154 * @return \Symfony\Component\HttpFoundation\RedirectResponse
158 */ 155 */
@@ -172,8 +169,8 @@ class EntryController extends Controller
172 /** 169 /**
173 * Deletes entry 170 * Deletes entry
174 * 171 *
175 * @param Request $request 172 * @param Request $request
176 * @param Entries $entry 173 * @param Entries $entry
177 * @Route("/delete/{id}", requirements={"id" = "\d+"}, name="delete_entry") 174 * @Route("/delete/{id}", requirements={"id" = "\d+"}, name="delete_entry")
178 * @return \Symfony\Component\HttpFoundation\RedirectResponse 175 * @return \Symfony\Component\HttpFoundation\RedirectResponse
179 */ 176 */