@extends('layouts/acc_layout') @section('title', '| Register Report') @section('content')

OTS Account Closing Report

{{--
kxghixd
--}}
{!! Form::open(['url' => 'viewOtsAccountClosingReport','method' => 'get']) !!} {!! Form::hidden('firstRequest',1) !!}
{!! Form::label('', 'Branch Location:', ['class' => 'control-label pull-left']) !!}
{!! Form::label('', ' ', ['class' => 'control-label']) !!}
{!! Form::text('dateFrom',$dateFromSelected,['id'=>'dateFrom','placeholder'=>'From','class'=>'form-control input-sm','readonly','style'=>'cursor:pointer']) !!}
{!! Form::text('dateTo',$dateToSelected,['id'=>'dateTo','placeholder'=>'To','class'=>'form-control input-sm','readonly','style'=>'cursor:pointer']) !!}
{!! Form::submit('Search',['id'=>'search','class'=>'btn btn-primary btn-xs','style'=>'font-size:15px;']) !!}
{!! Form::close() !!}
{{-- End Filtering Group --}} @if(!$firstRequest) @php if($branchSelected===0){ $selectedBranchName = "All Branches"; } else{ $selectedBranchName = DB::table('gnr_branch')->where('id',$branchSelected)->value('name'); } $selectedProjectName = DB::table('gnr_project')->where('id',$projectSelected)->value('name'); @endphp

@php $total = 0; @endphp @foreach($closingAccounts as $index => $payment) {{-- --}} @php $total = $total + (float) $payment->amount; @endphp @endforeach
SL# Date Account Name Account ID Branch Payment & Deduction (Tk) Net Payment
Principal Amount Interest Payment Closing Fee
{{$index+1}} {{date('d-m-Y',strtotime($payment->closingDate))}} {{$memberNames[$index]}} {{$payment->accNo}} {{$branchNames[$index]}} {{number_format($principalAmounts[$index],2,'.',',')}}{{number_format($interestDues[$index],2,'.',',')}}{{number_format($payment->dueAmount,2,'.',',')}} {{number_format($payment->accClosingCharge,2,'.',',')}} {{number_format($payment->amount,2,'.',',')}}
Total {{number_format($total,2,'.',',')}}
@endif
{{-- Filtering --}}