@php $meta = [ 'Supplier' => $goodsReceivedNote->supplier?->name, 'Purchase Order' => $goodsReceivedNote->purchaseOrder?->order_number ?? '-', 'Received By' => $goodsReceivedNote->receivedBy?->name, 'Received At' => $goodsReceivedNote->received_at?->format('d M Y H:i'), 'Lines' => $goodsReceivedNote->items->count(), 'Reference Status' => $goodsReceivedNote->purchaseOrder?->status ? ucfirst($goodsReceivedNote->purchaseOrder->status) : '-', ]; $notes = $goodsReceivedNote->notes; $totalAmount = $goodsReceivedNote->items->sum(fn ($item) => (float) $item->quantity * (float) $item->unit_cost); @endphp @extends('reports.layout') @section('content')
Received Items
@foreach ($goodsReceivedNote->items as $item) @endforeach
Product Category Quantity Unit Cost Line Total
{{ $item->product?->name }} {{ $item->product?->category?->name ?? '-' }} {{ number_format((float) $item->quantity, 2) }} {{ number_format((float) $item->unit_cost, 2) }} {{ number_format((float) $item->quantity * (float) $item->unit_cost, 2) }}
Total Received Value {{ number_format($totalAmount, 2) }}
@endsection