You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I need the users loaded by this bundle to implement an interface so I can use them in place of my other users loaded by FOSUserBundle.
I was able to almost do this by making a child bundle to override the Entitiy/User.php file with a new one. I had to just copy-paste the entity from the bundle and add my interface and implement the methods. The problem is, since the Doctrine mapping is already in the annotations in this bundle, I now have two entities that use the same table.
I added resolve_target_entities to my config which seemed to work:
The problem is that my unittests/functional tests always load fixtures and Doctrine doesn't like that it finds two entities that map to the table wp_users.
Could you make some change so that users can be overridden? Maybe use the MappedSuperclass pattern that FOSUserBundle does https://symfony.com/doc/1.3.x/bundles/FOSUserBundle/index.html ? If there is some other way I can accomplish this, please let me know.
The text was updated successfully, but these errors were encountered:
I need the users loaded by this bundle to implement an interface so I can use them in place of my other users loaded by FOSUserBundle.
I was able to almost do this by making a child bundle to override the Entitiy/User.php file with a new one. I had to just copy-paste the entity from the bundle and add my interface and implement the methods. The problem is, since the Doctrine mapping is already in the annotations in this bundle, I now have two entities that use the same table.
I added
resolve_target_entities
to my config which seemed to work:The problem is that my unittests/functional tests always load fixtures and Doctrine doesn't like that it finds two entities that map to the table
wp_users
.Could you make some change so that users can be overridden? Maybe use the MappedSuperclass pattern that FOSUserBundle does https://symfony.com/doc/1.3.x/bundles/FOSUserBundle/index.html ? If there is some other way I can accomplish this, please let me know.
The text was updated successfully, but these errors were encountered: