@extends('layouts.app') @section('title', 'Inventory Report') @section('actions') Download Inventory PDF @endsection @section('content')
Total Ingredients

{{ $summary->total }}

Low Stock (< 100 g)

{{ $summary->low }}

Out of Stock

{{ $summary->out }}

Total Inventory Value

{{ number_format($summary->value, 2) }}

@forelse($ingredients as $i) @empty @endforelse
CategoryIngredientPurchasedUsedAvailableUnitTotal Purchase PriceAvg Unit PriceStatus
{{ $i->category->name ?? '—' }} {{ $i->name }} {{ \App\Models\Ingredient::formatGrams($i->purchased_grams) }} {{ \App\Models\Ingredient::formatGrams($i->used_grams) }} {{ \App\Models\Ingredient::formatGrams($i->available_quantity_grams) }} {{ $i->unit }} {{ number_format($i->purchased_value, 2) }} {{ number_format($i->avg_unit_price * ($i->unit === 'kg' ? 1000 : 1), 2) }} / {{ $i->unit }} @if($i->isOutOfStock())Out @elseif($i->isLowStock())Low @elseOK@endif
No ingredients.
Supplier-wise Stock
@forelse($supplierTotals as $s) @empty @endforelse
SupplierTotal QuantityTotal Value
{{ $s->supplier_name }}{{ \App\Models\Ingredient::formatGrams($s->grams) }}{{ number_format($s->value, 2) }}
No supplier entries.
@endsection