@php $value = fn ($key) => old("lines.$i.$key", $line[$key] ?? null); $amountField = $side === 'credit' ? 'credit' : 'debit'; @endphp