Skip to content

Commit

Permalink
docs(): Add setRelations docs
Browse files Browse the repository at this point in the history
  • Loading branch information
doug-martin committed Apr 13, 2021
1 parent 87b3dc6 commit 928b958
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions documentation/docs/concepts/services.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,16 @@ Adds relations to a `DTO`
#### Returns
The DTO the relations were added to.

### `setRelations`
Sets relations on a `DTO`
#### Arguments
* `relationName: string` - The name of the relation
* `id: string | number` - The id of the DTO to add the relations to
* `relationIds: (string | number)[]` - The ids of the relations to set. If the relationIds is empty the all relations will be removed.
* `opts?: ModifyRelationOptions<DTO, Relation>` - Additional options apply when adding relations
#### Returns
The DTO the relations were added to.

### `setRelation`
Set a relation on a DTO
#### Arguments
Expand Down

0 comments on commit 928b958

Please sign in to comment.