mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-07 22:45:20 +02:00
fix: allow comma-separated currency input for budgeted_spending
This commit is contained in:
parent
b7c56e2fb7
commit
6cb58fbf05
1 changed files with 1 additions and 1 deletions
|
@ -37,7 +37,7 @@ class BudgetCategoriesController < ApplicationController
|
||||||
private
|
private
|
||||||
def budget_category_params
|
def budget_category_params
|
||||||
params.require(:budget_category).permit(:budgeted_spending).tap do |params|
|
params.require(:budget_category).permit(:budgeted_spending).tap do |params|
|
||||||
params[:budgeted_spending] = params[:budgeted_spending].presence || 0
|
params[:budgeted_spending] = params[:budgeted_spending].to_s.delete(',').presence || 0
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue