GPF Loan List for {{$month}}

@php $totalLoanAmount = 0; $uniqueEmpCodes = []; @endphp @foreach($data as $list) @php $totalLoanAmount += $list->loan_amount; $uniqueEmpCodes[$list->emp_code] = true; @endphp @endforeach
Sl Name & Employee Code Designation Department GPF Loan Date Document No Loan Amount
{{ $loop->iteration }} {{ $list->name_code }} {{ $list->designation }} {{ $list->current_department_name }} {{ date('d-M-Y', strtotime($list->vouchar_date)) }} {{ $list->vouchar_no }} {{ number_format($list->loan_amount, 2) }}
Total {{ number_format($totalLoanAmount, 2) }}
{{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- @php--}} {{-- $currentDepartment = null;--}} {{-- $rowCount = 0;--}} {{-- @endphp--}} {{-- @foreach($data as $list)--}} {{-- @if($currentDepartment != $list->current_department_name)--}} {{-- @php--}} {{-- $currentDepartment = $list->current_department_name;--}} {{-- $rowCount = 2;--}} {{-- @endphp--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- @else--}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- --}} {{-- @endif--}} {{-- @endforeach--}} {{-- --}} {{--
SlSettlement DateDepartmentEmp CodeDocument NoSettlement Amount
{{ $loop->iteration }}{{ $list->vouchar_date }}{{ $currentDepartment }}{{ $list->emp_code }}{{ $list->vouchar_no }}{{ $list->loan_amount }}
{{ $loop->iteration }}{{ $list->vouchar_date }}{{ $list->emp_code }}{{ $list->vouchar_no }}{{ $list->loan_amount }}
--}}