Constructor
new Relation(definition, modelInstance) → {Relation}
A relation attaching to a given model instance
Parameters:
Name | Type | Description |
---|---|---|
definition |
RelationDefinition | Object | |
modelInstance |
Object |
- Source:
Returns:
- Type
- Relation
Methods
fetch((Boolean|Object}, optionsopt, cb)
Fetch the related model(s) - this is a helper method to unify access.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
(Boolean|Object} |
condOrRefresh refresh or conditions object | ||
options |
Object |
<optional> |
Options |
cb |
function | callback |
- Source: