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

Enhancement/Add guest user role #430

Open
wants to merge 2 commits into
base: master
from

Conversation

@c-w
Copy link
Member

c-w commented Oct 30, 2019

This pull request adds a "guest" or "view only" role to doccano that enables viewing of project documents and annotations but not creation or modification thereof.

The pull request also fixes a number of additional minor issues related to RBAC:

  1. The add_new_superuser_to_projects functions which grants all superusers the admin role on projects wasn't being exercised for admins that were created before the RBAC functionality was introduced. To backport the RBAC functionality to old instances of doccano, the functionality is now being called on server start when we create the default project roles.

  2. The get_current_users_role function had a hard-coded list of roles. To make it easier to add new roles in the future, the function has been refactored to dynamically look up all roles.

Resolves #413

@Hironsan Hironsan added this to To do in v1.0.2 Nov 22, 2019
@Hironsan Hironsan moved this from To do to In progress in v1.0.2 Nov 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
v1.0.2
  
In progress
1 participant
You can’t perform that action at this time.