Add budget transformer and enrichment.

This commit is contained in:
James Cole
2025-08-03 20:17:50 +02:00
parent e55fc483bd
commit 6a49918707
12 changed files with 249 additions and 70 deletions

View File

@@ -95,6 +95,7 @@ class EditController extends Controller
$preFilled = [
'active' => $hasOldInput ? (bool) $request->old('active') : $budget->active,
'auto_budget_currency_id' => $hasOldInput ? (int) $request->old('auto_budget_currency_id') : $this->primaryCurrency->id,
'notes' => $this->repository->getNoteText($budget),
];
if ($autoBudget instanceof AutoBudget) {
$amount = $hasOldInput ? $request->old('auto_budget_amount') : $autoBudget->amount;