From faf4e1f07c07c50163aa8ed609984a700adac321 Mon Sep 17 00:00:00 2001 From: natdeanlewissoftwire Date: Fri, 28 Apr 2023 11:38:40 +0100 Subject: [PATCH] feat: rename --- app/models/validations/financial_validations.rb | 4 ++-- config/locales/en.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/models/validations/financial_validations.rb b/app/models/validations/financial_validations.rb index e6faf0804..7ec730b97 100644 --- a/app/models/validations/financial_validations.rb +++ b/app/models/validations/financial_validations.rb @@ -5,8 +5,8 @@ module Validations::FinancialValidations # or 'validate_' to run on submit as well def validate_outstanding_rent_amount(record) if !record.has_housing_benefit_rent_shortfall? && record.tshortfall.present? - record.errors.add :tshortfall, :no_outstanding_charges, message: I18n.t("validations.financial.tshortfall.outstanding_amount_not_required") - record.errors.add :hbrentshortfall, :no_outstanding_charges, message: I18n.t("validations.financial.hbrentshortfall.outstanding_amount_not_required") + record.errors.add :tshortfall, :no_outstanding_charges, message: I18n.t("validations.financial.tshortfall.outstanding_amount_not_expected") + record.errors.add :hbrentshortfall, :no_outstanding_charges, message: I18n.t("validations.financial.hbrentshortfall.outstanding_amount_not_expected") end end diff --git a/config/locales/en.yml b/config/locales/en.yml index 7e1666ea5..db0354246 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -242,11 +242,11 @@ en: financial: tshortfall: - outstanding_amount_not_required: "You cannot answer the outstanding amount question if you don’t have outstanding rent or charges" + outstanding_amount_not_expected: "You cannot answer the outstanding amount question if you don’t have outstanding rent or charges" more_than_rent: "Enter a value less less than the basic rent amount" must_be_positive: "Enter a value over £0.01 as you told us there is an outstanding amount" hbrentshortfall: - outstanding_amount_not_required: "Answer must be ‘yes’ as you have answered the outstanding amount question" + outstanding_amount_not_expected: "Answer must be ‘yes’ as you have answered the outstanding amount question" outstanding_no_benefits: "Answer cannot be ‘yes’ to outstanding amount for basic rent or charges if tenant does not receive housing benefit or Universal Credit or you‘re not sure" benefits: part_or_full_time: "Answer cannot be ‘all’ for income from Universal Credit, state pensions or benefits if the tenant or their partner works part-time or full-time"