From b5b37b64f1a3b96dd7d660ac51db5701cd37820b Mon Sep 17 00:00:00 2001 From: Aaron Spencer Date: Mon, 26 Jun 2023 17:11:22 +0100 Subject: [PATCH] CLDC-2439: Text moved to en.yml --- .../form/lettings/questions/max_rent_value_check.rb | 6 +----- .../form/lettings/questions/min_rent_value_check.rb | 9 ++++----- config/locales/en.yml | 1 + 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/app/models/form/lettings/questions/max_rent_value_check.rb b/app/models/form/lettings/questions/max_rent_value_check.rb index 3dc3a41a4..1b70c92dc 100644 --- a/app/models/form/lettings/questions/max_rent_value_check.rb +++ b/app/models/form/lettings/questions/max_rent_value_check.rb @@ -5,15 +5,11 @@ class Form::Lettings::Questions::MaxRentValueCheck < ::Form::Question @check_answer_label = "Total rent confirmation" @header = "Are you sure this is correct?" @type = "interruption_screen" - @hint_text = hint_text + @hint_text = "This is higher than we would expect. Check:" @check_answers_card_number = check_answers_card_number @answer_options = ANSWER_OPTIONS @hidden_in_check_answers = { "depends_on" => [{ "rent_value_check" => 0 }, { "rent_value_check" => 1 }] } end ANSWER_OPTIONS = { "0" => { "value" => "Yes" }, "1" => { "value" => "No" } }.freeze - - def hint_text - "This is higher than we would expect. Check:" - end end diff --git a/app/models/form/lettings/questions/min_rent_value_check.rb b/app/models/form/lettings/questions/min_rent_value_check.rb index 74c1ca0dd..0853dd5c1 100644 --- a/app/models/form/lettings/questions/min_rent_value_check.rb +++ b/app/models/form/lettings/questions/min_rent_value_check.rb @@ -5,15 +5,14 @@ class Form::Lettings::Questions::MinRentValueCheck < ::Form::Question @check_answer_label = "Total rent confirmation" @header = "Are you sure this is correct?" @type = "interruption_screen" - @hint_text = hint_text + @hint_text = I18n.t("soft_validations.rent.soft_min_hint_text") + # @hint_text = "This is lower than we would expect. Check:" @check_answers_card_number = check_answers_card_number @answer_options = ANSWER_OPTIONS @hidden_in_check_answers = { "depends_on" => [{ "rent_value_check" => 0 }, { "rent_value_check" => 1 }] } end - ANSWER_OPTIONS = { "0" => { "value" => "Yes" }, "1" => { "value" => "No" } }.freeze - def hint_text - "This is lower than we would expect. Check:" - end + + ANSWER_OPTIONS = { "0" => { "value" => "Yes" }, "1" => { "value" => "No" } }.freeze end diff --git a/config/locales/en.yml b/config/locales/en.yml index 2fcd02046..a93a6f812 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -595,6 +595,7 @@ en: over_soft_max_for_la_combined: "You told us the combined income of this household is %{combined_income}. This seems high. Are you sure this is correct?" rent: outside_range_title: "You told us the rent is %{brent}" + hint_text: "This is %{higher_or_lower} than we would expect. Check:" purchase_price: title_text: "You told us the purchase price is %{value}" hint_text: "This is %{higher_or_lower} than we would expect"