Reporte de cierre #{{$relation->id}}

Domiciliario:

@if($relation->domiciliario and $relation->domiciliario->name) {{ $relation->domiciliario->name }} @else - @endif

Fecha:

{{ $relation->created_at->format('d/m/Y') }}

Documento de identidad:

@if($relation->domiciliario and $relation->domiciliario->dni) {{ $relation->domiciliario->dni }} @else - @endif

@php $totalRecaudo = 0; @endphp @foreach ($allItems as $key => $order) @php $totalRecaudo += (float)$order->total; @endphp @endforeach

# Domicilio

Estatus

Productos

Recaudos

Total

{{ $order->reference }}

{{ $order->status }}

@if(isset($order->content) && is_array(json_decode($order->content))) @php $products = json_decode($order->content); @endphp @if(count($products) > 0)

    @foreach($products as $product)
  • {{ $product->name ?? '' }} ({{ $product->quantity ?? '' }})
  • @endforeach
@endif @else {{$order->content}} @endif

    @foreach($order->Collections as $recaudo)
  • {{ $recaudo->payment ?? '' }} ({{ $recaudo->value ?? '' }})
  • @endforeach

{{!is_null($configuration) ? $configuration->getCurrencySimbolAttribute() : '$'}}{{ number_format($order->total) }}

Resumen de Pagos
    @foreach ($paymentsSummary as $payment)
  • {{ $payment['payment_method'] }}: {{!is_null($configuration) ? $configuration->getCurrencySimbolAttribute() : '$'}}{{ number_format($payment['total'], 2) }}
  • @endforeach
Métricas de Productos y Pedidos
  • Productos entregados: {{ $productsDelivered }}
  • Pedidos entregados: {{ $itemsDelivered->count() ?? 0 }}
  • Productos no entregados: {{ $productsNotDelivered }}
  • Pedidos no entregados: {{ $itemsNotDelivered->count() ?? 0 }}