-
Notifications
You must be signed in to change notification settings - Fork 1
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
Give privileged groups archive access regardless of Humanities affiliation #609
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aside from one small oversight, looks good. If you address my one comment it's approved, no re-review needed.
main/utils.py
Outdated
"AK", | ||
"LK", | ||
"Secretaris", | ||
"Primaire secretaris", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use the values in constants.py
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! approve :)
Currently it's kind of weird that a secretary or chamber member can't view the archive if they're not in the humanities faculty. This PR resolves this by allowing privileged groups in.
Notes:
FacultyRequiredMixin
to useUserPassesTestMixin
to be able to chain it with the new mixin. But once I had written the utility function for the menus, I realized this was ultimately unnecessary. Because I do believeUserPassesTestMixin
offers more flexibility, I left this change in. But I'm happy to revert it, there's an argument to be made for both methods.