-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Review advanced workflow #8136
Comments
In my opinion the current The proposal is to destructure the advanced workflow into a set of configurations, which cover the current logic and other conflicting cases that cannot be implemented now.
The following 'free' settings would replace (and extend the flexibility) RESOURCE_PUBLISHING, ADMIN_MODERATE_UPLOADS and GROUP_PRIVATE_RESOURCES
The following example is a GeoNode instance without an active advanced workflow:
The following example implements what is descrived in the docs when RESOURCE_PUBLISHING, ADMIN_MODERATE_UPLOADS and GROUP_PRIVATE_RESOURCES are all True
Notice that @mattiagiupponi we should quicly analyse the impact of such a refactoring, taking also into account the migration of an instance with the advanced workflow already in place. |
It is better to use some "acronyms" to describe the list of permissions similar to the
Also, we should consider getting rid of those two options currently available on
Overall, this adds more flexibility for sure, but it looks to me quite hard for a user to understand. |
About point 2, still wondering why we don't have constants or an enum for the permissions set (talking about 32x and 33x of course) |
I see your point @afabiani. We could use and extend the namings we have introduced for the master branch. |
So, in a nutshell:
|
@mattiagiupponi the controls for the disabling of editing by the owner when the advanced workflow is active should also be adaptet. |
@etj I move this to inbox and tag it for master only. |
@giohappy the advanced workflow should be fixed in 3.3.x also. If we need a deeper refactoring in master branch, let's open a new issue for that. |
Reviewing the PR against 3.3.x. First set of test have be run with a vanilla instance, no setting changed. The behaviour seems to be ok when the resource is initially created; when the metadata is edited and a group is assigned, all permission on the resource are granted to the group managers, which is not in the desired behaviour. A little research showed that permission are set over and over also in HTTP GET calls, for instance:
Now, I see a few problems here:
|
You may find useful this query to retrieve the perms assigned to the various resources: select title, name, permname from
(
(select rb.title as title, pp.username as name,ap.name as permname
from guardian_userobjectpermission gup, auth_permission ap, base_resourcebase rb,people_profile pp
where cast(gup.object_pk as integer) = rb.id
and gup.permission_id =ap.id
and gup.user_id =pp.id
order by title,username,ap.name)
union all
select rb.title, '[' || ag."name"||']' as name, ap.name as permname
from guardian_groupobjectpermission gup, auth_permission ap, base_resourcebase rb, auth_group ag
where cast(gup.object_pk as integer) = rb.id
and gup.permission_id =ap.id
and gup.group_id = ag.id
order by title,name,permname
) as xxx
--where title like '%1000%'
order by title,name,permname |
Copying and modifyng the comment in the PR: Scenario 1: Default values: AUTO PUBLISH
Scenario 2: SIMPLE PUBLISHING
Scenario 3: ADVANCED WORKFLOW
Scenario 4: SIMPLE WORKFLOW
Recap:
|
@etj I think you gathered all the current scenarios. BTW we should also include the effects on visibility for anonymous users. We should review this logic too. The doubt is if we should assign / unassign permissions when the resource status change, or if the |
@giohappy Added descr for "anonymous" privs. |
* [Fixes #8136] test skeleton * [Fixes #8136] add test for advanced workflow * [Fixes #8136] Fix advanced workflow, giving permissions to group member and manages * [Fixes #8136] Fix advanced workflow, giving permissions to group member and manages * [Fixes #8136] Fix advanced workflow, giving permissions to group member and manages
About Scenario 3: ADVANCED WORKFLOW If we have https://docs.geonode.org/en/master/basic/settings/index.html#group-private-resources the 'publishing' should not make the resource publicly available but only get rid of the 'pending approval' label. This one: Not that one: |
@gannebamm "pending approval" depends on the approved flag, it's not related to the visibility to private groups. |
Advanced workflow should work as descripted in the issues #3564, #6551, #7135.
Steps to Reproduce the Problem
Specifications
The text was updated successfully, but these errors were encountered: