Month Wise Camp wise Refreshment and IEC Due Statement against Blood Bank
@php $first = false; @endphp
@php
$bbRef = 0;
$bbIEC = 0;
$bbTotal = 0;
$bbDonor = 0;
$bbCampCount = 0;
@endphp
| Sl |
Camp Date |
Organisation Name |
BB |
NOD |
Ref Amt |
IEC Amt |
Tot Ref & IEC Amt |
Ref Status |
IEC Status |
@foreach ($bbData['MonthWisedata'] as $month => $records)
@php
// ✅ RESET SL PER MONTH
$sl = 1;
$monthRef = 0;
$monthIEC = 0;
$monthTotal = 0;
$monthDonor = 0;
$campCount = count($records);
$bbCampCount += $campCount;
@endphp
|
Blood Bank Name: {{ $bbData['BloodbankName'] ?? '' }}
|
@foreach ($records as $value)
@php
$monthRef += $value->refreshment_charge ?? 0;
$monthIEC += $value->iec_grant_paid ?? 0;
$monthTotal += $value->total_amount ?? 0;
$monthDonor += $value->donor_count ?? 0;
$bbRef += $value->refreshment_charge ?? 0;
$bbIEC += $value->iec_grant_paid ?? 0;
$bbTotal += $value->total_amount ?? 0;
$bbDonor += $value->donor_count ?? 0;
@endphp
| {{ $sl++ }} |
{{ $value->camp_date ? date('d-m-Y', strtotime($value->camp_date)) : '' }}
|
{{ $value->org_name }} |
{{ $value->blood_bank_code ?? '' }} |
{{ $value->donor_count ?? 0 }} |
{{ number_format($value->refreshment_charge ?? 0, 2) }} |
{{ number_format($value->iec_grant_paid ?? 0, 2) }} |
{{ number_format($value->total_amount ?? 0, 2) }} |
{{ strtoupper($value->ref_status ?? '') }} |
{{ strtoupper($value->iec_status ?? '') }} |
@endforeach
| Total in {{ $month }} |
{{ $monthDonor }} |
{{ number_format($monthRef, 2) }} |
{{ number_format($monthIEC, 2) }} |
{{ number_format($monthTotal, 2) }} |
Camp No: {{ $campCount }}
|
@endforeach
|
|
Total Due During the Period against BB {{ $bbCode }}
|
{{ $bbDonor }} |
{{ number_format($bbRef, 2) }} |
{{ number_format($bbIEC, 2) }} |
{{ number_format($bbTotal, 2) }} |
Camp No: {{ $bbCampCount }}
|
@endforeach
@else