@extends('backEnd.layouts.master') @section('title', 'Inventory Ledger — ' . $product->name) @section('content')
| # | Type | Stock In | Stock Out | Reference | Note | Date |
|---|---|---|---|---|---|---|
| {{ ($ledger->currentPage() - 1) * $ledger->perPage() + $i + 1 }} | @php $typeConfig = [ 'purchase' => ['label' => 'Purchase', 'class' => 'bg-success', 'icon' => 'fa-arrow-down'], 'sale' => ['label' => 'Sale', 'class' => 'bg-primary', 'icon' => 'fa-shopping-cart'], 'return' => ['label' => 'Return', 'class' => 'bg-info', 'icon' => 'fa-undo'], 'reserve' => ['label' => 'Reserved', 'class' => 'bg-secondary','icon' => 'fa-lock'], 'release' => ['label' => 'Released', 'class' => 'bg-secondary','icon' => 'fa-unlock'], 'adjustment' => ['label' => 'Adjustment', 'class' => 'bg-warning text-dark', 'icon' => 'fa-edit'], 'damage' => ['label' => 'Damage', 'class' => 'bg-danger', 'icon' => 'fa-exclamation-triangle'], ]; $cfg = $typeConfig[$entry->type] ?? ['label' => ucfirst($entry->type), 'class' => 'bg-secondary', 'icon' => 'fa-circle']; @endphp {{ $cfg['label'] }} | @if($entry->qty_in > 0) +{{ $entry->qty_in }} @else — @endif | @if($entry->qty_out > 0) -{{ $entry->qty_out }} @else — @endif | @if($entry->reference_type && $entry->reference_id) {{ $entry->reference_type }} #{{ $entry->reference_id }} @else — @endif | {{ $entry->note ?? '—' }} |
{{ $entry->created_at->format('d M Y') }}
{{ $entry->created_at->format('h:i A') }}
|
| No inventory movements recorded yet. | ||||||