<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

class PostApprovalFlow extends Model
{
    use SoftDeletes;

    protected $table = 'post_approval_flow';

    protected $fillable = [
        'type_customer',
        'type_entity',
        'solar_for',
        'sub_category',
        'lender_id',
        'applicant',
        'co_applicant'
    ];

    protected $dates = ['deleted_at'];

    protected $casts = [
        'applicant' => 'array',
        'co_applicant' => 'array',
    ];

    public function lender(){
        return $this->belongsTo(Lenders::class, 'lender_id');
    }
    
}