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

feat: restrict scope access to forms, add/modify form schemas #296

Open
wants to merge 2 commits into
base: 2025-root
Choose a base branch
from

Conversation

connorff
Copy link
Member

No description provided.

Copy link
Member

@akjadhav akjadhav left a comment

Choose a reason for hiding this comment

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

everything else LGTM

@@ -33,6 +33,13 @@ export async function getApplicationAttribute(
getter: (e: IApplication) => any,
createIfNotFound = false
) {
// prevent non-admins from viewing applications
const groups = res.locals.user["cognito:groups"] || [];
const canView = groups.includes("admin") || groups.includes("organizers_current");
Copy link
Member

Choose a reason for hiding this comment

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

We have an admin pool? or should this be leadership_current?

Copy link
Member Author

@connorff connorff Dec 31, 2024

Choose a reason for hiding this comment

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

Yeah we have an existing admin scope. It's what determines whether the admin portal displays on root:

image

backend/routes/common.ts Show resolved Hide resolved
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.

2 participants