@extends('layouts.app') @section('main-content')

My Inventory

Inventory List
@if ($errors->any())
    @foreach ($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif
@role('Super Admin|Product Manager|Admin') @endrole @role('Super Admin|Product Manager|Admin') @endrole @forelse($inventories as $inventory) @role('Super Admin|Product Manager|Admin') @endrole @role('Super Admin|Admin|Product Manager') @endrole @empty @endforelse
# Category Product Name Location Min Level On HandPrd Cost (RM)Unit Price (RM)Total Cost (RM)Restock
{{ $loop->iteration }} {{ $inventory->category }} {{ $inventory->product->name }} {{ !empty($inventory->location_id) ? $inventory->storages->name : '' }} {{ $inventory->threshold }} @if ($inventory->onhand > $inventory->threshold ) {{ $inventory->onhand }} @elseif ($inventory->onhand == $inventory->threshold) {{ $inventory->onhand }} @else {{ $inventory->onhand }} @endif {{ number_format($inventory->max_cost, 2) }} @if ($inventory->max_cost >= $inventory->unit_price ) {{ number_format($inventory->product->unit_price, 2) }} @else {{ number_format($inventory->unit_price, 2) }} @endif {{ number_format($inventory->max_cost * $inventory->onhand, 2,'.', ',') }}{{ date('Y-m-d', strtotime($inventory->last_purchase)) }}
Record not found
@endsection @section('script') @endsection