From 747c19d60792a30495193315a491f7b3d5da6e29 Mon Sep 17 00:00:00 2001 From: sarahcrack <73823091+sarahcrack@users.noreply.github.com> Date: Mon, 2 Dec 2024 16:28:26 +0000 Subject: [PATCH 1/3] adapted ListingComponent to order providers regardless of letter case --- app/components/grouped_cards/listing_component.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/components/grouped_cards/listing_component.rb b/app/components/grouped_cards/listing_component.rb index 805ae4ec10..12dfeb58da 100644 --- a/app/components/grouped_cards/listing_component.rb +++ b/app/components/grouped_cards/listing_component.rb @@ -15,7 +15,7 @@ def group_link_anchor(group) end def items(group) - @data.dig(group, "providers") + @data.dig(group, "providers").sort_by { |provider| provider["header"].to_s.downcase } end def description(group) From 627cfd53b17b264c56d432ad9f707353e4742181 Mon Sep 17 00:00:00 2001 From: sarahcrack <73823091+sarahcrack@users.noreply.github.com> Date: Tue, 3 Dec 2024 10:02:31 +0000 Subject: [PATCH 2/3] removed case insentive sorting from ListingComponent and adapted rake tasks to handle sort --- app/components/grouped_cards/listing_component.rb | 2 +- .../assessment-only-route-to-qts.md | 15 ++++++++------- .../train-to-be-a-teacher/teaching-internships.md | 15 ++++++++------- lib/tasks/generate_assessment_only_providers.rake | 2 +- .../generate_teaching_internship_providers.rake | 2 +- 5 files changed, 19 insertions(+), 17 deletions(-) diff --git a/app/components/grouped_cards/listing_component.rb b/app/components/grouped_cards/listing_component.rb index 12dfeb58da..805ae4ec10 100644 --- a/app/components/grouped_cards/listing_component.rb +++ b/app/components/grouped_cards/listing_component.rb @@ -15,7 +15,7 @@ def group_link_anchor(group) end def items(group) - @data.dig(group, "providers").sort_by { |provider| provider["header"].to_s.downcase } + @data.dig(group, "providers") end def description(group) diff --git a/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md b/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md index 44fe20d184..6bf4bd774f 100644 --- a/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md +++ b/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md @@ -4,6 +4,7 @@ heading: "Assessment only route to QTS for unqualified teachers" subcategory: Other routes into teaching description: |- Find out about the assessment only route to qualified teacher status (QTS) for unqualified teachers who have worked in a classroom. +date: "2021-06-08" image: false backlink: / promo_content: @@ -395,6 +396,13 @@ provider_groups: telephone: "01227 925555" international_phone: "+441227925555" + - header: "i2i Teaching Partnership SCITT" + link: "https://www.i2ipartnership.co.uk/" + name: "Krissy Taylor" + email: "ktaylor@i2ipartnership.co.uk" + telephone: "01252 900550" + international_phone: "+441252900550" + - header: "Inspiring Futures Partnership Trust" link: "https://cheppingviewscitt.com/Entry-Criteria/" name: "Nicky Stephenson" @@ -458,13 +466,6 @@ provider_groups: telephone: "0118 378 7237" international_phone: "+441183787237" - - header: "i2i Teaching Partnership SCITT" - link: "https://www.i2ipartnership.co.uk/" - name: "Krissy Taylor" - email: "ktaylor@i2ipartnership.co.uk" - telephone: "01252 900550" - international_phone: "+441252900550" - South West: providers: - header: "Bournemouth Bay Teacher Training Partnership" diff --git a/app/views/content/train-to-be-a-teacher/teaching-internships.md b/app/views/content/train-to-be-a-teacher/teaching-internships.md index 819bad347a..fc8bdde44d 100644 --- a/app/views/content/train-to-be-a-teacher/teaching-internships.md +++ b/app/views/content/train-to-be-a-teacher/teaching-internships.md @@ -4,6 +4,7 @@ heading: "Get teaching experience with an internship" subcategory: Postgraduate teacher training description: |- Find paid teaching internships to gain new skills and see what classroom life is like. Explore chemistry, computing, languages, maths and physics internships. +date: "2021-04-14" image: false promo_content: - content/train-to-be-a-teacher/promos/eta-promo-internships @@ -365,6 +366,13 @@ provider_groups: areas: "West Berkshire" name: "Claire Hickling" email: "c.hickling@niot.org.uk" + - header: "i2i Teaching Partnership" + link: "https://www.i2ipartnership.co.uk/1243/undergraduate-teaching-internship-programme" + applications: "Open January" + subjects: "chemistry, computing, maths, physics, languages" + areas: "Hampshire, Surrey" + name: "Liz Wylie" + email: "lwylie@i2ipartnership.co.uk" - header: "Ringwood School" link: "https://www.ringwood.hants.sch.uk/teacher-training/paid-internships/" applications: "Open April" @@ -400,13 +408,6 @@ provider_groups: areas: "Slough, Surrey" name: "Natasha Bisset" email: "n.bisset@xaviercet.org.uk" - - header: "i2i Teaching Partnership" - link: "https://www.i2ipartnership.co.uk/1243/undergraduate-teaching-internship-programme" - applications: "Open January" - subjects: "chemistry, computing, maths, physics, languages" - areas: "Hampshire, Surrey" - name: "Liz Wylie" - email: "lwylie@i2ipartnership.co.uk" South West: providers: - header: "Excalibur Academies Trust" diff --git a/lib/tasks/generate_assessment_only_providers.rake b/lib/tasks/generate_assessment_only_providers.rake index 10c8f03561..01fe5bb3ad 100644 --- a/lib/tasks/generate_assessment_only_providers.rake +++ b/lib/tasks/generate_assessment_only_providers.rake @@ -19,7 +19,7 @@ namespace :assessment_only_providers do end end - provider_groups = provider_groups.transform_values { |v| v["providers"].sort_by { |a| a["header"] } }.sort_by { |x, _y| [case x when "Non-UK"then 2; when "National" then 0; else 1 end, x] } + provider_groups = provider_groups.transform_values { |v| v["providers"].sort_by { |a| a["header"].to_s.downcase } }.sort_by { |x, _y| [case x when "Non-UK"then 2; when "National" then 0; else 1 end, x] } File.open("app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md", "w") do |f| f.write ERB.new(File.read("lib/tasks/support/assessment-only-route-to-qts.md.erb"), trim_mode: "<>").result(binding) diff --git a/lib/tasks/generate_teaching_internship_providers.rake b/lib/tasks/generate_teaching_internship_providers.rake index 3a6bcaabe0..2953e56aa2 100644 --- a/lib/tasks/generate_teaching_internship_providers.rake +++ b/lib/tasks/generate_teaching_internship_providers.rake @@ -14,7 +14,7 @@ namespace :teaching_internship_providers do h[ip.region.to_s]["providers"] << ip.to_h end - providers.transform_values! { |v| v["providers"].sort_by { |a| a["header"] } } + providers.transform_values! { |v| v["providers"].sort_by { |a| a["header"].to_s.downcase } } provider_groups = providers.sort File.open("app/views/content/train-to-be-a-teacher/teaching-internships.md", "w") do |f| From d132933c162c5f1fc3f030c37ee8aa045fd6e0da Mon Sep 17 00:00:00 2001 From: sarahcrack <73823091+sarahcrack@users.noreply.github.com> Date: Tue, 3 Dec 2024 10:40:53 +0000 Subject: [PATCH 3/3] removed date from internships and assessment only page template --- .../train-to-be-a-teacher/assessment-only-route-to-qts.md | 1 - app/views/content/train-to-be-a-teacher/teaching-internships.md | 1 - lib/tasks/support/assessment-only-route-to-qts.md.erb | 1 - lib/tasks/support/teaching-internship-providers.md.erb | 1 - 4 files changed, 4 deletions(-) diff --git a/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md b/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md index 6bf4bd774f..752ed22a64 100644 --- a/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md +++ b/app/views/content/train-to-be-a-teacher/assessment-only-route-to-qts.md @@ -4,7 +4,6 @@ heading: "Assessment only route to QTS for unqualified teachers" subcategory: Other routes into teaching description: |- Find out about the assessment only route to qualified teacher status (QTS) for unqualified teachers who have worked in a classroom. -date: "2021-06-08" image: false backlink: / promo_content: diff --git a/app/views/content/train-to-be-a-teacher/teaching-internships.md b/app/views/content/train-to-be-a-teacher/teaching-internships.md index fc8bdde44d..4c8d6f2289 100644 --- a/app/views/content/train-to-be-a-teacher/teaching-internships.md +++ b/app/views/content/train-to-be-a-teacher/teaching-internships.md @@ -4,7 +4,6 @@ heading: "Get teaching experience with an internship" subcategory: Postgraduate teacher training description: |- Find paid teaching internships to gain new skills and see what classroom life is like. Explore chemistry, computing, languages, maths and physics internships. -date: "2021-04-14" image: false promo_content: - content/train-to-be-a-teacher/promos/eta-promo-internships diff --git a/lib/tasks/support/assessment-only-route-to-qts.md.erb b/lib/tasks/support/assessment-only-route-to-qts.md.erb index da68d577d4..aabce80623 100644 --- a/lib/tasks/support/assessment-only-route-to-qts.md.erb +++ b/lib/tasks/support/assessment-only-route-to-qts.md.erb @@ -4,7 +4,6 @@ heading: "Assessment only route to QTS for unqualified teachers" subcategory: Other routes into teaching description: |- Find out about the assessment only route to qualified teacher status (QTS) for unqualified teachers who have worked in a classroom. -date: "2021-06-08" image: false backlink: / promo_content: diff --git a/lib/tasks/support/teaching-internship-providers.md.erb b/lib/tasks/support/teaching-internship-providers.md.erb index 8996be7ac5..c56fc98e7a 100644 --- a/lib/tasks/support/teaching-internship-providers.md.erb +++ b/lib/tasks/support/teaching-internship-providers.md.erb @@ -4,7 +4,6 @@ heading: "Get teaching experience with an internship" subcategory: Postgraduate teacher training description: |- Find paid teaching internships to gain new skills and see what classroom life is like. Explore chemistry, computing, languages, maths and physics internships. -date: "2021-04-14" image: false promo_content: - content/train-to-be-a-teacher/promos/eta-promo-internships