]> Raphaël G. Git Repositories - userbundle/blob - Form/LoginType.php
Rename Repository/EntityRepository in Repository
[userbundle] / Form / LoginType.php
1 <?php declare(strict_types=1);
2
3 /*
4 * This file is part of the Rapsys UserBundle package.
5 *
6 * (c) Raphaël Gertz <symfony@rapsys.eu>
7 *
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
10 */
11
12 namespace Rapsys\UserBundle\Form;
13
14 use Symfony\Component\OptionsResolver\OptionsResolver;
15
16 /**
17 * {@inheritdoc}
18 */
19 class LoginType extends RegisterType {
20 /**
21 * {@inheritdoc}
22 */
23 public function configureOptions(OptionsResolver $resolver): void {
24 //Call parent configure option
25 parent::configureOptions($resolver);
26
27 //Set defaults
28 $resolver->setDefaults(['civility' => false, 'password' => true, 'password_repeated' => false, 'forename' => false, 'surname' => false]);
29 }
30
31 /**
32 * {@inheritdoc}
33 */
34 public function getName(): string {
35 return 'rapsys_user_login';
36 }
37 }