ember.js - ember data hasMany relationship -


http://jsbin.com/eveqoke/150/edit

my payload looks this:

var customers = {   "customers":[     {"id":3,"name":"joe","bio":"some tex","contact":"ny"},     {"id":2,"name":"rox","bio":"mo' tex","contact":"la"}   ] };  var orders = {   "orders":[     {"id":1,"customer":3,"amount":20},     {"id":2,"customer":3,"amount":60}   ] }; 

obviously wont work, have serialzer http://mozmonkey.com/2013/12/loading-json-with-embedded-records-into-ember-data-1-0-0-beta/ works fine far, expet hasmany relationships.

is possible ember's store automatically detects relation btw 2 models? or has embedded?


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -