Skip to content

[INTS25] user admin role models#53

Merged
carolynzhang18 merged 14 commits intomainfrom
INTS25-user-admin-role-models
Jun 21, 2025
Merged

[INTS25] user admin role models#53
carolynzhang18 merged 14 commits intomainfrom
INTS25-user-admin-role-models

Conversation

@carolynzhang18
Copy link
Contributor

@carolynzhang18 carolynzhang18 commented Jun 18, 2025

Notion ticket link

Create User, Admin, and Role Models + Migration Files

Implementation description

  • Create new models admin and position
  • Added position field to user
  • Created migration file to update DB with above changes

Steps to test

  1. With Docker running, run: docker exec recruitment_tools_backend node migrate up.
  2. Check that you don't get any errors (I spent a solid hour whack-a-moling errors, hopefully it works without errors now).
  3. In pgAdmin (or your Postgres viewer of choice), check that admins and positions are seeded with the provided data in the migration file, and check that users now has a position column (I left this nullable for backward compatibility - existing records don't have the field).

What should reviewers focus on?

Checklist

  • My PR name is descriptive and in imperative tense
  • My commit messages are descriptive and in imperative tense. My commits are atomic and trivial commits are squashed or fixup'd into non-trivial commits
  • I have run the appropriate linter(s)
  • I have requested a review from the PL, as well as other devs who have background knowledge on this PR or who will be building on top of this PR

@mxc-maggiechen mxc-maggiechen changed the title Ints25 user admin role models [INTS25] user admin role models Jun 21, 2025
Copy link
Contributor

@mxc-maggiechen mxc-maggiechen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works great! thanks so much for doing so much work on this 👍 I think the workflow error might be a Github problem, but maybe look into it a bit? If we can't resolve it we can merge it in by bypassing permissions

Comment on lines 136 to 153
export const EngineeringPositionTitles = [
"Project Lead",
"Developer",
"VP Engineering",
] as const;
export const DesignPositionTitles = [
"Designer",
"VP Design",
"Graphic Designer",
] as const;
export const ProductPositionTitles = ["Product Manager", "VP Product"] as const;
export const CommunityPositionTitles = [
"President",
"VP Scoping",
"VP Talent",
"VP Finance",
"Director Lead",
"Internal Director",
"External Director",
"Content Strategist",
] as const;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you have time, maybe create a enum for all position titles to prevent misspelling

Copy link
Member

@jeessh jeessh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm
IMG_2150

@carolynzhang18 carolynzhang18 force-pushed the INTS25-user-admin-role-models branch from 3ab55c9 to ad83350 Compare June 21, 2025 16:21
@carolynzhang18 carolynzhang18 force-pushed the INTS25-user-admin-role-models branch from ad83350 to 836cea8 Compare June 21, 2025 16:23
Copy link
Contributor

@eric-mxrtin eric-mxrtin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

@carolynzhang18 carolynzhang18 merged commit 50f844f into main Jun 21, 2025
1 check passed
@carolynzhang18 carolynzhang18 deleted the INTS25-user-admin-role-models branch June 21, 2025 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants