|
|
|
|
|
|
|
|
use Symfony\Component\HttpFoundation\ParameterBag; |
|
|
use Symfony\Component\HttpFoundation\ParameterBag; |
|
|
use Symfony\Component\HttpFoundation\Session\SessionInterface; |
|
|
use Symfony\Component\HttpFoundation\Session\SessionInterface; |
|
|
use Symfony\Component\Validator\Constraints\EqualTo; |
|
|
use Symfony\Component\Validator\Constraints\EqualTo; |
|
|
|
|
|
use Symfony\Component\Validator\Constraints\NotNull; |
|
|
use Symfony\Contracts\Translation\TranslatorInterface; |
|
|
use Symfony\Contracts\Translation\TranslatorInterface; |
|
|
|
|
|
|
|
|
class Utils |
|
|
class Utils |
|
|
|
|
|
|
|
|
'class' => 'special-field' |
|
|
'class' => 'special-field' |
|
|
], |
|
|
], |
|
|
'constraints' => [ |
|
|
'constraints' => [ |
|
|
|
|
|
new NotNull(), |
|
|
new EqualTo(['value' => $this->parameterBag->get('app.captcha_value'), 'message' => 'Valeur incorrecte']) |
|
|
new EqualTo(['value' => $this->parameterBag->get('app.captcha_value'), 'message' => 'Valeur incorrecte']) |
|
|
], |
|
|
], |
|
|
]); |
|
|
]); |