You've already forked Atomcms-edit
34 lines
678 B
PHP
Executable File
34 lines
678 B
PHP
Executable File
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Models\User;
|
|
|
|
use App\Models\Concerns\BelongsToUser;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
/**
|
|
* @method static \Illuminate\Database\Eloquent\Builder<static>|UserNotification create($attributes = [])
|
|
*/
|
|
class UserNotification extends Model
|
|
{
|
|
use BelongsToUser;
|
|
|
|
#[\Override]
|
|
protected $guarded = ['id', 'created_at', 'updated_at', 'user_id', 'type'];
|
|
|
|
#[\Override]
|
|
public $timestamps = true;
|
|
|
|
/** @var array<string, string> */
|
|
#[\Override]
|
|
protected $casts = [
|
|
'read' => 'boolean',
|
|
];
|
|
|
|
public static function insert(array $data): void
|
|
{
|
|
self::create($data);
|
|
}
|
|
}
|