Mager updated
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
|
||||
class Email extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'person_id',
|
||||
'value',
|
||||
'label',
|
||||
'is_primary',
|
||||
'is_active',
|
||||
'valid',
|
||||
'verified_at',
|
||||
'preferences',
|
||||
'meta',
|
||||
];
|
||||
|
||||
protected $casts = [
|
||||
'is_primary' => 'boolean',
|
||||
'is_active' => 'boolean',
|
||||
'valid' => 'boolean',
|
||||
'verified_at' => 'datetime',
|
||||
'preferences' => 'array',
|
||||
'meta' => 'array',
|
||||
];
|
||||
|
||||
public function person(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(\App\Models\Person\Person::class, 'person_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user