<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Spatie\Activitylog\Traits\LogsActivity;
use Spatie\Activitylog\LogOptions;

class StudentLife extends Model
{
    use LogsActivity;

    protected $fillable = [
        'main_title',
        'background_image',
        'text',
        'description',
        'images',
        'event_count',
        'images_count',
    ];

    protected $casts = [
        'images' => 'array',
    ];

    public function getActivitylogOptions(): \Spatie\Activitylog\LogOptions
    {
        return \Spatie\Activitylog\LogOptions::defaults()->logAll();
    }
}
