| 1 | <?php |
||
| 20 | class LeagueTeam extends Eloquent { |
||
|
|
|||
| 21 | |||
| 22 | protected $fillable = ['name']; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * The league this team is in |
||
| 26 | * |
||
| 27 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo |
||
| 28 | */ |
||
| 29 | public function league() { |
||
| 32 | |||
| 33 | /** |
||
| 34 | * The users that are in this team |
||
| 35 | * |
||
| 36 | * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany |
||
| 37 | */ |
||
| 38 | 9 | public function users() { |
|
| 41 | |||
| 42 | /** |
||
| 43 | * The movies this team owns |
||
| 44 | * |
||
| 45 | * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany |
||
| 46 | */ |
||
| 47 | 9 | public function movies() { |
|
| 50 | } |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.