@extends('layouts.app') @section('content')
Contributions Differences Analysis
Filter Options
@if(count($differences) > 0) @endif
@if(count($differences) > 0)
@php $monthYears = collect($differences)->flatMap(fn($diff) => array_keys($diff['details']))->unique()->sort()->values()->toArray(); @endphp @foreach($monthYears as $my) @endforeach @foreach ($differences as $key => $difference) @foreach($monthYears as $my) @endforeach @endforeach
SN Name Monthly Salary Vote Code Department Change{{ \Carbon\Carbon::parse($my . '-01')->format('M Y') }}Action
{{ $key + 1 }} {{ $difference['firstName'] }} {{ $difference['middleName'] }} {{ $difference['lastName'] }} {{ number_format($difference['monthlySalary'], 2) }} {{ $difference['voteCode'] }} {{ $difference['deptName'] }} @if ($difference['change_comment'] === 'Increase') Increase @elseif ($difference['change_comment'] === 'Decrease') Decrease @endif {{ number_format($difference['details'][$my] ?? '', 2) }} View
@elseif(request()->filled('start_date') && request()->filled('end_date'))
No differences in deduction amounts found for Deduction Code 667 within the selected date range and department (if specified).
@endif
@endsection