<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Factories\HasFactory;


/**
 * @mixin IdeHelperTeamMember
 */
class TeamMember extends Model
{
    use HasFactory;

    protected $fillable = [
        'full_name',
        'slug',
        'title',
        'department',
        'bio',
        'image',
        'email',
        'phone',
        'whatsapp_phone',
        'linkedin_url',
        'instagram_url',
        'sort_order',
        'is_active',
        'is_featured',
    ];

    protected $casts = [
        'sort_order' => 'integer',
        'is_active' => 'boolean',
        'is_featured' => 'boolean',
    ];

    public function scopeActive($query)
    {
        return $query->where('is_active',true);
    }

    public function scopeFeatured($query)
    {
        return $query->where('is_featured',true);
    }


}
