{{-- REPORT HEADER --}}
@include('templates.pdf_header', [ 'organisation' => $organisation, 'asOfDate' => $asOfDate, 'title' => 'STOCK REPORT / STOCK TAKING REPORT AS AT ' . \Carbon\Carbon::parse($asOfDate)->format('d/m/Y') ])
{{-- STOCK TABLE --}} @php $totalQty = 0; $totalValue = 0; @endphp @foreach($data as $index => $row) @php $qty = $row['current_stock']; $price = $row['unit_price']; $value = $qty * $price; $totalQty += $qty; $totalValue += $value; @endphp @endforeach {{-- TOTAL ROW --}}
S/N Items Name Warehouse UOM Stock Qty Stock Price Value
{{ $index + 1 }} {{ $row['item_name'] }} {{ $row['warehouse'] }} {{ $row['uom'] }} {{ number_format($qty) }} {{ number_format($price, 2) }} {{ number_format($value, 2) }}
TOTAL {{ number_format($totalQty) }} {{ number_format($totalValue, 2) }}
{{-- FOOTER --}}