Skip to content

Commit 0f63607

Browse files
Merge pull request #6537 from NHSDigital/fix-school-move-merge
Handle reworked school move with team-merger
2 parents 2651014 + 1030b55 commit 0f63607

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

app/lib/team_merger.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ class TeamMerger
1111
ImmunisationImport,
1212
PatientSpecificDirection,
1313
SchoolMoveLogEntry,
14-
SchoolMove,
1514
Triage
1615
].freeze
1716

@@ -346,6 +345,10 @@ def migrate_generic_locations(merged_team)
346345
location_id: merged_loc.id
347346
)
348347

348+
SchoolMove.where(school_id: source_ids).update_all(
349+
school_id: merged_loc.id
350+
)
351+
349352
keep_ids =
350353
PatientLocation
351354
.where(location_id: source_ids)

0 commit comments

Comments
 (0)