diff options
author | Thomas Citharel <tcit@tcit.fr> | 2017-05-04 14:35:14 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-04 14:35:14 +0200 |
commit | 6b76ae3d1f6a061237f983622b2d3708beded368 (patch) | |
tree | c0085b25c6ff8eec25f2b785cf985a8e95f25b09 /src/Wallabag/UserBundle/Form | |
parent | 3b4502e0e663866e7bac00164fd935fdc92309d6 (diff) | |
parent | b5b6877976bc32f23e51c2fb0f3f973f0d571b10 (diff) | |
download | wallabag-6b76ae3d1f6a061237f983622b2d3708beded368.tar.gz wallabag-6b76ae3d1f6a061237f983622b2d3708beded368.tar.zst wallabag-6b76ae3d1f6a061237f983622b2d3708beded368.zip |
Merge pull request #3060 from wallabag/search-users
Search & paginate users
Diffstat (limited to 'src/Wallabag/UserBundle/Form')
-rw-r--r-- | src/Wallabag/UserBundle/Form/SearchUserType.php | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/Wallabag/UserBundle/Form/SearchUserType.php b/src/Wallabag/UserBundle/Form/SearchUserType.php new file mode 100644 index 00000000..9ce46ee1 --- /dev/null +++ b/src/Wallabag/UserBundle/Form/SearchUserType.php | |||
@@ -0,0 +1,29 @@ | |||
1 | <?php | ||
2 | |||
3 | namespace Wallabag\UserBundle\Form; | ||
4 | |||
5 | use Symfony\Component\Form\AbstractType; | ||
6 | use Symfony\Component\Form\Extension\Core\Type\TextType; | ||
7 | use Symfony\Component\Form\FormBuilderInterface; | ||
8 | use Symfony\Component\OptionsResolver\OptionsResolver; | ||
9 | |||
10 | class SearchUserType extends AbstractType | ||
11 | { | ||
12 | public function buildForm(FormBuilderInterface $builder, array $options) | ||
13 | { | ||
14 | $builder | ||
15 | ->setMethod('GET') | ||
16 | ->add('term', TextType::class, [ | ||
17 | 'required' => true, | ||
18 | 'label' => 'user.new.form_search.term_label', | ||
19 | ]) | ||
20 | ; | ||
21 | } | ||
22 | |||
23 | public function configureOptions(OptionsResolver $resolver) | ||
24 | { | ||
25 | $resolver->setDefaults([ | ||
26 | 'csrf_protection' => false, | ||
27 | ]); | ||
28 | } | ||
29 | } | ||