pubpub / platform

Open-source technology for creating full-stack knowledge applications for communities of all types.
https://knowledgefutures.org/pubpub
GNU General Public License v2.0
20 stars 2 forks source link

Restrict stage visibility based on membership #762

Open 3mcd opened 6 days ago

3mcd commented 6 days ago

Motivation

So users only see stages they have permission to view.

Requirements

Modify stage-related queries so that:

If a user does not have the ability to see any stages, the link to "Workflows" in the side nav should not appear.

Acceptance Criteria

kalilsn commented 2 days ago

If a user does not have the ability to see any stages, the link to "Workflows" in the side nav should not appear.

This might be a little challenging to do efficiently with the current setup and may require a new (pretty simple) query either way.

3mcd commented 2 days ago

@kalilsn I agree that the requirement to show/hide the Workflows link adds a bit of overhead (one query per page load) for little gain. Instead I think we could always show the link and just put an informative message on the Workflows page if no stages are accessible to the user. Thoughts @gabestein ?