[Flow] How to define targetEntity in abstractClass

Karsten Dambekalns karsten at typo3.org
Tue Jul 22 08:50:44 CEST 2014


Hi.

On 21.07.2014, at 10:38, Alexander Wende <a_wende at web.de> wrote:

> I'm trying to build a "revision-safe" model for some entities like pages, news and so on.
> Page and news model extends the revising model which contains pointers to the previous revision and the next revision.
…
> But how did I tell doctrine which concrete entities should be used in page or news model? I can't use the targetEntity anotation because the concrete entity depends on the class which extends the abstract class.

You want to read about and use inheritance mapping: http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/inheritance-mapping.html

Regards,
Karsten


More information about the Flow mailing list