Browse Source

feat: updated copy requirements

CLDC-1790-sales-validation-content-updates
natdeanlewissoftwire 2 years ago
parent
commit
a421007141
  1. 2
      app/models/form/sales/questions/deposit_value_check.rb
  2. 2
      app/models/form/sales/questions/household_wheelchair_check.rb
  3. 2
      app/models/form/sales/questions/mortgage_value_check.rb
  4. 2
      app/models/form/sales/questions/savings_value_check.rb
  5. 2
      app/models/validations/sales/financial_validations.rb
  6. 8
      config/locales/en.yml
  7. 2
      spec/models/form/sales/questions/deposit_value_check_spec.rb
  8. 2
      spec/models/form/sales/questions/household_wheelchair_check_spec.rb
  9. 2
      spec/models/form/sales/questions/mortgage_value_check_spec.rb
  10. 2
      spec/models/form/sales/questions/savings_value_check_spec.rb

2
app/models/form/sales/questions/deposit_value_check.rb

@ -3,7 +3,7 @@ class Form::Sales::Questions::DepositValueCheck < ::Form::Question
super
@id = "deposit_value_check"
@check_answer_label = "Deposit confirmation"
@header = "Are you sure that the deposit is this much higher than the buyer's savings?"
@header = "Are you sure the buyer's deposit is this much higher than their savings?"
@type = "interruption_screen"
@answer_options = {
"0" => { "value" => "Yes" },

2
app/models/form/sales/questions/household_wheelchair_check.rb

@ -3,7 +3,7 @@ class Form::Sales::Questions::HouseholdWheelchairCheck < ::Form::Question
super
@id = "wheel_value_check"
@check_answer_label = "Does anyone in the household use a wheelchair?"
@header = "Is this right? Earlier, you said someone in the household uses a wheelchair"
@header = "Are you sure? Earlier, you said that that nobody in the household considers themselves to have a disability"
@type = "interruption_screen"
@answer_options = {
"0" => { "value" => "Yes" },

2
app/models/form/sales/questions/mortgage_value_check.rb

@ -3,7 +3,7 @@ class Form::Sales::Questions::MortgageValueCheck < ::Form::Question
super
@id = "mortgage_value_check"
@check_answer_label = "Mortgage confirmation"
@header = "Are you sure that the mortgage is more than 5 times the income used for the mortgage application?"
@header = "Are you sure the mortgage is more than 5 times the income used for the mortgage application?"
@type = "interruption_screen"
@answer_options = {
"0" => { "value" => "Yes" },

2
app/models/form/sales/questions/savings_value_check.rb

@ -3,7 +3,7 @@ class Form::Sales::Questions::SavingsValueCheck < ::Form::Question
super
@id = "savings_value_check"
@check_answer_label = "Savings confirmation"
@header = "Are you sure the savings are higher than £100,000?"
@header = "Are you sure savings are above £100,000?"
@type = "interruption_screen"
@answer_options = {
"0" => { "value" => "Yes" },

2
app/models/validations/sales/financial_validations.rb

@ -10,7 +10,7 @@ module Validations::Sales::FinancialValidations
record.errors.add :ownershipsch, I18n.t("validations.financial.income1.over_hard_max.inside_london")
record.errors.add :la, I18n.t("validations.financial.income1.over_hard_max.inside_london")
record.errors.add :postcode_full, I18n.t("validations.financial.income1.over_hard_max.inside_london")
elsif record.income1 > 80_000
elsif !record.london_property? && record.income1 > 80_000
record.errors.add :income1, I18n.t("validations.financial.income1.over_hard_max.outside_london")
record.errors.add :ecstat1, I18n.t("validations.financial.income1.over_hard_max.outside_london")
record.errors.add :ownershipsch, I18n.t("validations.financial.income1.over_hard_max.outside_london")

8
config/locales/en.yml

@ -214,8 +214,8 @@ en:
earnings_missing: "Enter how much income the household has in total"
income1:
over_hard_max:
outside_london: "Income maximum under £80,000 for properties outside London local authorities"
inside_london: "Income maximum £90,000 for properties within London local authorities"
outside_london: "Income must not exceed £80,000 for properties outside London local authorities"
inside_london: "Income must not exceed £90,000 for properties within London local authorities"
negative_currency: "Enter an amount above 0"
rent:
less_than_shortfall: "Enter an amount that is more than the shortfall in basic rent"
@ -372,7 +372,7 @@ en:
no_choices: "You cannot answer this question as you told us nobody in the household has a physical or mental health condition (or other illness) expected to last 12 months or more"
postcode:
discounted_ownership: "Last settled accommodation and discounted ownership property postcodes must match"
tenancy:
length:
fixed_term_not_required: "You must only answer the length of the tenancy if it's fixed-term"
@ -423,7 +423,7 @@ en:
must_be_less_than_1_year_from_saledate:
Contract exchange date must be less than 1 year before completion date
previous_property_beds:
property_type_bedsit: "A bedsit cannot have more than 1 bedroom"
property_type_bedsit: "Number of bedrooms must be 1 if the property is a bedsit"
discounted_ownership_value: "Mortgage, deposit, and grant total must equal £%{value_with_discount}"
monthly_rent:
higher_than_expected: "Basic monthly rent must be between £0 and £9,999"

2
spec/models/form/sales/questions/deposit_value_check_spec.rb

@ -16,7 +16,7 @@ RSpec.describe Form::Sales::Questions::DepositValueCheck, type: :model do
end
it "has the correct header" do
expect(question.header).to eq("Are you sure that the deposit is this much higher than the buyer's savings?")
expect(question.header).to eq("Are you sure the buyer's deposit is this much higher than their savings?")
end
it "has the correct check_answer_label" do

2
spec/models/form/sales/questions/household_wheelchair_check_spec.rb

@ -16,7 +16,7 @@ RSpec.describe Form::Sales::Questions::HouseholdWheelchairCheck, type: :model do
end
it "has the correct header" do
expect(question.header).to eq("Is this right? Earlier, you said someone in the household uses a wheelchair")
expect(question.header).to eq("Are you sure? Earlier, you said that that nobody in the household considers themselves to have a disability")
end
it "has the correct check_answer_label" do

2
spec/models/form/sales/questions/mortgage_value_check_spec.rb

@ -16,7 +16,7 @@ RSpec.describe Form::Sales::Questions::MortgageValueCheck, type: :model do
end
it "has the correct header" do
expect(question.header).to eq("Are you sure that the mortgage is more than 5 times the income used for the mortgage application?")
expect(question.header).to eq("Are you sure the mortgage is more than 5 times the income used for the mortgage application?")
end
it "has the correct check_answer_label" do

2
spec/models/form/sales/questions/savings_value_check_spec.rb

@ -16,7 +16,7 @@ RSpec.describe Form::Sales::Questions::SavingsValueCheck, type: :model do
end
it "has the correct header" do
expect(question.header).to eq("Are you sure the savings are higher than £100,000?")
expect(question.header).to eq("Are you sure savings are above £100,000?")
end
it "has the correct check_answer_label" do

Loading…
Cancel
Save