ADMIN MANAGEMENT
@php $adminAvatar = $adminAvatar ?? asset('images/bzmtch_logo.png'); $adminFullName = $adminFullName ?? $adminUsername ?? 'Admin'; @endphp
{{-- Flash / Errors --}} @if($errors->any())
    @foreach($errors->all() as $e)
  • {{ $e }}
  • @endforeach
@endif

Products

| >

Manage Products

@php $products = $products ?? collect(); @endphp
@if($products->isEmpty())
No products found. Click "Add" to create your first product.
@else
@php $unitsByName = ($units ?? collect())->keyBy(fn($u) => strtoupper(trim($u->name ?? ''))); @endphp @foreach($products as $product) @php $productUnitCode = optional($unitsByName[strtoupper(trim($product->unit ?? ''))] ?? null)->code; @endphp @endforeach
Image Product ID Barcode Product Name Unit Costing Retail Wholesale Promo Price Category Sub Category P-type Warranty Date Date registered
@if($product->image_path) {{ $product->product_name }} @else No image @endif {{ $product->id }} @php $barcode = $product->barcode; @endphp {{ $barcode !== null && $barcode !== '' ? (strlen($barcode) < 5 ? str_pad($barcode, 5, '0', STR_PAD_LEFT) : $barcode) : '-' }} {{ strtoupper($product->product_name ?? '') }} {{ $productUnitCode ? strtoupper($productUnitCode) : '-' }} ₱{{ number_format($product->costing ?? 0, 2) }} ₱{{ number_format($product->retail ?? 0, 2) }} ₱{{ number_format($product->wholesale ?? 0, 2) }} ₱{{ number_format($product->promo_price ?? 0, 2) }} ₱{{ number_format($product->retail ?? 0, 2) }} {{ $product->category ? strtoupper($product->category) : '-' }} {{ $product->sub_category ? strtoupper($product->sub_category) : '-' }} {{ $product->p_type ?? '-' }} {{ $product->p_type === 'WITH WARRANTY' && $product->warranty_date ? $product->warranty_date->format('M d, Y') : '-' }} {{ $product->created_at ? $product->created_at->format('M d, Y') : '-' }}
@endif
@include('admin.partials.inbox')