@extends('layouts.app') @section('title', 'Edit Purchase - ' . setting('system_name')) @section('content')

Edit Purchase

@if ($errors->any()) @endif
@csrf @method('PUT')
@error('supplier_id')
{{ $message }}
@enderror
@error('reference_no')
{{ $message }}
@enderror
@error('purchase_date')
{{ $message }}
@enderror
@error('status')
{{ $message }}
@enderror
@error('payment_status')
{{ $message }}
@enderror
Purchase Items

To modify items, please delete and recreate the purchase.

@foreach ($purchase->purchaseItems as $item) @endforeach
Product Quantity Unit Cost Discount % Tax % Line Total
{{ $item->product?->name ?? '-' }} ({{ $item->product?->sku ?? '-' }}) {{ $item->quantity }} MWK {{ number_format($item->unit_cost, 2) }} {{ $item->discount_percent ?? 0 }}% {{ $item->tax_percent ?? 0 }}% MWK {{ number_format($item->line_total, 2) }}
Grand Total: MWK {{ number_format($purchase->grand_total, 2) }}
@endsection