Feature #45409

Support validation of abstract nested properties

Added by Aske Ertmann over 8 years ago. Updated over 8 years ago.

Should have
Target version:
Start date:
Due date:
% Done:


Estimated time:
PHP Version:
Has patch:


Currently the validation of properties in action controllers does not take the property mapping configuration into account causing missing validation of nested abstract properties.

If you have an entity which has a collection of or is an abstract entity, it is possible to use the property mapping configuration to set which kind of abstract entity you'd want to convert/typehint to. But that is not respected in the validator resolver meaning that the validator resolver only returns a conjunction validator for the properties in the abstract entity and not the typehintet one.

There are two reasons for implementing this, which are 1) the missing validation leads to exceptions when the nested properties are persisted in the entity manager, 2) the validation is missing in the form.

Account (Security) has a party property which is of type \TYPO3\Party\Domain\Model\AbstractParty.

Then we have a \TYPO3\Party\Domain\Model\Person which extends the AbstractParty which has some more properties than the abstract party does. In the property mapping configuration I get configure it to use Person instead of a AbstractParty, but the validation resolves with AbstractParty meaning that the extra properties and their validation doesn't get taken into account.

I think the solution should be to tie the property mapping configuration to the validator resolver so when it's actually resolving validators for a property of an action controller it can check if any special converters where used to change the type of the property.


Updated by Aske Ertmann over 8 years ago

  • Project changed from TYPO3 Flow Base Distribution to TYPO3.Flow

Updated by Aske Ertmann over 8 years ago

  • Category set to Validation
  • Target version set to 2.1
  • Has patch set to No
  • Complexity set to medium

Updated by Robert Lemke over 8 years ago

  • Target version deleted (2.1)

Also available in: Atom PDF