summaryrefslogtreecommitdiff
path: root/Year_3/TSDWL/LARAVEL/iBook/app/Models/Book.php
blob: 98c4ac2ef6f709c9fe731476eef1393174c1ac01 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

use App\Models\Author;

class Book extends Model
{
    use HasFactory;

    public function author()
    {
        return $this->belongsTo(Author::class);
    }
}