[Form] Added a field guess for AssertType('\DateTime') constraint

This commit is contained in:
Bernhard Schussek 2011-01-25 13:43:12 +01:00 committed by Fabien Potencier
parent ce61baf717
commit 34865a3533

View File

@ -137,6 +137,12 @@ class ValidatorFieldFactoryGuesser implements FieldFactoryGuesserInterface
array(), array(),
FieldFactoryGuess::LOW_CONFIDENCE FieldFactoryGuess::LOW_CONFIDENCE
); );
case '\DateTime':
return new FieldFactoryClassGuess(
'Symfony\Component\Form\DateField',
array(),
FieldFactoryGuess::MEDIUM_CONFIDENCE
);
} }
break; break;
case 'Symfony\Component\Validator\Constraints\Choice': case 'Symfony\Component\Validator\Constraints\Choice':