Description
Hi there,
I have notice that for a datetime Type, an automatic validation is done after form submiting.
I splitted my field like this:
$builder->add('matchDate', 'datetime', array(
'required' => false,
'invalid_message' => 'Hello',
'date_format' => 'dd/MM/yyyy',
'date_widget' => 'single_text',
'time_widget' => 'choice'
))
If I put for example "02/35/2013" in my matchDate.date field, I get an error on the matchDate field with "This value is not valid".
I looked in Symfony\Component\Validator\Constraints\Date.php, Symfony\Component\Validator\Constraints\Time.php, Symfony\Component\Validator\Constraints\DateTime.php and anywhere I could find this error message.
On my entity I have no validation constraints set. Did anyone notice the same behavior on this application ?
In fact, it's not a problem that the validation is done, it's more the unposibility to change the error message even in setting the 'invalid_message' option.
Thanks in advance for you help.
By the way, I'm actualy working on 2.2.0BETA1