Browse Source

CLDC-2398 Update bulk upload setup error messages (#1743)

* Update bulk upload setup error messages

* typo
demo-previous-period-open
kosiakkatrina 1 year ago committed by GitHub
parent
commit
5e7a6dee5b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      app/services/bulk_upload/sales/year2022/row_parser.rb
  2. 12
      app/services/bulk_upload/sales/year2023/row_parser.rb

10
app/services/bulk_upload/sales/year2022/row_parser.rb

@ -276,7 +276,7 @@ class BulkUpload::Sales::Year2022::RowParser
validates :field_57,
presence: {
message: I18n.t("validations.not_answered", question: "shared ownership type"),
message: I18n.t("validations.not_answered", question: "type of shared ownership sale"),
category: :setup,
},
if: :shared_ownership?,
@ -293,7 +293,7 @@ class BulkUpload::Sales::Year2022::RowParser
validates :field_76,
presence: {
message: I18n.t("validations.not_answered", question: "discounted ownership type"),
message: I18n.t("validations.not_answered", question: "type of discounted ownership sale"),
category: :setup,
},
if: :discounted_ownership?,
@ -345,13 +345,13 @@ class BulkUpload::Sales::Year2022::RowParser
if: :outright_sale?,
on: :after_log
validates :field_109, presence: { message: I18n.t("validations.not_answered", question: "more than 2 buyers"), category: :setup }, if: :joint_purchase?, on: :after_log
validates :field_109, presence: { message: I18n.t("validations.not_answered", question: "more than 2 joint buyers"), category: :setup }, if: :joint_purchase?, on: :after_log
validates :field_113, presence: { message: I18n.t("validations.not_answered", question: "ownership type"), category: :setup }, on: :after_log
validates :field_113, presence: { message: I18n.t("validations.not_answered", question: "purchase made under ownership scheme"), category: :setup }, on: :after_log
validates :field_114, presence: { message: I18n.t("validations.not_answered", question: "company buyer"), category: :setup }, if: :outright_sale?, on: :after_log
validates :field_115, presence: { message: I18n.t("validations.not_answered", question: "will the buyers live in the property"), category: :setup }, if: :outright_sale?, on: :after_log
validates :field_115, presence: { message: I18n.t("validations.not_answered", question: "buyers living in property"), category: :setup }, if: :outright_sale?, on: :after_log
validates :field_116, presence: { message: I18n.t("validations.not_answered", question: "joint purchase"), category: :setup }, if: :joint_purchase_asked?, on: :after_log

12
app/services/bulk_upload/sales/year2023/row_parser.rb

@ -335,7 +335,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_7,
presence: {
message: I18n.t("validations.not_answered", question: "ownership type"),
message: I18n.t("validations.not_answered", question: "purchase made under ownership scheme"),
category: :setup,
},
on: :after_log
@ -351,7 +351,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_8,
presence: {
message: I18n.t("validations.not_answered", question: "shared ownership type"),
message: I18n.t("validations.not_answered", question: "type of shared ownership sale"),
category: :setup,
if: :shared_ownership?,
},
@ -368,7 +368,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_9,
presence: {
message: I18n.t("validations.not_answered", question: "discounted ownership type"),
message: I18n.t("validations.not_answered", question: "type of discounted ownership sale"),
category: :setup,
if: :discounted_ownership?,
},
@ -385,7 +385,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_10,
presence: {
message: I18n.t("validations.not_answered", question: "type of ouright sale"),
message: I18n.t("validations.not_answered", question: "type of outright sale"),
category: :setup,
if: :outright_sale?,
},
@ -427,7 +427,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_13,
presence: {
message: I18n.t("validations.not_answered", question: "will the buyers live in the property"),
message: I18n.t("validations.not_answered", question: "buyers living in property"),
category: :setup,
if: :outright_sale?,
},
@ -443,7 +443,7 @@ class BulkUpload::Sales::Year2023::RowParser
validates :field_15,
presence: {
message: I18n.t("validations.not_answered", question: "more than 2 buyers"),
message: I18n.t("validations.not_answered", question: "more than 2 joint buyers"),
category: :setup,
if: :joint_purchase?,
},

Loading…
Cancel
Save