1
0
Files
services_core/app/Models/NotificationPreference.php
T
2026-07-31 13:57:11 +07:00

26 lines
505 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class NotificationPreference extends Model
{
protected $guarded = ['id'];
protected function casts(): array
{
return ['enabled' => 'boolean'];
}
public function event()
{
return $this->belongsTo(NotificationEvent::class, 'notification_event_id');
}
public function channelConfig()
{
return $this->belongsTo(NotificationChannel::class, 'notification_channel_id');
}
}