Fixes i18n errors now that they are detected by i18n-tasks
This commit is contained in:
@@ -66,14 +66,14 @@ class Valuation::BudgetInvestmentsController < Valuation::BaseController
|
||||
|
||||
def valid_price_params?
|
||||
if /\D/.match params[:budget_investment][:price]
|
||||
@investment.errors.add(:price, I18n.t('budget.investments.wrong_price_format'))
|
||||
@investment.errors.add(:price, I18n.t('budgets.investments.wrong_price_format'))
|
||||
end
|
||||
|
||||
if /\D/.match params[:budget_investment][:price_first_year]
|
||||
@investment.errors.add(:price_first_year, I18n.t('budget.investments.wrong_price_format'))
|
||||
@investment.errors.add(:price_first_year, I18n.t('budgets.investments.wrong_price_format'))
|
||||
end
|
||||
|
||||
@investment.errors.empty?
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user