SupportsInverseRelations
trait SupportsInverseRelations
Properties
| protected string|null | $inverseRelationship | The name of the inverse relationship. |
Methods
Instruct Eloquent to link the related models back to the parent after the relationship query has run.
Instruct Eloquent to link the related models back to the parent after the relationship query has run.
Guess the name of the inverse relationship.
Get the possible inverse relations for the parent model.
Set the inverse relation on all models in a collection.
Set the inverse relation on a model.
Get the name of the inverse relationship.
Remove the chaperone / inverse relationship for this query.
Remove the chaperone / inverse relationship for this query.
Details
at line 27
SupportsInverseRelations
inverse(string|null $relation = null)
Instruct Eloquent to link the related models back to the parent after the relationship query has run.
Alias of "chaperone".
at line 37
SupportsInverseRelations
chaperone(string|null $relation = null)
Instruct Eloquent to link the related models back to the parent after the relationship query has run.
at line 61
protected string|null
guessInverseRelation()
Guess the name of the inverse relationship.
at line 74
protected array
getPossibleInverseRelations()
Get the possible inverse relations for the parent model.
at line 92
protected mixed
applyInverseRelationToCollection(mixed $models, Model|null $parent = null)
Set the inverse relation on all models in a collection.
at line 107
protected Model
applyInverseRelationToModel(Model $model, Model|null $parent = null)
Set the inverse relation on a model.
at line 121
string|null
getInverseRelationship()
Get the name of the inverse relationship.
at line 133
SupportsInverseRelations
withoutInverse()
Remove the chaperone / inverse relationship for this query.
Alias of "withoutChaperone".
at line 143
SupportsInverseRelations
withoutChaperone()
Remove the chaperone / inverse relationship for this query.