{{-- div for Company --}} @php $company = DB::table('gnr_company')->where('id', Auth::user()->company_id_fk)->select('name','address')->first(); @endphp {{$company->name}}
{{$company->address}}
Member Wise Pass Book Balancing Register Report
{{--

Ambala Foundation

House # 67, Block # Ka, Piciculture Housing Society, Shyamoli, Dhaka- 1207

--}} {{--

Member Ledger Report

--}}
Branch Name & Code : {{-- @if ($BranchId == 'All') {{$BranchId}} @elseif ($BranchId != 'All') --}} @foreach ($BranchInfos as $key => $BranchInfo) {{$BranchInfo->name}}({{$BranchInfo->branchCode}}) @endforeach {{-- @endif --}}
Area Name : {{$AreaInfos}}
Creadit Officer : @if ($RequestedSamity != 'All') @if ($CreditOfficerInfos != null) {{$CreditOfficerInfos->emp_name_english}} @endif @elseif ($RequestedSamity == 'All') @foreach ($CreditOfficerInfos as $key => $CreditOfficerInfo) {{$CreditOfficerInfo->emp_name_english}}
@endforeach @endif
Samity Name & Code : @if ($RequestedSamity == 'All') All @elseif ($RequestedSamity != 'All') @foreach ($SamityInfos as $key => $SamityInfo) {{$SamityInfo->name}}({{$SamityInfo->code}}) @endforeach @endif
Quarter
: {{-- @if ($SelectionType == 'N') {{$DateFrom}} - {{$DateTo}} @elseif ($SelectionType == 'Y') {{$DateTo}} @endif --}} {{$Querter}}
Quarter Date
: @if ($RequestedQuerter == '1-3') January-01 to March-31 @elseif ($RequestedQuerter == '4-6') April-01 to June-30 @elseif ($RequestedQuerter == '7-9') July-01 to September-30 @elseif ($RequestedQuerter == '10-12') October-01 to December-31 @endif {{-- {{$RequestedQuerter}} --}}
Print Date
: 2026-07-21

{{--
--}} @foreach ($SavingsProduct as $key => $SavingsProduct1) @endforeach @foreach ($SavingsProduct as $key => $SavingsProduct1) @endforeach @php $SerialNumber = 0; $RowCounter = 0; $SavingsCounter = 0; $LoanAmountTotal = 0; $RepaymentWeekTotal = 0; $OutstandingTotal = 0; $DueTotal = 0; $ManualSavingsTracker = 0; $ManualSavingsRowPrinter = 0; $SavingsTotal = array(); // echo sizeof($SavingsProduct); foreach ($SavingsProduct as $key => $SavingsProduct1) { $MemberSavingsArray[$SavingsProduct1->id] = 0; } foreach ($SavingsProduct as $key => $SavingsProduct1) { $MemberSavingsArrayPassBook[$SavingsProduct1->id] = 0; } $ManualOutstandingTotal = 0; $ManualDueTotal = 0; @endphp @foreach ($MemberInfos as $key1 => $MemberInfo) @if (sizeof($LoanInfos) > 0) @foreach ($LoanInfos as $key2 => $LoanInfo) @php list($mId, $pId) = explode('/', $key2); @endphp @if ($MemberInfo->id == $mId and $MemberInfo->primaryProductId == $pId) @if (sizeof($LoanInfo) > 0) @foreach ($LoanInfo as $key2A => $LoanInfo1) @php $LoanAmountTotal = $LoanAmountTotal + $LoanInfo1->loanAmount; $RepaymentWeekTotal = $RepaymentWeekTotal + $LoanInfo1->numberOfInstallment; @endphp @foreach ($OutstandingsInfos as $key4 => $OutstandingsInfo) @php list($mId4, $pId4) = explode('/', $key4); @endphp @if ($mId4 == $MemberInfo->id and $mId4 == $mId and $pId4 == $MemberInfo->primaryProductId and $pId4 == $pId) {{-- --}} @php $OutstandingTotal = $OutstandingTotal + $OutstandingsInfo; @endphp @endif @endforeach @foreach ($DueInfos as $key5 => $DueInfo) @php list($mId5, $pId5) = explode('/', $key5); @endphp @if ($mId5 == $MemberInfo->id and $mId5 == $mId and $pId5 == $MemberInfo->primaryProductId and $pId5 == $pId) @php $DueTotal = $DueTotal + $DueInfo; @endphp @endif @endforeach @php $RowCounter = 1; @endphp @endforeach @endif @endif @endforeach @endif @foreach ($SavingsInfos as $key6 => $SavingsInfo) @php list($mId6, $pId6) = explode('/', $key6); @endphp @if ($mId6 == $MemberInfo->id and $pId6 == $MemberInfo->primaryProductId and $RowCounter == 0) @foreach ($SavingsInfo as $key6A => $SavingsInfo1) @foreach ($SavingsProduct as $key => $SavingsProduct1) @if ($SavingsProduct1->id == $key6A) @php $MemberSavingsArray[$SavingsProduct1->id] = $MemberSavingsArray[$SavingsProduct1->id] + $SavingsInfo1; @endphp @endif @endforeach @endforeach @elseif ($mId6 == $MemberInfo->id and $pId6 == $MemberInfo->primaryProductId and $RowCounter == 1) @foreach ($SavingsInfo as $key6A => $SavingsInfo1) @foreach ($SavingsProduct as $key => $SavingsProduct1) @if ($SavingsProduct1->id == $key6A) @php $MemberSavingsArray[$SavingsProduct1->id] = $MemberSavingsArray[$SavingsProduct1->id] + $SavingsInfo1; @endphp @endif @endforeach @php ++$SavingsCounter; // $SavingsTotal[$SavingsCounter] = $SavingsTotal[$SavingsCounter] + $SavingsInfo1; @endphp @endforeach @endif @if ($mId6 == $MemberInfo->id and $pId6 == $MemberInfo->primaryProductId) @php $Savings = DB::table('manual_pass_book_balance') ->select('outstanding', 'due', 'savingsBalance', 'memberIdFk') ->where([['memberIdFk', $MemberInfo->id], ['productIdFk', $MemberInfo->primaryProductId], ['date', $startDate]]) ->get(); // dd($Savings); // echo sizeof($Savings); @endphp @if (sizeof($Savings) > 0) @foreach ($Savings as $key => $Saving) @if ($ManualSavingsTracker == 0) @php $ManualSavingsTracker = $ManualSavingsTracker + 1; $ManualOutstandingTotal = $ManualOutstandingTotal + $Saving->outstanding; $ManualDueTotal = $ManualDueTotal + $Saving->due; @endphp @endif {{-- --}} @endforeach @php $ManualSavingsRowPrinter = sizeof($SavingsProduct) - sizeof($Savings); @endphp @for ($i=0; $i < $ManualSavingsRowPrinter; $i++) @endfor @else @foreach ($SavingsProduct as $key => $SavingsProduct1) @endforeach @endif @endif @endforeach @php $RowCounter = 0; $ManualSavingsTracker = 0; // dd($Savings); @endphp @endforeach {{-- --}} @foreach ($MemberSavingsArray as $key => $MemberSavingsArray1) @endforeach {{-- --}} @foreach ($MemberManualPassBookSavingsTotal as $key => $MemberManualPassBookSavingsTotal1) @endforeach @php // dd($SavingsTotal); @endphp
SL. No.
Member ID
Member Name
Spouse Name
Loan Desburesment Information
Repayment Week
Collection Sheet Balance
Pass Book Balance
Loan ID
Desburesment Date
Loan Amount
Loan
Savings
Loan
Savings
Outstanding
Due
{{$SavingsProduct1->name}}
Outstanding
Due
{{$SavingsProduct1->name}}
{{++$SerialNumber}} {{$MemberInfo->code}} {{$MemberInfo->name}} {{$MemberInfo->spouseFatherSonName}}{{$LoanInfo1->loanCode}} {{$LoanInfo1->disbursementDate}} {{number_format($LoanInfo1->loanAmount,2)}} {{$LoanInfo1->numberOfInstallment}} {{number_format($OutstandingsInfo,2)}}{{number_format($DueInfo,2)}}- - - - - -{{number_format($SavingsInfo1,2)}}{{number_format($SavingsInfo1,2)}}{{number_format($Saving->outstanding,2)}} {{number_format($Saving->due,2)}}{{number_format($Saving->savingsBalance,2)}}{{$Saving->savingsBalance}}0.000.00 0.000.00
Total {{number_format($LoanAmountTotal,2)}} {{number_format($RepaymentWeekTotal,2)}} {{number_format($OutstandingTotal,2)}} {{number_format($DueTotal,2)}} {{number_format($MemberSavingsArray1,2)}} {{number_format($ManualOutstandingTotal,2)}} {{number_format($ManualDueTotal,2)}} {{number_format($MemberManualPassBookSavingsTotal1,2)}}

{{--
--}} @foreach ($SavingsProduct as $key => $SavingsProduct1) @endforeach @foreach ($SavingsProduct as $key => $SavingsProduct1) @endforeach @php $SavingsArray = array(); $CategoryWiseTotal1 = 0; $CategoryWiseTotal2 = 0; $CategoryWiseTotal3 = 0; $CategoryWiseTotal4 = 0; foreach ($SavingsProduct as $key => $SavingsProduct1) { $SavingsArray[$SavingsProduct1->id] = 0; } foreach ($SavingsProduct as $key => $SavingsProduct1) { $SavingsArrayPassBook[$SavingsProduct1->id] = 0; } $CategoryWiseTotal5 = 0; $CategoryWiseTotal6 = 0; $CategoryWiseTotal7 = 0; $CategoryWiseTotal8 = 0; $CategoryWiseTotal9 = 0; @endphp @foreach ($CategoryName as $key1A => $Category) @foreach ($Category as $key => $Category1) @foreach ($CategoryWiseDisbursementAmount as $key2 => $DisbursementAmount) @if ($key2 == $Category1->id) @php $CategoryWiseTotal1 = $CategoryWiseTotal1 + $DisbursementAmount; @endphp @endif @endforeach @foreach ($CategoryWiseOutstanding as $key3 => $Outstanding) @if ($key3 == $Category1->id) @php $CategoryWiseTotal2 = $CategoryWiseTotal2 + $Outstanding; @endphp @endif @endforeach @foreach ($CategoryWiseDue as $key4 => $Due) @if ($key4 == $Category1->id) @php $CategoryWiseTotal3 = $CategoryWiseTotal3 + $Due; @endphp @endif @endforeach @foreach ($CategoryWiseSavings as $key5 => $CategoryWiseSaving) @foreach ($CategoryWiseSaving as $key5A => $CategoryWiseSaving1) @if ($key5 == $Category1->id) @foreach ($SavingsProduct as $key => $SavingsProduct1) @if ($SavingsProduct1->id == $key5A) @php $SavingsArray[$SavingsProduct1->id] = $SavingsArray[$SavingsProduct1->id] + $CategoryWiseSaving1; @endphp @endif @endforeach @endif @endforeach @endforeach @foreach ($CategoryWiseManualOutstandings as $key6 => $CategoryWiseManualOutstanding) @if ($key6 == $Category1->id) @php $CategoryWiseTotal8 = $CategoryWiseTotal8 + $CategoryWiseManualOutstanding; @endphp @endif @endforeach @foreach ($CategoryWiseManualDue as $key7 => $CategoryWiseManualDue1) @if ($key7 == $Category1->id) @php $CategoryWiseTotal9 = $CategoryWiseTotal9 + $CategoryWiseManualDue1; @endphp @endif @endforeach @foreach ($CategoryWiseManualSavings as $key8 => $CategoryWiseManualSaving) @foreach ($CategoryWiseManualSaving as $key8A => $CategoryWiseManualSaving1) @if ($key8 == $Category1->id) @foreach ($SavingsProduct as $key => $SavingsProduct1) @if ($SavingsProduct1->id == $key8A) @php $SavingsArrayPassBook[$SavingsProduct1->id] = $SavingsArrayPassBook[$SavingsProduct1->id] + $CategoryWiseManualSaving1; @endphp @endif @endforeach @endif @endforeach @endforeach @endforeach @endforeach @foreach ($SavingsArray as $key => $SavingsArray1) @endforeach @foreach ($SavingsArrayPassBook as $key => $SavingsArrayPassBook1) @endforeach @php // dd($Savings); @endphp
Product Catagory Name
Loan Desburesment
Collection Sheet Balance
Pass Book Balance
Loan
Savings
Loan
Savings
Outstanding
Due
{{$SavingsProduct1->name}}
Outstanding
Due
{{$SavingsProduct1->name}}
{{$Category1->name}}{{number_format($DisbursementAmount,2)}}{{number_format($Outstanding,2)}}{{number_format($Due,2)}}{{number_format($CategoryWiseSaving1,2)}}{{number_format($CategoryWiseManualOutstanding,2)}}{{number_format($CategoryWiseManualDue1,2)}}{{number_format($CategoryWiseManualSaving1,2)}}
Total {{number_format($CategoryWiseTotal1,2)}} {{number_format($CategoryWiseTotal2,2)}} {{number_format($CategoryWiseTotal3,2)}} {{number_format($SavingsArray1,2)}} {{number_format($CategoryWiseTotal8,2)}} {{number_format($CategoryWiseTotal9,2)}} {{number_format($SavingsArrayPassBook1,2)}}
{{-- --}}
Credit Officer Signature :
Credit Officer Name :
Designation :
{{-- --}}
Accounts & MIS Officer Signature :
Accounts & MIS Officer Name :
Designation :
{{-- --}}
Branch Manager Signature :
Branch Manager Name :
Designation :