-
Notifications
You must be signed in to change notification settings - Fork 835
Open
Labels
Description
Please let me know if I'm not doing this in proper fashion, but the following is happening for me with 1.3.x and 1.4.0:
Restangular.one('parent', parentId).all('childcollection').getList().then(function(collection) {
$scope.childCollection = Restangular.copy(collection);
});
$scope.updateChildren = function(index) {
$scope.childCollection.putElement(index).then(function(updatedCollection) {
//Use updated collection
});
}
The above code returns an 'undefined is not a function' on putElement()
However if I do not use Restangular.copy but instead do:
Restangular.one('parent', parentId).all('childcollection').getList().then(function(collection) {
$scope.childCollection = collection;
});
No problems using putElement.