diff --git a/app/serializers/api/applications_csv_serializer.rb b/app/serializers/api/applications_csv_serializer.rb index 81d02afc94..132d2773f8 100644 --- a/app/serializers/api/applications_csv_serializer.rb +++ b/app/serializers/api/applications_csv_serializer.rb @@ -19,6 +19,7 @@ class ApplicationsCsvSerializer private_childcare_provider_urn headteacher_status eligible_for_funding + funded_place funding_choice course_identifier status @@ -67,6 +68,7 @@ def to_row(application) application.private_childcare_provider&.provider_urn, application.headteacher_status, application.eligible_for_funding, + application.funded_place, application.funding_choice, application.course.identifier, application.lead_provider_approval_status, diff --git a/public/api/docs/v1/swagger.yaml b/public/api/docs/v1/swagger.yaml index e91f2509a9..0fbe55147f 100644 --- a/public/api/docs/v1/swagger.yaml +++ b/public/api/docs/v1/swagger.yaml @@ -1406,13 +1406,13 @@ components: example: | id,participant_id,full_name,email,email_validated,teacher_reference_number, teacher_reference_number_validated,school_urn,school_ukprn,private_childcare_provider_urn, - headteacher_status,eligible_for_funding,funding_choice,course_identifier, + headteacher_status,eligible_for_funding,funded_place,funding_choice,course_identifier, status,works_in_school,employer_name,employment_role,created_at,updated_at, cohort,ineligible_for_funding_reason,targeted_delivery_funding_eligibility, teacher_catchment,teacher_catchment_country,teacher_catchment_iso_country_code,itt_provider,lead_mentor db3a7848-7308-4879-942a-c4a70ced400a,7a8fef46-3c43-42c0-b3d5-1ba5904ba562, Isabelle MacDonald,isabelle.macdonald2@some-school.example.com,true,1234567, - false,100015,10005549,,no,false,trust,npq-early-headship-coaching-offer, + false,100015,10005549,,no,false,true,trust,npq-early-headship-coaching-offer, accepted,true,,,2024-04-23T15:52:03Z,2024-04-23T15:52:03Z,2021, establishment-ineligible,false,true,United Kingdom of Great Britain and Northern Ireland ,GBR,Test ITT Provider,false @@ -1497,6 +1497,11 @@ components: funding from the DfE type: boolean example: true + funded_place: + description: This field indicates whether the application is funded + nullable: true + type: boolean + example: true funding_choice: description: Indicates how this NPQ participant has said they will funded their training diff --git a/public/api/docs/v2/swagger.yaml b/public/api/docs/v2/swagger.yaml index 6a3881111c..87d39b2b9d 100644 --- a/public/api/docs/v2/swagger.yaml +++ b/public/api/docs/v2/swagger.yaml @@ -1590,13 +1590,13 @@ components: example: | id,participant_id,full_name,email,email_validated,teacher_reference_number, teacher_reference_number_validated,school_urn,school_ukprn,private_childcare_provider_urn, - headteacher_status,eligible_for_funding,funding_choice,course_identifier, + headteacher_status,eligible_for_funding,funded_place,funding_choice,course_identifier, status,works_in_school,employer_name,employment_role,created_at,updated_at, cohort,ineligible_for_funding_reason,targeted_delivery_funding_eligibility, teacher_catchment,teacher_catchment_country,teacher_catchment_iso_country_code,itt_provider,lead_mentor db3a7848-7308-4879-942a-c4a70ced400a,7a8fef46-3c43-42c0-b3d5-1ba5904ba562, Isabelle MacDonald,isabelle.macdonald2@some-school.example.com,true,1234567, - false,100015,10005549,,no,false,trust,npq-early-headship-coaching-offer, + false,100015,10005549,,no,false,true,trust,npq-early-headship-coaching-offer, accepted,true,,,2024-04-23T15:52:03Z,2024-04-23T15:52:03Z,2021, establishment-ineligible,false,true,United Kingdom of Great Britain and Northern Ireland ,GBR,Test ITT Provider,false @@ -1681,6 +1681,11 @@ components: funding from the DfE type: boolean example: true + funded_place: + description: This field indicates whether the application is funded + nullable: true + type: boolean + example: true funding_choice: description: Indicates how this NPQ participant has said they will funded their training diff --git a/spec/serializers/api/applications_csv_serializer_spec.rb b/spec/serializers/api/applications_csv_serializer_spec.rb index 272279b853..0b1ceba95e 100644 --- a/spec/serializers/api/applications_csv_serializer_spec.rb +++ b/spec/serializers/api/applications_csv_serializer_spec.rb @@ -13,7 +13,8 @@ :accepted, :with_private_childcare_provider, employer_name: "Employer Name", - employment_role: "Employment Role") + employment_role: "Employment Role", + funded_place: true) end let(:rows) { CSV.parse(csv, headers: true) } let(:first_application) { applications.first } @@ -30,6 +31,7 @@ employer_name: first_application.employer_name, employment_role: first_application.employment_role, full_name: first_application.user.full_name, + funded_place: first_application.funded_place.to_s, funding_choice: first_application.funding_choice, headteacher_status: first_application.headteacher_status, ineligible_for_funding_reason: first_application.ineligible_for_funding_reason, diff --git a/spec/swagger_schemas/models/application_csv.rb b/spec/swagger_schemas/models/application_csv.rb index 6ac0525964..40f1f36ecd 100644 --- a/spec/swagger_schemas/models/application_csv.rb +++ b/spec/swagger_schemas/models/application_csv.rb @@ -81,6 +81,12 @@ type: :boolean, example: true, }, + funded_place: { + description: "This field indicates whether the application is funded", + nullable: true, + type: :boolean, + example: true, + }, funding_choice: { description: "Indicates how this NPQ participant has said they will funded their training", type: :string, diff --git a/spec/swagger_schemas/responses/applications_csv.rb b/spec/swagger_schemas/responses/applications_csv.rb index 388ae2d8db..521a26cac0 100644 --- a/spec/swagger_schemas/responses/applications_csv.rb +++ b/spec/swagger_schemas/responses/applications_csv.rb @@ -9,13 +9,13 @@ }, example: "id,participant_id,full_name,email,email_validated,teacher_reference_number,\n" \ "teacher_reference_number_validated,school_urn,school_ukprn,private_childcare_provider_urn,\n" \ - "headteacher_status,eligible_for_funding,funding_choice,course_identifier,\n" \ + "headteacher_status,eligible_for_funding,funded_place,funding_choice,course_identifier,\n" \ "status,works_in_school,employer_name,employment_role,created_at,updated_at,\n" \ "cohort,ineligible_for_funding_reason,targeted_delivery_funding_eligibility,\n" \ "teacher_catchment,teacher_catchment_country,teacher_catchment_iso_country_code,itt_provider,lead_mentor\n"\ "db3a7848-7308-4879-942a-c4a70ced400a,7a8fef46-3c43-42c0-b3d5-1ba5904ba562,\n" \ "Isabelle MacDonald,isabelle.macdonald2@some-school.example.com,true,1234567,\n" \ - "false,100015,10005549,,no,false,trust,npq-early-headship-coaching-offer,\n" \ + "false,100015,10005549,,no,false,true,trust,npq-early-headship-coaching-offer,\n" \ "accepted,true,,,2024-04-23T15:52:03Z,2024-04-23T15:52:03Z,2021,\n" \ "establishment-ineligible,false,true,United Kingdom of Great Britain and Northern Ireland\n" \ ",GBR,Test ITT Provider,false\n",