@if(!empty(\App\Models\Setting::where('setting_key','company_logo')->first()->setting_value)) @endif

{{\App\Models\Setting::where('setting_key','company_name')->first()->setting_value}}

@if(!empty($loan->client)) @if($loan->client->client_type=="individual") {{$loan->client->first_name}} {{$loan->client->middle_name}} {{$loan->client->last_name}} ({{trans_choice('general.individual',1)}}) @else {{$loan->client->full_name}} ({{trans_choice('general.business',1)}}) @endif @endif {{trans_choice('general.loan',1)}} {{trans_choice('general.statement',1)}}


@foreach(\App\Models\LoanTransaction::where('loan_id',$loan->id)->whereIn('reversal_type',['user','none'])->orderBy('date','asc')->orderBy('id','asc')->get() as $key) @endforeach
{{trans_choice('general.date',1)}} {{trans_choice('general.submitted',1)}} {{trans_choice('general.on',1)}} {{trans_choice('general.transaction',1)}} {{trans_choice('general.type',1)}} {{trans_choice('general.debit',1)}} [ZMK] {{trans_choice('general.credit',1)}} [ZMK] {{trans_choice('general.balance',1)}} [ZMK]
{{ Carbon\Carbon::parse($key->date)->format('d/m/Y') }} {{ Carbon\Carbon::parse($key->created_at)->format('d/m/Y') }} @if($key->transaction_type=='disbursement') {{trans_choice('general.disbursement',1)}} @endif @if($key->transaction_type=='specified_due_date_fee') {{trans_choice('general.specified_due_date',2)}} {{trans_choice('general.fee',1)}} @endif @if($key->transaction_type=='installment_fee') {{trans_choice('general.installment_fee',2)}} @endif @if($key->transaction_type=='overdue_installment_fee') {{trans_choice('general.overdue_installment_fee',2)}} @endif @if($key->transaction_type=='loan_rescheduling_fee') {{trans_choice('general.loan_rescheduling_fee',2)}} @endif @if($key->transaction_type=='overdue_maturity') {{trans_choice('general.overdue_maturity',2)}} @endif @if($key->transaction_type=='disbursement_fee') {{trans_choice('general.disbursement',1)}} {{trans_choice('general.charge',2)}} @endif @if($key->transaction_type=='interest') {{trans_choice('general.interest',1)}} {{trans_choice('general.applied',2)}} @endif @if($key->transaction_type=='repayment') {{trans_choice('general.repayment',1)}} @endif @if($key->transaction_type=='penalty') {{trans_choice('general.penalty',1)}} @endif @if($key->transaction_type=='interest_waiver') {{trans_choice('general.interest',1)}} {{trans_choice('general.waiver',2)}} @endif @if($key->transaction_type=='waiver') {{trans_choice('general.waiver',2)}} @endif @if($key->transaction_type=='') {{trans_choice('general.waiver',2)}} @endif @if($key->transaction_type=='charge_waiver') {{trans_choice('general.charge',1)}} {{trans_choice('general.waiver',2)}} @endif @if($key->transaction_type=='write_off') {{trans_choice('general.write_off',1)}} @endif @if($key->transaction_type=='repayment_disbursement') {{trans_choice('general.repayment',1)}} {{trans_choice('general.disbursement',1)}} @endif @if($key->transaction_type=='adjusted_interest') Reloan Interest @endif @if($key->transaction_type=='write_off_recovery') {{trans_choice('general.recovery',1)}} {{trans_choice('general.repayment',1)}} @endif @if($key->reversed==1) @if($key->reversal_type=="user") ({{trans_choice('general.user',1)}} {{trans_choice('general.reversed',1)}} ) @endif @if($key->reversal_type=="system") ({{trans_choice('general.system',1)}} {{trans_choice('general.reversed',1)}} ) @endif @endif {{number_format($key->debit,2)}} {{number_format($key->credit,2)}} {{number_format($balance,2)}}
TOTALS {{ number_format($total_dr,2) }} {{ number_format($total_cr,2) }}