Vista Previa de Venta #{{ $venta->id }}

{{ __('Regresar') }} {{ __('Editar') }}

Cliente: {{ $venta->cliente->nombre }}

Camal Origen: {{ optional($venta->camal)->nombre ?? 'No especificado' }}

Fecha: {{ $venta->fecha }}

Estado: {{ ucfirst($venta->estado) }}

{{-- Totales Summary --}}
Totales
Total Jabas
{{ $this->totalJabas }}
Total Pesajes
{{ number_format($venta->total_pesajes, 2) }} kg
Tara Jabas
{{ number_format($venta->tara_jabas, 2) }} kg
Devoluciones
{{ number_format($venta->total_devoluciones, 2) }} kg
Adicionales
{{ number_format($venta->total_adicionales, 2) }} kg
Peso Neto
{{ number_format($this->pesoNeto, 2) }} kg
Total a Pagar: S/ {{ number_format($this->pesoNeto * $venta->precio, 2) }}
(Precio Unitario: S/ {{ number_format($venta->precio, 2) }})
{{-- Details Tables --}}
{{-- Pesajes --}}

Pesajes

@foreach($venta->pesajes as $pesaje) @endforeach
Peso Tara Cantidad Granja
{{ number_format($pesaje->peso, 2) }} @php $taraUnit = $pesaje->cantidad > 0 ? ($pesaje->tara / $pesaje->cantidad) : $pesaje->tara; @endphp {{ number_format($taraUnit, 2) }} {{ $pesaje->cantidad }} {{ $pesaje->granja }}
{{-- Devoluciones --}} @if($venta->devoluciones->count() > 0)

Devoluciones

@foreach($venta->devoluciones as $dev) @endforeach
Cantidad Peso Tipo Tara Peso Total (Calc)
{{ $dev->cantidad }} {{ number_format($dev->peso_devuelto, 2) }} @if($dev->tipo_pollo == 0) Vivo @elseif($dev->tipo_pollo == 200) Con tripa (200g) @elseif($dev->tipo_pollo == 300) Sin tripa (300g) @endif {{ number_format($dev->tara, 2) }} {{ number_format($dev->peso_total, 2) }}
@endif {{-- Adicionales --}} @if($venta->adicionales->count() > 0)

Adicionales

@foreach($venta->adicionales as $adi) @endforeach
Cantidad Peso Tipo Tara Peso Total (Calc)
{{ $adi->cantidad }} {{ number_format($adi->peso_adicional, 2) }} @if($adi->tipo_pollo == 0) Vivo @elseif($adi->tipo_pollo == 200) Con tripa (200g) @elseif($adi->tipo_pollo == 300) Sin tripa (300g) @endif {{ number_format($adi->tara_adicional, 2) }} {{ number_format($adi->peso_total, 2) }}
@endif