@extends('admin.layouts.app') @section('title', 'Products') @section('page_title', 'Product Management') @section('content')
Products List
Add Product
@forelse($products as $product) @empty @endforelse
ID Name Code Reference No Category Unit Purchase Price Sale Price Current Stock Status Actions
{{ $product->id }} {{ $product->name }} {{ $product->code }} {{ $product->reference_no ?? '-' }} {{ $product->category->name ?? 'N/A' }} {{ $product->unit->short_name ?? 'N/A' }} {{ number_format($product->purchase_price, 2) }} {{ number_format($product->sale_price, 2) }} @php $stock = $product->calculated_stock ?? $product->current_stock; @endphp @if($stock <= $product->alert_quantity) {{ number_format($stock, 3) }} @else {{ number_format($stock, 3) }} @endif @if($product->status == 1) Active @else Inactive @endif
@csrf @method('DELETE')
No products found
{{ $products->links() }}
@endsection