Use only child object when filling fixtures with relationship and concrete_inheritance #198

Merged
merged 3 commits into from Dec 22, 2012

Conversation

Projects
None yet
2 participants

This pull request fixes the issue #195.

To sum it up, let consider the following models:

  • IphoneApplication inherits from Application
  • Statistics is linked to an Application.

These changes allow to specify a reference to an IphoneApplication object to Statistics "application_id" property in the fixtures. The base Application will be automatically created and used for the relationship.

PS: I commited on 1.1 branch. Have I to apply my changes on 1.0 branch manually and ask for a new pull request, or is there any GitHub feature to synchronize them?

It seems there is still an issue: parent tables does not seem to be cleared when loading fixtures another time.

I am looking at it this week-end.

Parent data are now cleared when loading new fixtures, avoiding duplicates.

@willdurand willdurand added a commit that referenced this pull request Dec 22, 2012

@willdurand willdurand Merge pull request #198 from jpetitcolas/1.1
Use only child object when filling fixtures with relationship and concrete_inheritance
26596d1

@willdurand willdurand merged commit 26596d1 into propelorm:1.1 Dec 22, 2012

1 check passed

default The Travis build passed
Details
Owner

willdurand commented Dec 22, 2012

thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment