@php $org = auth()->user()->organization ?? \App\Models\System\Organization::find(auth()->user()->organization_id); $documentTitle = 'Stock Position Report'; $isPdf = false; @endphp @extends('documents.inventory._layout', [ 'documentTitle' => 'Stock Position Report', 'reference' => null, 'documentDate' => $reportDate, ]) @section('header-meta')
|
Total Lines {{ $levels->count() }} |
On Hand {{ number_format($totalOnHand) }} |
Reserved {{ number_format($totalReserved) }} |
Available {{ number_format($totalAvailable) }} |
@if($belowMinCount > 0)
⚠ Below Minimum {{ $belowMinCount }} |
@endif
@if($mismatchCount > 0)
⚠ Serial Mismatch {{ $mismatchCount }} |
@endif
| # | Product | SKU | Lot | On Hand | Reserved | Available | Serial Records | Last Updated |
|---|---|---|---|---|---|---|---|---|
| {{ $i + 1 }} | {{ $level->product?->name ?? '—' }} | {{ $level->product?->sku ?? '—' }} | {{ $level->lot?->lot_number ?? '—' }} | {{ number_format($level->quantity_on_hand ?? 0) }} | {{ number_format($level->quantity_reserved ?? 0) }} | {{ number_format($avail) }} | {{ $level->active_serial_count ?? 0 }} | {{ $level->last_updated ? \Carbon\Carbon::parse($level->last_updated)->format('d M Y') : '—' }} |
| {{ $locationName }} Totals | {{ number_format($locationLevels->sum('quantity_on_hand')) }} | {{ number_format($locationLevels->sum('quantity_reserved')) }} | {{ number_format($locationLevels->sum(fn($l) => ($l->quantity_on_hand ?? 0) - ($l->quantity_reserved ?? 0))) }} | |||||