-
-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Removing Fragment from fragmentArray fails on PUT request #341
Comments
I just want to bump this issue as I'm having a very similar problem. Is this related to the open PR referenced here? #338 |
@joshuamanns My ember-data version is 3.10.0. Isn't the PR #338 is related to ember-data 3.13.0? |
@prabakaranfresh Were you ever able to resolve this? It's still a blocking issue for me and I'm debating if I should create an entire workaround instead of using fragments. |
@joshuamanns I am having a workaround. I am forcing addresses.map(address => address.send('becomeDirty')); |
Creating, Updating and Deleting fragments in Fragment Array works fine for a new model (
isNew: true
)On an existing model from server, deleting a fragment inside fragmentArray removes it from the model and setting
hasDirtyAttributes
totrue
. But while saving the model usingmodel.save
empty object is sent to server (Only on PUT Request)I am removing one of the addresses from the fragmentArray
After this the data sent to the server is an empty object
// Data to server {}
When I remove any fragment from the fragmentArray,
hasDirtyAttributes
is set astrue
for the model and the fragmentArray. But no data was sent to server onPUT
request usingmodel.save()
Referred this Issue: Remove fragment from fragment array? But mine happens only on
model.save()
The text was updated successfully, but these errors were encountered: