<?php
namespace App\Models;

class FinanceApproval
{
    public $id;
    public $deal_payment_id;
    public $deal_didar_id;
    public $status;
    public $approved_amount;
    public $approver_user_id;
    public $approved_at;
    public $rejection_reason;
    public $created_at;
    public $updated_at;

    public function __construct(array $data = [])
    {
        foreach ($data as $key => $value) {
            if (property_exists($this, $key)) {
                $this->$key = $value;
            }
        }
    }

    public function toArray(): array
    {
        return get_object_vars($this);
    }
}
