@extends('layouts.app') @section('title', 'Bill of Materials') @section('content') @php $currentProduct = null; @endphp @forelse($bomEntries as $entry) @if($currentProduct !== ($entry->product->item_name ?? '')) @if($currentProduct !== null) @endif @php $currentProduct = $entry->product->item_name ?? ''; @endphp

{{ $currentProduct }}

{{ $entry->product->item_code ?? '' }}
@endif @empty
No BOM entries found. Add the first one.
@endforelse @if($currentProduct !== null && $bomEntries->count())
Raw Material Qty Required UOM Actions
{{ $entry->rawMaterial->item_name ?? '' }} {{ number_format($entry->quantity_required, 2) }} {{ $entry->unit_of_measure }}
Edit
@csrf @method('DELETE')
@endif @endsection