noyainrain / meetling

Web app for collaboratively preparing meetings.
https://meetling.org/
GNU General Public License v3.0
15 stars 2 forks source link

Public meeting permissions #63

Open noyainrain opened 7 years ago

noyainrain commented 7 years ago

Introduce a public mode for meetings, where only the owners of a meeting or agenda item can modify it. By default the creator of a meeting (or agenda item) is the owner and it could be possible to add further owners. Proposing an agenda item is still possible for anyone with access.

noyainrain commented 7 years ago

Preliminary draft:

class Meeting:
    """
    .. describe:: owners

       Owners of the meeting, which includes the creator.

    .. describe:: public

       Indicates if the meeting has a public (untrusted) or restricted (trusted) audience.
       For public meetings, only the owners of a meeting or agenda item can modify it, while anyone
       with access to the meeting can edit anything in a trusted environment.
    """

    def create_agenda_item():
        """
        Permission: Authenticated users.
        """

    def edit():
    def move_agenda_item():
        """
        Permission: *owners* if the meeting is *public*, all authenticated users otherwise.
        """

    def trash_agenda_item():
    def restore_agenda_item():
        """
        Permission: *owner* of the *item* and *owners* of the meeting if it is *public*, all
        authenticated users otherwise.
        """

class AgendaItem:
    """
    .. describe:: owner

       Creator of the item.

    .. describe:: meeting
    """

    def edit():
        """
        Permission: *owner* of the item and *owners* of the *meeting* if it is *public*, all
        authenticated users otherwise.
        """