@extends('layouts.pdf-layout') @section('letter_title')
ROUTE | @foreach($allAgents as $agentId => $agentName){{ strtoupper($agentName) }} | @endforeachTOTAL |
---|---|---|
{{ $route }} | @foreach($allAgents as $agentId => $agentName)@if(isset($data['agents'][$agentId])) {{ number_format($data['agents'][$agentId]['total_rate'], 2) }} @php $columnTotals[$agentId] += $data['agents'][$agentId]['total_rate']; @endphp @else - @endif | @endforeach{{ number_format($data['total_rate'], 2) }} | @php $grandTotal += $data['total_rate']; @endphp
TOTAL | @foreach($allAgents as $agentId => $agentName){{ number_format($columnTotals[$agentId], 2) }} | @endforeach{{ number_format($grandTotal, 2) }} |