doctrine / orm

Doctrine Object Relational Mapper (ORM)
https://www.doctrine-project.org/projects/orm.html
MIT License
9.93k stars 2.51k forks source link

DDC-2901: entity-listeners are not propagated to children of mapped superclasses #3660

Open doctrinebot opened 10 years ago

doctrinebot commented 10 years ago

Jira issue originally created by user stuartcarnie:

If I have event-listeners set on the subclass and mapped superclass, event-listeners will not be propagated, per this code. Conversely, lifecycle events are, per this

doctrinebot commented 10 years ago

Comment created by @ocramius:

[~stuartcarnie] I lost the code references that you linked, since the code changed and the line numbers don't match anymore.

Any chance that you can provide a failing test for this issue, as well as update the links to reference a fixed commit hash or tag?

doctrinebot commented 10 years ago

Comment created by stuartcarnie:

[~ocramius], I've updated the URIs in the description to the right tree

doctrinebot commented 10 years ago

Comment created by @ocramius:

The code explicitly forbids inheriting listeners when the child class does not have any.

[~fabio.bat.silva] can you provide any insight on why this decision was made?

doctrinebot commented 8 years ago

Comment created by netsuo:

Hi,

Is this resolved ? Is there any "clean" workaround ?

I had to set my mappersuperclass' listener on the children to make it work, but it isn't really the best solution