diff --git a/app/models/derived_variables/lettings_log_variables.rb b/app/models/derived_variables/lettings_log_variables.rb index 937dd7c2e..3a7350a8a 100644 --- a/app/models/derived_variables/lettings_log_variables.rb +++ b/app/models/derived_variables/lettings_log_variables.rb @@ -76,8 +76,8 @@ module DerivedVariables::LettingsLogVariables self.voiddate = startdate self.unitletas = form.start_date.year >= 2023 ? UNITLETAS_MAPPING_23_24[rent_type] : UNITLETAS_MAPPING[rent_type] if is_general_needs? - self.prevten = 32 if managing_organisation&.provider_type == "PRP" - self.prevten = 30 if managing_organisation&.provider_type == "LA" + self.prevten = 32 if owning_organisation&.provider_type == "PRP" + self.prevten = 30 if owning_organisation&.provider_type == "LA" end end diff --git a/app/models/form/lettings/pages/referral.rb b/app/models/form/lettings/pages/referral.rb index 3850fd400..9bda8c77e 100644 --- a/app/models/form/lettings/pages/referral.rb +++ b/app/models/form/lettings/pages/referral.rb @@ -2,7 +2,7 @@ class Form::Lettings::Pages::Referral < ::Form::Page def initialize(id, hsh, subsection) super @id = "referral" - @depends_on = [{ "managing_organisation_provider_type" => "LA", "needstype" => 1, "renewal" => 0 }] + @depends_on = [{ "owning_organisation_provider_type" => "LA", "needstype" => 1, "renewal" => 0 }] end def questions diff --git a/app/models/form/lettings/pages/referral_prp.rb b/app/models/form/lettings/pages/referral_prp.rb index b1f650d8e..d9c37b6d6 100644 --- a/app/models/form/lettings/pages/referral_prp.rb +++ b/app/models/form/lettings/pages/referral_prp.rb @@ -2,7 +2,7 @@ class Form::Lettings::Pages::ReferralPrp < ::Form::Page def initialize(id, hsh, subsection) super @id = "referral_prp" - @depends_on = [{ "managing_organisation_provider_type" => "PRP", "needstype" => 1, "renewal" => 0 }] + @depends_on = [{ "owning_organisation_provider_type" => "PRP", "needstype" => 1, "renewal" => 0 }] end def questions diff --git a/app/models/form/lettings/pages/referral_supported_housing.rb b/app/models/form/lettings/pages/referral_supported_housing.rb index 80d69b8cd..8464ae366 100644 --- a/app/models/form/lettings/pages/referral_supported_housing.rb +++ b/app/models/form/lettings/pages/referral_supported_housing.rb @@ -2,7 +2,7 @@ class Form::Lettings::Pages::ReferralSupportedHousing < ::Form::Page def initialize(id, hsh, subsection) super @id = "referral_supported_housing" - @depends_on = [{ "managing_organisation_provider_type" => "LA", "needstype" => 2, "renewal" => 0 }] + @depends_on = [{ "owning_organisation_provider_type" => "LA", "needstype" => 2, "renewal" => 0 }] end def questions diff --git a/app/models/form/lettings/pages/referral_supported_housing_prp.rb b/app/models/form/lettings/pages/referral_supported_housing_prp.rb index 244f85fcd..289ae5eb6 100644 --- a/app/models/form/lettings/pages/referral_supported_housing_prp.rb +++ b/app/models/form/lettings/pages/referral_supported_housing_prp.rb @@ -2,7 +2,7 @@ class Form::Lettings::Pages::ReferralSupportedHousingPrp < ::Form::Page def initialize(id, hsh, subsection) super @id = "referral_supported_housing_prp" - @depends_on = [{ "managing_organisation_provider_type" => "PRP", "needstype" => 2, "renewal" => 0 }] + @depends_on = [{ "owning_organisation_provider_type" => "PRP", "needstype" => 2, "renewal" => 0 }] end def questions diff --git a/app/models/lettings_log.rb b/app/models/lettings_log.rb index 6fce43f42..922df5977 100644 --- a/app/models/lettings_log.rb +++ b/app/models/lettings_log.rb @@ -493,8 +493,8 @@ class LettingsLog < Log update(unresolved: false) end - def managing_organisation_provider_type - managing_organisation&.provider_type + def owning_organisation_provider_type + owning_organisation&.provider_type end def reset_created_by! diff --git a/config/forms/2022_2023.json b/config/forms/2022_2023.json index 5a65e6f0e..161101e4f 100644 --- a/config/forms/2022_2023.json +++ b/config/forms/2022_2023.json @@ -7010,7 +7010,7 @@ }, "depends_on": [ { - "managing_organisation_provider_type": "LA", + "owning_organisation_provider_type": "LA", "needstype": 1, "renewal": 0 } @@ -7067,7 +7067,7 @@ }, "depends_on": [ { - "managing_organisation_provider_type": "PRP", + "owning_organisation_provider_type": "PRP", "needstype": 1, "renewal": 0 } @@ -7124,7 +7124,7 @@ }, "depends_on": [ { - "managing_organisation_provider_type": "LA", + "owning_organisation_provider_type": "LA", "needstype": 2, "renewal": 0 } @@ -7184,7 +7184,7 @@ }, "depends_on": [ { - "managing_organisation_provider_type": "PRP", + "owning_organisation_provider_type": "PRP", "needstype": 2, "renewal": 0 }