-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Closed as not planned
Closed as not planned
Copy link
Description
Symfony 2.8.13
Below is my form date field
$builder->add('my_date', array(
'widget' => 'single_text',
'attr' => array(
'class' => 'date-picker',
'size' => 10,
),
'format' => 'dd-MM-yyyy',
'required' => false,
'input' => 'datetime',
'constraints' => [
new GreaterThanOrEqual([
'value' => new \DateTime('01-01-2000'),
'message' => 'Invalid date value',
]),
new LessThanOrEqual([
'value' => new \DateTime('31-12-9999'),
'message' => 'Invalid date value',
]),
],
)
);
After last merge the constraints GreaterThanOrEqual and LessThanOrEqual are not working anymore as the DateTimeToLocalizedStringTransformer returns different value than the user input
below is the dump of the transformed value (submitted value is 01-01-20033)
ashatp, farizyoga and keksa