-
Notifications
You must be signed in to change notification settings - Fork 455
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
Add policies layer in between roles and permissions #2495
Merged
Merged
Changes from 23 commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
fac854a
Add policies layer in between roles and permissions
jdorn 5c4e782
Define policies, role->policies map, and policy->permissions map
jdorn b57773b
Hook up new policy-based roles to existing permissions flow
jdorn b2e6d92
Add new fields to OrganizationModel
jdorn 818657e
Remove test suite (part of different PR)
jdorn 1788cb1
Add isRoleValid checks throughout back-end
jdorn 7450d68
Merges in main and resolves conflict.
mknowlton89 2d4950f
Fixes broken import paths
mknowlton89 e430fd9
Merge remote-tracking branch 'origin/main' into permission-policies
jdorn 7895224
Fix tests, add metadata about policies
jdorn 4b40c2f
Move isRoleValid and areProjectRolesValid to shared
jdorn 5f133b4
Helper function to get default role
jdorn 9f950ac
Move permission constants to new file, add displayName to policies
jdorn 4a23b7f
Remove old permission-constants file that's not being used
jdorn 4e29865
Change getRoles logic to match design mocks
jdorn db8b73a
Use getDefaultRole helper throughout codebase
jdorn f9e31a7
Fix type export
jdorn 974af56
Add new permission, commercial feature, and back-end routes for manag…
jdorn 160fcca
Merges in main and resolves conflicts.
mknowlton89 9bebefb
Fixes lint issues and updates policies.
mknowlton89 b8d0fed
Adds missing 'manageSDKWebhooks' permission to SDKConnectionsFullAcce…
mknowlton89 be07356
Merges in main and resolves import conflict.
mknowlton89 8a0d605
Removes FactFiltersFullAccess policy
mknowlton89 d58484e
Merge branch 'main' into permission-policies
mknowlton89 dfc398f
Merge branch 'main' into permission-policies
mknowlton89 File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think we'll want to add one more check - to prevent deleting a role that is the org's default.
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.
I've added this in this PR here, so we don't need to do it here - https://github.com/growthbook/growthbook/pull/2512/files#diff-d577f6ec2e9cc31ebc7af8b716ca1deeffe215e114c4ad0f8f98eef0dde9d404