Skip to content

Nested embedded loading fails to materialize records #559

Closed
wants to merge 8 commits into from

4 participants

@rykov
rykov commented Dec 29, 2012

One level of embedding works:

comment: { ... user: { ... }}

However, when you have an embedded record within another embedded record, the record is not correctly loaded into the store (userGroup in the example below).

comment: { ... user: { ... userGroup: {...}}}

I've included the failed unit tests that expose this issue

@darthdeus
Ember.js member

Is this on current master with merged embedded-records branch?

@rykov
rykov commented Jan 1, 2013

Yes, the tests fail on the tip of master.

@rykov rykov Merge branch 'master' of git://github.com/emberjs/data
Conflicts:
	packages/ember-data/tests/integration/embedded/embedded_loading_test.js
459b77f
@wagenet wagenet and 1 other commented on an outdated diff Jan 9, 2013
...a/tests/integration/embedded/embedded_loading_test.js
@@ -8,8 +8,14 @@ var Comment = DS.Model.extend({
user: DS.belongsTo(Person)
});
+var Group = DS.Model.extend({
@wagenet
Ember.js member
wagenet added a note Jan 9, 2013

This should be var Group = App.Group = DS.Model.extend({. Without the App.Group, you'll get other unrelated errors.

@rykov
rykov added a note Jan 9, 2013

Fixed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@wagenet
Ember.js member
wagenet commented Jan 9, 2013

I've verified that these tests do fail on current master. However, it would be helpful if you could rebase for future merging. @rykov

@rykov
rykov commented Jan 9, 2013

@wagenet - Just updated to latest master

@sandstrom

I think I may have a solution for this problem: #637

@rykov
rykov commented Jan 18, 2013

Closing -- merged as part of #637

@rykov rykov closed this Jan 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.