You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi!
I'm trying to get ember-data @hasMany, one to many relationship to work - but keep failing. Then intention:
The scan-phase API will return a JSON object, with many phase objects.
If I put a debugger in the mirage/scenarios/default.js, mirage db seems to have a good data.
server.db.dump()
But then the error happened.
Error message:
Mirage: You're trying to create a scan-phase model and you passed in "[object Object],[object Object]" under the phases key, but that key is a HasMany relationship. You must pass in a Collection, PolymorphicCollection, array of Models, or null.
It looks like this error is actually happening in mirage but I cant tell when from the information. In Mirage you defined a route, could you post what this route looks like?
Bug or question
Hi!
I'm trying to get ember-data
@hasMany
, one to many relationship to work - but keep failing.Then intention:
The
scan-phase
API will return a JSON object, with manyphase
objects.If I put a debugger in the
mirage/scenarios/default.js
, mirage db seems to have a good data.But then the error happened.
Error message:
Diff from
ember-cli-mirage-boilerplate
rpringadi/ember-cli-mirage-boilerplate@b96acba
Env
ember-cli: 3.10.1
node: 14.16.1
os: darwin x64
Please advice what went wrong if possible. Thanks in advance.
If possible, please use the Mirage Boilerplate to demonstrate your issue or bug:
Visit the Ember CLI Mirage Boilerplate repo
Click Fork
Clone your fork locally, checkout a new branch, reproduce your issue and push
Link to your branch in your issue
https://github.com/rpringadi/ember-cli-mirage-boilerplate/tree/onetomanyrelationship
branch: onetomanyrelationship
The text was updated successfully, but these errors were encountered: