Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor back-end for chapter assignments #5024

Open
shaun-technovation opened this issue Sep 16, 2024 · 4 comments
Open

Refactor back-end for chapter assignments #5024

shaun-technovation opened this issue Sep 16, 2024 · 4 comments

Comments

@shaun-technovation
Copy link
Contributor

shaun-technovation commented Sep 16, 2024

Refactor how chapter assignments are done on the back-end to be able to handle a one-to-many relationship for mentors, mentors can belong to many chapters.

Instead of having three ways for chapter assignments (one for students, one for ChAs and one for mentors), it might make more sense to have one consolidated way and place for chapter assignments.

One proposal is to have one table to keep track of chapter assignments:

  • chapter_id
  • account_id
  • profile_type
  • profile_id
  • season
  • primary
@dboyer
Copy link

dboyer commented Sep 18, 2024

Hey team! Please add your planning poker estimate with Zenhub @shaun-technovation @viviancan

@shaun-technovation shaun-technovation self-assigned this Sep 24, 2024
shaun-technovation added a commit that referenced this issue Sep 24, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 24, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 24, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 24, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 26, 2024
Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 27, 2024
Refs: #5024
@shaun-technovation
Copy link
Contributor Author

I have the majority of the refactoring done, just working on a few loose ends, which I plan to wrap up on Monday.

Since I have a pretty big PR open/in progress, I created two spin-off tickets for some mostly independent, but related work:

There might be more functionality that needs to get updated too, that's just what I've noticed so far^.

shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and allow
accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

Refs: #5024
shaun-technovation added a commit that referenced this issue Sep 30, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and will
allow accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

The rest of the changes here are to support those two^ changes.

Refs: #5024
@shaun-technovation shaun-technovation changed the title Refactor back-end for chapter assignment Refactor back-end for chapter assignments Sep 30, 2024
shaun-technovation added a commit that referenced this issue Oct 1, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and will
allow accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

The rest of the changes here are to support those two^ changes.

Refs: #5024
shaun-technovation added a commit that referenced this issue Oct 2, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and will
allow accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

The rest of the changes here are to support those two^ changes.

Refs: #5024
@shaun-technovation
Copy link
Contributor Author

There are two rake tasks I added, I just ran them on Preview:

  • heroku run bundle exec rake migrate_cha_chapter_assignments --app technovation-preview
  • heroku run bundle exec rake migrate_chapter_primary_contacts --app technovation-preview

I also added a new Zenhub issue for deployment notes and added these two rake tasks to it.

@shaun-technovation
Copy link
Contributor Author

This is on Preview. Two big behind the scenes changes:

  • A chapter will now be associated to an account (not a student/cha profile type)
  • A chapter's primary contact will now be associated to an account (not a cha profile type)

Things to look out for is anything that isn't working as expected because of these new association changes.

shaun-technovation added a commit that referenced this issue Oct 7, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and will
allow accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

The rest of the changes here are to support those two^ changes.

Refs: #5024
shaun-technovation added a commit that referenced this issue Oct 9, 2024
This will change how chapter assignments are done, a chapter assignment
used to be one-to-one - one profile type assigned to one chapter. This
new way will associate accounts (not profiles) to chapters, and will
allow accounts to be able to be associated to multiple chapters.

Since chapters are now associated to accounts, the other big change is that a
chapter's primary contact will now be associated to an account instead
of a chapter ambassador profile.

The rest of the changes here are to support those two^ changes.

Refs: #5024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants