2016-05-19 15:01:28 +01:00
|
|
|
<?php
|
|
|
|
|
2018-01-15 14:02:13 +00:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
2017-12-19 16:00:42 +00:00
|
|
|
namespace App\Models;
|
2016-05-19 15:01:28 +01:00
|
|
|
|
2020-10-17 17:15:06 +01:00
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
2016-05-19 15:01:28 +01:00
|
|
|
use Illuminate\Database\Eloquent\Model;
|
2018-01-15 14:02:13 +00:00
|
|
|
use Illuminate\Database\Eloquent\Relations\HasMany;
|
2016-05-19 15:01:28 +01:00
|
|
|
|
2016-05-29 14:21:46 +01:00
|
|
|
class MicropubClient extends Model
|
2016-05-19 15:01:28 +01:00
|
|
|
{
|
2020-10-17 17:15:06 +01:00
|
|
|
use HasFactory;
|
|
|
|
|
2023-02-18 09:34:57 +00:00
|
|
|
/** @var string */
|
2016-05-19 15:01:28 +01:00
|
|
|
protected $table = 'clients';
|
|
|
|
|
2023-02-18 09:34:57 +00:00
|
|
|
/** @var array<int, string> */
|
2016-05-19 15:01:28 +01:00
|
|
|
protected $fillable = ['client_url', 'client_name'];
|
2017-06-22 14:30:10 +01:00
|
|
|
|
2018-01-15 14:02:13 +00:00
|
|
|
public function notes(): HasMany
|
2017-06-22 15:44:41 +00:00
|
|
|
{
|
2017-12-19 16:00:42 +00:00
|
|
|
return $this->hasMany('App\Models\Note', 'client_id', 'client_url');
|
2017-06-22 14:30:10 +01:00
|
|
|
}
|
2016-05-19 15:01:28 +01:00
|
|
|
}
|