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

Group permissions manager #107

Merged
merged 45 commits into from
Feb 12, 2024
Merged

Group permissions manager #107

merged 45 commits into from
Feb 12, 2024

Conversation

philtweir
Copy link
Contributor

Draft implementation of the group permission manager. This depends on a new external Python module, which is also undergoing iteration.

At present, this is blocked on having a concept to express the available permissions. It also needs work around the node groups, hiding entries from the search results and, as it recalculates the table on each user/resource check (most likely unnecessarily even once a request), will be inefficient.

@philtweir philtweir marked this pull request as draft December 3, 2023 07:35
@philtweir
Copy link
Contributor Author

Separately, this has tidied up a lot of stray files -- that should be separately merged to main and then this PR rebased.

@philtweir philtweir force-pushed the feature/group-permissions-manager branch from 8ac4bff to 6d07431 Compare December 11, 2023 15:22
@philtweir philtweir force-pushed the feature/group-permissions-manager branch from 6d07431 to a29e0df Compare December 11, 2023 15:24
@philtweir
Copy link
Contributor Author

@taylorn01 @OwenGalvia keen to get this to main, but not sure what the best approach is, as would be good to get your input -- perhaps if you find this works for you, we can chat during the week and suggest some steps?

framework.recalculate_table()
enforcer.model.print_policy()
print(enforcer.get_implicit_permissions_for_user("u:310"))
#group_tree = {}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

remove debug

self.userAccountCards = {
userAccount: self.cards?.['user account']
};
console.log(self.userAccountCards, "CARDS");
Copy link
Contributor Author

Choose a reason for hiding this comment

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

remove debug

const userAccountNode = self.getRawNodeValue(params.data(), self.dataConfig.userAccount);

if(userAccountNode){
console.log("USER ACCOUNT", userAccountNode);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

remove debug

@@ -92,9 +187,9 @@
"CONN_MAX_AGE": 0,
"ENGINE": "django.contrib.gis.db.backends.postgis",
"HOST": "localhost",
"NAME": "coral",
"NAME": "arches2",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

wrong default

@@ -190,9 +296,31 @@
# when hosting Arches under a sub path set this value to the sub path eg : "/{sub_path}/"
FORCE_SCRIPT_NAME = None

FORCE_USER_SIGNUP_EMAIL_AUTHENTICATION = False
Copy link
Contributor Author

Choose a reason for hiding this comment

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

add comment:

this allows us to onboard a user via magic link without allowing self-onboarding

@@ -22,3 +22,6 @@ semantic_version
PyJWT
requests_oauthlib
python-docx

git+https://github.com/flaxandteal/arches-orm@master
Copy link
Contributor Author

Choose a reason for hiding this comment

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

point release

@taylorn01 taylorn01 merged commit 08763a2 into main Feb 12, 2024
3 of 4 checks passed
@andrea-kyurchiev andrea-kyurchiev deleted the feature/group-permissions-manager branch August 14, 2024 12:27
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