-
Notifications
You must be signed in to change notification settings - Fork 180
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Include V2 registrations in WCIF output (#9074)
* Make 'Assignemnts' table polymorphic * Hook up WCIF associations for MicroserviceRegistrations * Add missing WCIF methods to MicroserviceRegistration * Stub microservice writing methods * Store non-competing dummy registrations in cache table * Add 'roles' field to migration and harmonize 'is_competing' * Clarify comments about nil values for comment strings * Fix column sanitizers for overhauled registration tables * Fix WCIF status cancelled VS deleted and waiting_list VS pending * Remove redundant 'roles' accessor
- Loading branch information
Showing
9 changed files
with
125 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
db/migrate/20240306134217_make_assignments_table_registration_polymorphic.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# frozen_string_literal: true | ||
|
||
class MakeAssignmentsTableRegistrationPolymorphic < ActiveRecord::Migration[7.1] | ||
def change | ||
add_column :assignments, :registration_type, :string, after: :registration_id | ||
|
||
remove_index :assignments, column: :registration_id | ||
add_index :assignments, [:registration_id, :registration_type] | ||
|
||
Assignment.update_all(registration_type: 'Registration') | ||
end | ||
end |
8 changes: 8 additions & 0 deletions
8
db/migrate/20240307181801_add_staff_dummy_fields_to_microservice_registrations.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# frozen_string_literal: true | ||
|
||
class AddStaffDummyFieldsToMicroserviceRegistrations < ActiveRecord::Migration[7.1] | ||
def change | ||
add_column :microservice_registrations, :roles, :text, after: :user_id, null: true | ||
add_column :microservice_registrations, :is_competing, :boolean, after: :roles, default: true, null: false | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters