<?php

namespace App\Models;

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

class ProfileFieldGroup extends Model
{
    use HasFactory;

    protected $fillable = [
        'association_id',
        'name',
        'description',
        'order',
        'is_active',
    ];

    public function association()
    {
        return $this->belongsTo(Association::class);
    }

    public function fields()
    {
        return $this->hasMany(ProfileField::class, 'group_id');
    }
}
