aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/ApiBundle
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2017-05-09 13:55:31 +0200
committerJeremy Benoist <jeremy.benoist@gmail.com>2017-05-09 13:55:31 +0200
commit54c2d164a362e64a320438b439bf9dd6d2c02424 (patch)
treedc25a86685524e642cedfd95d02736ef06b28f77 /src/Wallabag/ApiBundle
parentb28c5430efefa63d04d87404c99798e82d0427e4 (diff)
parentc829b06ed8f757f2b96515eb872f9ccf20363c94 (diff)
downloadwallabag-54c2d164a362e64a320438b439bf9dd6d2c02424.tar.gz
wallabag-54c2d164a362e64a320438b439bf9dd6d2c02424.tar.zst
wallabag-54c2d164a362e64a320438b439bf9dd6d2c02424.zip
Merge remote-tracking branch 'origin/master' into 2.3
Diffstat (limited to 'src/Wallabag/ApiBundle')
-rw-r--r--src/Wallabag/ApiBundle/Controller/EntryRestController.php3
-rw-r--r--src/Wallabag/ApiBundle/Form/Type/ClientType.php6
2 files changed, 7 insertions, 2 deletions
diff --git a/src/Wallabag/ApiBundle/Controller/EntryRestController.php b/src/Wallabag/ApiBundle/Controller/EntryRestController.php
index dbff6065..632b16d9 100644
--- a/src/Wallabag/ApiBundle/Controller/EntryRestController.php
+++ b/src/Wallabag/ApiBundle/Controller/EntryRestController.php
@@ -95,12 +95,13 @@ class EntryRestController extends WallabagRestController
95 $tags = $request->query->get('tags', ''); 95 $tags = $request->query->get('tags', '');
96 $since = $request->query->get('since', 0); 96 $since = $request->query->get('since', 0);
97 97
98 /** @var \Pagerfanta\Pagerfanta $pager */
98 $pager = $this->getDoctrine() 99 $pager = $this->getDoctrine()
99 ->getRepository('WallabagCoreBundle:Entry') 100 ->getRepository('WallabagCoreBundle:Entry')
100 ->findEntries($this->getUser()->getId(), $isArchived, $isStarred, $sort, $order, $since, $tags); 101 ->findEntries($this->getUser()->getId(), $isArchived, $isStarred, $sort, $order, $since, $tags);
101 102
102 $pager->setCurrentPage($page);
103 $pager->setMaxPerPage($perPage); 103 $pager->setMaxPerPage($perPage);
104 $pager->setCurrentPage($page);
104 105
105 $pagerfantaFactory = new PagerfantaFactory('page', 'perPage'); 106 $pagerfantaFactory = new PagerfantaFactory('page', 'perPage');
106 $paginatedCollection = $pagerfantaFactory->createRepresentation( 107 $paginatedCollection = $pagerfantaFactory->createRepresentation(
diff --git a/src/Wallabag/ApiBundle/Form/Type/ClientType.php b/src/Wallabag/ApiBundle/Form/Type/ClientType.php
index 0ea1a9c5..eaea4feb 100644
--- a/src/Wallabag/ApiBundle/Form/Type/ClientType.php
+++ b/src/Wallabag/ApiBundle/Form/Type/ClientType.php
@@ -16,7 +16,11 @@ class ClientType extends AbstractType
16 { 16 {
17 $builder 17 $builder
18 ->add('name', TextType::class, ['label' => 'developer.client.form.name_label']) 18 ->add('name', TextType::class, ['label' => 'developer.client.form.name_label'])
19 ->add('redirect_uris', UrlType::class, ['required' => false, 'label' => 'developer.client.form.redirect_uris_label']) 19 ->add('redirect_uris', UrlType::class, [
20 'required' => false,
21 'label' => 'developer.client.form.redirect_uris_label',
22 'property_path' => 'redirectUris',
23 ])
20 ->add('save', SubmitType::class, ['label' => 'developer.client.form.save_label']) 24 ->add('save', SubmitType::class, ['label' => 'developer.client.form.save_label'])
21 ; 25 ;
22 26