here's the laravel eloquent relationships in simple example(from docs).
1- one-to-one

2- one-to-many

3- many-to-many

4- has-one-through

5- has-many-through

6- one-to-one-polymorphic

7- one-to-many-polymorphic

8- Many-to-many-polymorphic


Top comments (0)