Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to compare followed reverse foreign relation fields that are on a non-abstract parent class #58

Closed
LegoStormtroopr opened this issue Feb 1, 2016 · 1 comment

Comments

@LegoStormtroopr
Copy link
Contributor

For example, given the models and register below:

class Association(Model):
    related_to = ForeignKey('Parent',related_name='associations')

class Parent(Model):
    text = TextField(null=True)

class Child(Parent):
    more_text = TextField(null=True)

reversion.revisions.register(Child, follow=['parent_ptr','associations'])

Both the parent and child instances will be stored in the relation, but due to how django serialisers work for multi-table inheritance the associations field will only be available on the Parent reversion, not the Child reversion. I've made a PR that addresses that will be added soon.

@jedie
Copy link
Owner

jedie commented Feb 1, 2016

PR always welcome! Please add a test, too ;)

LegoStormtroopr added a commit to LegoStormtroopr/django-reversion-compare that referenced this issue Feb 1, 2016
LegoStormtroopr added a commit to LegoStormtroopr/django-reversion-compare that referenced this issue Feb 1, 2016
LegoStormtroopr added a commit to LegoStormtroopr/django-reversion-compare that referenced this issue Feb 1, 2016
@jedie jedie closed this as completed in 931b3f5 Feb 3, 2016
jedie added a commit that referenced this issue Feb 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants