PUT not putting changes when model is get through $object
See original GitHub issuerestanglar v1.3.1
$scope.data = Restangular.one("collection", "1245").get().$object;
// I got back
{
title: "some title"
}
$scope.data.title = "title 123";
$scope.data.put();
It will not put the changes.
But if get through promise it will work.
Restangular.one("collection", "1245").get().then(function(result) {
$scope.data = result;
});
$scope.data.title = "title 123";
$scope.data.put(); // will work
Issue Analytics
- State:
- Created 10 years ago
- Reactions:1
- Comments:24 (2 by maintainers)
Top Results From Across the Web
Django model method not making changes to object
1 Answer 1 · you set a variable with a single equal sign ( = ), not a double equal sign ( ==...
Read more >Why we Avoid Putting Value Objects in Events
What's the harm in putting Value Objects in your Events? ... As your domain model evolves, you may add new invariants to be...
Read more >PutObject - Amazon Simple Storage Service
To successfully change the objects acl of your PutObject request, you must have the s3:PutObjectAcl in your IAM permissions. To successfully set the...
Read more >Using Objects - The Java™ Tutorials
Once you've created an object, you probably want to use it for something. You may need to use the value of one of...
Read more >Link or embed a PowerPoint slide in a Word document
If you insert the slide into the document as a PowerPoint object, Word runs PowerPoint when ... The presentation object can be embedded...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
+1
@peter-bertuglia Great !! Here is an upgrade handling collections as well as element.
EDIT
There were too much codes… this is well enough :
With the previous version, if you did a Restangular.extendModel, you received twice each resource instead of once. And when working with events, those were triggered twice…
Bye !