Total Complexity | 2 |
Total Lines | 19 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
7 | class Post extends Model |
||
8 | { |
||
9 | /** |
||
10 | * The attributes that are mass assignable. |
||
11 | * |
||
12 | * @var array |
||
13 | */ |
||
14 | protected $fillable = [ |
||
15 | 'title', 'body', 'author_id', |
||
16 | ]; |
||
17 | |||
18 | public function author() |
||
19 | { |
||
20 | return $this->belongsTo(Author::class, 'author_id'); |
||
21 | } |
||
22 | |||
23 | public function images() |
||
26 | } |
||
27 | } |
||
28 |