@foreach($categories as $cat) @endforeach
Medicine Info Category Stock Quantity Selling Price Expiry Status Actions @forelse($medicines as $med)
{{ $med->name }}
{{ $med->code ?: 'NO CODE' }} {{ $med->generic_name ?: 'GENERIC NOT SET' }}
{{ $med->category }} {{ $med->strength }}
@php $isLow = $med->stock_quantity <= $med->min_stock_level; @endphp {{ $med->stock_quantity }} @if($isLow) @endif
₹{{ number_format($med->selling_price, 2) }} @php $isExpired = $med->expire_date && $med->expire_date->isPast(); $isNearExpiry = $med->expire_date && !$isExpired && $med->expire_date->diffInMonths(now()) < 3; @endphp {{ $med->expire_date ? $med->expire_date->format('d M, Y') : '—' }}
@empty @endforelse
@if($medicines->hasPages())
{{ $medicines->links() }}
@endif