Browse Source
splits the referral_register question and pages into two, as its not easy to have the answers be dependent if the owning organisation changes type, reset the referral register question. the other questions do not need to be reset as they are no longer routed topull/3153/head
8 changed files with 81 additions and 22 deletions
@ -1,11 +0,0 @@
|
||||
# added in 2026 |
||||
class Form::Lettings::Pages::ReferralRegister < ::Form::Page |
||||
def initialize(id, hsh, subsection) |
||||
super |
||||
@id = "referral_register" |
||||
end |
||||
|
||||
def questions |
||||
@questions ||= [Form::Lettings::Questions::ReferralRegister.new(nil, nil, self)] |
||||
end |
||||
end |
||||
@ -0,0 +1,15 @@
|
||||
# added in 2026 |
||||
class Form::Lettings::Pages::ReferralRegisterLa < ::Form::Page |
||||
def initialize(id, hsh, subsection) |
||||
super |
||||
@id = "referral_register_la" |
||||
end |
||||
|
||||
def questions |
||||
@questions ||= [Form::Lettings::Questions::ReferralRegister.new(nil, nil, self, :la)] |
||||
end |
||||
|
||||
def routed_to?(log, _current_user) |
||||
log.owning_organisation&.la? |
||||
end |
||||
end |
||||
@ -0,0 +1,15 @@
|
||||
# added in 2026 |
||||
class Form::Lettings::Pages::ReferralRegisterPrp < ::Form::Page |
||||
def initialize(id, hsh, subsection) |
||||
super |
||||
@id = "referral_register_prp" |
||||
end |
||||
|
||||
def questions |
||||
@questions ||= [Form::Lettings::Questions::ReferralRegister.new(nil, nil, self, :prp)] |
||||
end |
||||
|
||||
def routed_to?(log, _current_user) |
||||
log.owning_organisation&.prp? |
||||
end |
||||
end |
||||
Loading…
Reference in new issue