Open mattiassvedhem opened 12 years ago
Tenacity currently does not support Single Table Inheritance. I'm not sure what it would take to implement, but I can take a look later on this week after I return from vacation. However, implementing many-to-many will be the next feature I plan on adding. So, it may be a while until I get to this.
Feel free to give it a shot if you'd like.
Ok, after some testing.
It does seem to work if I add the user_id manually. However if I change the type of the user, user_id on associated documents gets nil'ed.
I'll see if I can fix it.
I have set up a User model and a Manager model with Single Table inheritance like this :
And a Mongoid model :
However the association only works when the user is a User and not a Manager. If i try to add posts to a manager I just get an empty array when trying to fetch them trough user.posts.
Any thoughts on this? Thanks