diff --git a/app/controllers/providers_controller.rb b/app/controllers/providers_controller.rb index 152207988..e2c567d14 100644 --- a/app/controllers/providers_controller.rb +++ b/app/controllers/providers_controller.rb @@ -70,7 +70,7 @@ def index } render json: ProviderSerializer.new(@providers, options).serialized_json, status: :ok end - header = %w(name provider_id year contact_name contact_address is_active description website region country_code logo_url focus_area organisation_type memmber_type address post_code city state twitter_handle ror_id role_name joined created updated deleted_at) + header = %w(name provider_id year contact_name contact_address is_active description website region country logo_url focus_area organisation_type memmber_type address post_code city state twitter_handle ror_id role_name joined created updated deleted_at) format.csv { render request.format.to_sym => response.records.to_a, header: header } end rescue Elasticsearch::Transport::Transport::Errors::BadRequest => exception diff --git a/app/models/provider.rb b/app/models/provider.rb index 0bb4364d6..af4c6080b 100644 --- a/app/models/provider.rb +++ b/app/models/provider.rb @@ -170,8 +170,8 @@ def csv is_active: is_active, description: description, website: website, - region: region, - country_code: country_code, + region: region_human_name, + country: country_name, logo_url: logo_url, focus_area: focus_area, organization_type: organization_type,