formatting

This commit is contained in:
Taylor Otwell 2018-08-14 14:47:35 -05:00
parent 3a775c2d06
commit da9b18a857
1 changed files with 1 additions and 1 deletions

View File

@ -325,7 +325,7 @@ You can also filter the results returned by `belongsToMany` using the `wherePivo
#### Defining Custom Intermediate Table Models
If you would like to define a custom model to represent the intermediate table of your relationship, you may call the `using` method when defining the relationship. Many to Many relationships should extend `Illuminate\Database\Eloquent\Relations\Pivot` and Many To Many Polymorphic relationships the `Illuminate\Database\Eloquent\Relations\MorphPivot` class. For example, we may define a `Role` which uses a custom `UserRole` pivot model:
If you would like to define a custom model to represent the intermediate table of your relationship, you may call the `using` method when defining the relationship. Custom many-to-many pivot models should extend the `Illuminate\Database\Eloquent\Relations\Pivot` class while custom polymorphic many-to-many pivot models should extend the `Illuminate\Database\Eloquent\Relations\MorphPivot` class. For example, we may define a `Role` which uses a custom `UserRole` pivot model:
<?php