ember.js - Saving models and their relationships using the new Ember Data JSONAPISerializer/Adapter -
i have implemented json-api backend , i'm using ember (1.13.4) , ember data (1.13.5) pull data in store using new jsonapiadapter / jsonapiserializer. working , store populated of models , attributes/relationships.
however, when call .save() method on models json-api-formatted request generated doesn't contain "included" key related models inside it. means if modify attribute in related model , save primary model don't see changed attribute related model in json payload.
what correct way save models , relationships embedded using new jsonapiadapter / jsonapiserializer? tried embeddedrecordsmixin resulted in null attribute values within "attributes" key of payload.
if can assist me i'd grateful.
thanks.
ok, has been answered on ember forum follows:
"the standard not support @ moment , scheduled v1.1 (http://discuss.jsonapi.org/t/json-api-weekly-meeting-june-22nd-2015/23).
your best bet inherit serializer , implement own standard now. remember include included paths in url server can reply updated entities."
more information can found here.
Comments
Post a Comment