|
|
|
@ -51,7 +51,7 @@ module Csv |
|
|
|
labels: %i[location mobility_type], |
|
|
|
labels: %i[location mobility_type], |
|
|
|
codes: %i[location mobility_type_before_type_cast], |
|
|
|
codes: %i[location mobility_type_before_type_cast], |
|
|
|
}, |
|
|
|
}, |
|
|
|
location_admin_district: { |
|
|
|
location_local_authority: { |
|
|
|
labels: %i[location location_admin_district], |
|
|
|
labels: %i[location location_admin_district], |
|
|
|
codes: %i[location location_admin_district], |
|
|
|
codes: %i[location location_admin_district], |
|
|
|
}, |
|
|
|
}, |
|
|
|
@ -281,7 +281,7 @@ module Csv |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
non_question_fields = %w[id status created_by is_dpo created_at updated_by updated_at creation_method old_id old_form_id collection_start_year] |
|
|
|
non_question_fields = %w[id status created_by is_dpo created_at updated_by updated_at creation_method old_id old_form_id collection_start_year] |
|
|
|
scheme_and_location_attributes = %w[scheme_code scheme_service_name scheme_sensitive SCHTYPE scheme_registered_under_care_act scheme_owning_organisation_name scheme_primary_client_group scheme_has_other_client_group scheme_secondary_client_group scheme_support_type scheme_intended_stay scheme_created_at location_code location_postcode location_name location_units location_type_of_unit location_mobility_type location_admin_district location_startdate] |
|
|
|
scheme_and_location_attributes = %w[scheme_code scheme_service_name scheme_sensitive SCHTYPE scheme_registered_under_care_act scheme_owning_organisation_name scheme_primary_client_group scheme_has_other_client_group scheme_secondary_client_group scheme_support_type scheme_intended_stay scheme_created_at location_code location_postcode location_name location_units location_type_of_unit location_mobility_type location_local_authority location_startdate] |
|
|
|
final_attributes = non_question_fields + attributes + scheme_and_location_attributes |
|
|
|
final_attributes = non_question_fields + attributes + scheme_and_location_attributes |
|
|
|
@user.support? ? final_attributes : final_attributes - SUPPORT_ONLY_ATTRIBUTES |
|
|
|
@user.support? ? final_attributes : final_attributes - SUPPORT_ONLY_ATTRIBUTES |
|
|
|
end |
|
|
|
end |
|
|
|
|