@ -214,7 +214,6 @@ class Scheme < ApplicationRecord
if confirmed == true
required_attributes.any? do |attribute|
if self[attribute].blank?
errors.add :base
errors.add attribute.to_sym
self.confirmed = false
end
@ -65,8 +65,6 @@ en:
invalid: "Select if this scheme provides for another client group"
arrangement_type:
invalid: "Select who provides the support services used by this scheme"
base:
invalid: "You must answer all the required questions for this scheme"
location:
attributes:
startdate:
@ -586,7 +586,7 @@ RSpec.describe SchemesController, type: :request do
it "does not allow the scheme to be confirmed" do
expect(response).to have_http_status(:unprocessable_entity)
expect(page).to have_content(I18n.t("activerecord.errors.models.scheme.attributes.base.invalid"))
expect(page).to have_content(I18n.t("activerecord.errors.models.scheme.attributes.managing_organisation_id.invalid"))