1
0
Fork 0
arangodb/Documentation/DocuBlocks/JSF_foxx_repository_replace...

17 lines
377 B
Markdown

`FoxxRepository#replaceById(id, object)`
Find the item in the database by the given ID ("collection/key") or "key"
and replace it with the given object's attributes.
If the object is a model, updates the model's revision and returns the model.
@EXAMPLES
```javascript
repository.replaceById('test/123345', myNewModel);
repository.replaceById('123346', myNewModel);
```