2020-12-21 07:09:34 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Models;
|
|
|
|
|
2020-12-26 10:46:23 +00:00
|
|
|
use Illuminate\Database\Eloquent\Model;
|
2020-12-21 07:09:34 +00:00
|
|
|
|
2020-12-26 10:46:23 +00:00
|
|
|
class Location extends Model {
|
2020-12-21 07:09:34 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* The attributes that are mass assignable.
|
|
|
|
*
|
|
|
|
* @var array
|
|
|
|
*/
|
|
|
|
protected $fillable = [
|
|
|
|
'name',
|
|
|
|
];
|
2020-12-27 00:34:07 +00:00
|
|
|
|
|
|
|
public function books() {
|
|
|
|
return $this->hasMany(Book::class);
|
|
|
|
}
|
2020-12-21 07:09:34 +00:00
|
|
|
}
|