@push('header') @endpush
{{-- Quick Links --}}
{{-- Summary Cards --}}
Total Movements
{{ number_format($movements->total()) }}
Total Inward
{{ number_format($totals['total_inward'] ?? 0) }}
Total Outward
{{ number_format($totals['total_outward'] ?? 0) }}
Total Value
{{ number_format($totals['total_value'] ?? 0, 2) }}

Moon Traders
Van Stock Ledger
@if($dateFrom && $dateTo) For the period {{ \Carbon\Carbon::parse($dateFrom)->format('d-M-Y') }} to {{ \Carbon\Carbon::parse($dateTo)->format('d-M-Y') }} @else All Movements @endif
Printed by: {{ auth()->user()->name }} | {{ now()->format('d-M-Y h:i A') }}

@forelse ($movements as $index => $movement) @empty @endforelse
Sr# Date Vehicle Product Type Qty Unit Cost Total Value Reference
{{ $movements->firstItem() + $index }} {{ \Carbon\Carbon::parse($movement->movement_date)->format('d-m-Y') }} @if($movement->vehicle) {{ $movement->vehicle->vehicle_number }} {{ $movement->vehicle->vehicle_number }} @else N/A @endif {{ $movement->product?->product_name ?? 'N/A' }} {{ ucwords(str_replace('_', ' ', $movement->movement_type)) }} {{ $movement->quantity > 0 ? '+' : '' }}{{ number_format($movement->quantity) }} {{ number_format($movement->unit_cost, 2) }} {{ number_format(abs($movement->quantity * $movement->unit_cost), 2) }} @if($movement->reference) @php $refClass = class_basename($movement->reference_type); @endphp {{ $refClass }}: {{ $movement->reference->reference_number ?? $movement->reference->id ?? '-' }} @else - @endif
No stock movements found. Try adjusting your filters.
Page Total ({{ $movements->count() }} movements) {{ number_format($movements->sum('quantity')) }} {{ number_format($movements->sum(fn($m) => abs($m->quantity * $m->unit_cost)), 2) }}
@if ($movements->hasPages())
{{ $movements->links() }}
@endif