| DSSR Report |
| From :
{{ $fromDate }} To : {{ $toDate }} |
@foreach ($users as $key => $user)
@php
$totalCustomerCount = 0;
$totalOrderedOrVisted = 0;
$totalOrderedCount = 0;
$totalOrderAmount = 0;
$totalBilledAmount = 0;
$totalCollectionAmount = 0;
@endphp
| {{ $key + 1 }} |
{{ $user->name }} |
{{ $user->start_time }} |
{{ $user->end_time }} |
{{ $user->duration }} |
@if (empty($user->routes))
-- |
-- |
-- |
-- |
-- |
-- |
-- |
@else
@php
$totalCustomerCount += $user->routes[0]['count'];
$totalOrderedOrVisted += $user->routes[0]['ordered_or_visted'];
$totalOrderedCount += $user->routes[0]['ordered_count'];
$totalOrderAmount += $user->routes[0]['order_amount'];
$totalBilledAmount += $user->routes[0]['billed_amount'];
$totalCollectionAmount += $user->routes[0]['collection_amount'];
@endphp
{{ $user->routes[0]['route_name'] }} |
{{ $user->routes[0]['count'] }} |
{{ $user->routes[0]['ordered_or_visted'] }} |
{{ $user->routes[0]['ordered_count'] }} |
{{ $user->routes[0]['order_amount'] }} |
{{ $user->routes[0]['billed_amount'] }} |
{{ $user->routes[0]['collection_amount'] }} |
@endif
@foreach ($user->routes as $key => $route)
@if ($key == 0)
@continue
@endif
@php
$totalCustomerCount += $route['count'];
$totalOrderedOrVisted += $route['ordered_or_visted'];
$totalOrderedCount += $route['ordered_count'];
$totalOrderAmount += $route['order_amount'];
$totalBilledAmount += $route['billed_amount'];
$totalCollectionAmount += $route['collection_amount'];
@endphp
|
|
|
|
|
{{ $route['route_name'] }} |
{{ $route['count'] }} |
{{ $route['ordered_or_visted'] }} |
{{ $route['ordered_count'] }} |
{{ $route['order_amount'] }} |
{{ $route['billed_amount'] }} |
{{ $route['collection_amount'] }} |
@endforeach
|
{{ $totalCustomerCount }} |
{{ $totalOrderedOrVisted }} |
{{ $totalOrderedCount }} |
{{ $totalOrderAmount }} |
{{ $totalBilledAmount }} |
{{ $totalCollectionAmount }} |
@endforeach