22 lines
432 B
PHP
22 lines
432 B
PHP
<?php
|
|||
|
|
|
||
|
|
namespace App\Models;
|
||
|
|
|
||
|
|
use Illuminate\Database\Eloquent\Model;
|
||
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||
|
|
|
||
|
|
class UserIdentity extends Model
|
||
|
|
{
|
||
|
|
protected $fillable = ['user_id', 'type', 'identifier', 'verified_at'];
|
||
|
|
|
||
|
|
protected function casts(): array
|
||
|
|
{
|
||
|
|
return ['verified_at' => 'datetime'];
|
||
|
|
}
|
||
|
|
|
||
|
|
public function user(): BelongsTo
|
||
|
|
{
|
||
|
|
return $this->belongsTo(User::class);
|
||
|
|
}
|
||
|
|
}
|