From c6785c9a0a3fee5f8b86077184070a45b2051e9b Mon Sep 17 00:00:00 2001 From: Kat Date: Tue, 2 May 2023 11:52:05 +0100 Subject: [PATCH] Update validation message: mortgage --- .../form/sales/pages/mortgage_value_check.rb | 15 ++++++++++++++- config/locales/en.yml | 3 ++- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/app/models/form/sales/pages/mortgage_value_check.rb b/app/models/form/sales/pages/mortgage_value_check.rb index 96bb4a22b..949cea27f 100644 --- a/app/models/form/sales/pages/mortgage_value_check.rb +++ b/app/models/form/sales/pages/mortgage_value_check.rb @@ -4,7 +4,20 @@ class Form::Sales::Pages::MortgageValueCheck < ::Form::Page @depends_on = depends_on @informative_text = {} @person_index = person_index - @title_text = { "translation" => "soft_validations.mortgage.title_text" } + @title_text = { + "translation" => "soft_validations.mortgage.title_text", + "arguments" => [ + { + "key" => "field_formatted_as_currency", + "arguments_for_key" => "mortgage", + "i18n_template" => "mortgage", + }, + ], + } + @informative_text = { + "translation" => "soft_validations.mortgage.hint_text", + "arguments" => [], + } end def questions diff --git a/config/locales/en.yml b/config/locales/en.yml index 00925b3e8..a5218afa9 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -590,7 +590,8 @@ en: wheelchair: title_text: "You told us that someone in the household uses a wheelchair." mortgage: - title_text: "Are you sure that the mortgage is more than 5 times the income used for the mortgage application?" + title_text: "You told us that the mortgage amount is %{mortgage}" + hint_text: "This is more than 5 times the income, which is higher than we would expect." devise: two_factor_authentication: