<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class LoanSetting extends Model
{
    protected $fillable = [

        'enabled',

        'interest_rate',

        'processing_fee_type',

        'processing_fee',

        'minimum_loan_amount',

        'maximum_loan_amount',

        'allowed_tenures',

    ];


    protected $casts = [

        'enabled' =>
            'boolean',

        'interest_rate' =>
            'decimal:2',

        'processing_fee' =>
            'decimal:2',

        'minimum_loan_amount' =>
            'decimal:2',

        'maximum_loan_amount' =>
            'decimal:2',

        'allowed_tenures' =>
            'array',

    ];
}