mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-08 23:15:24 +02:00
Fix budget allocation forms from resetting and clearing data on slow networks (#1804)
* First pass * Fix null constraint bug for budget category assignment * Fix autofocus reset when allocating budget * Lint fix
This commit is contained in:
parent
f498212b2d
commit
5b083c9e33
7 changed files with 56 additions and 53 deletions
|
@ -21,14 +21,10 @@
|
|||
</div>
|
||||
<% else %>
|
||||
<div class="max-w-md mx-auto">
|
||||
<% if @budget.available_to_allocate.negative? %>
|
||||
<%= render "budget_categories/allocation_progress_overage", budget: @budget %>
|
||||
<% else %>
|
||||
<%= render "budget_categories/allocation_progress", budget: @budget %>
|
||||
<% end %>
|
||||
<%= render "budget_categories/allocation_progress", budget: @budget %>
|
||||
|
||||
<div class="space-y-4 mb-4">
|
||||
<% BudgetCategory::Group.for(@budget.budget_categories).sort_by(&:name).each do |group| %>
|
||||
<% BudgetCategory::Group.for(@budget_categories).sort_by(&:name).each do |group| %>
|
||||
<div class="space-y-4">
|
||||
<%= render "budget_categories/budget_category_form", budget_category: group.budget_category %>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue