src/Form/Account/LostPasswordType.php line 13

Open in your IDE?
  1. <?php
  2. namespace App\Form\Account;
  3. use App\Actimage\CaptchaBundle\Form\Type\ActimageCaptchaType;
  4. use App\Form\AbstractFrontType;
  5. use EWZ\Bundle\RecaptchaBundle\Form\Type\EWZRecaptchaType;
  6. use EWZ\Bundle\RecaptchaBundle\Validator\Constraints\IsTrue;
  7. use Symfony\Component\Form\Extension\Core\Type\EmailType;
  8. use Symfony\Component\Form\FormBuilderInterface;
  9. use Symfony\Component\Validator\Constraints\NotBlank;
  10. class LostPasswordType extends AbstractFrontType
  11. {
  12.     public function buildForm(FormBuilderInterface $builder, array $options): void
  13.     {
  14.         $builder
  15.             ->add('email'EmailType::class, [
  16.                 'label'       => 'lost_password.step1.form.email.label',
  17.                 'required'    => true,
  18.                 'constraints' => [new NotBlank()],
  19.             ])
  20. //            ->add('recaptcha', EWZRecaptchaType::class, [
  21. //                'label'       => false,
  22. //                'mapped'      => false,
  23. //                'required'    => true,
  24. //                'constraints' => [new IsTrue()],
  25. //            ]);
  26.             ->add('captcha'ActimageCaptchaType::class, [
  27.                 'label'       => false,
  28.                 'mapped'      => false,
  29.                 'required'    => true,
  30.             ]);
  31.     }
  32. }