Skip to content

Add generic permission model #499

Open
@MrSerth

Description

@MrSerth

In order to allow users granting permissions for their tasks, collections and groups to other users, we could benefit from a generic permission model.

Unitl now, a dedicated NxN relationship between tasks and users existed. While that works for one model, it is not generic and similar logic needs to be implemented for exercises and collections.

Hence, we propose to add a generic, polymorphic permission model to CodeHarbor. The following data structure might be useful as a first draft:

context_id
context_type
user_id
permission

The context_id and context_type represent the polymorphic assosication and might be used to relate to either a task, collection or group.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions