I've got an entity with some validators (not a form).
So I use $validator->validate($entity)
, but it doesn't validate my sub-ojects (the entity class has some others entity classes with some validators).
Is there an "automatic" way to do this, or I have to do $errorList->addAll($validator->validate($entity));
for each of them ?
@Assert\Valid
on the property@Assert\Type(...)
would be enough..