Inter-Actief / Inter-Actief/alexia

Remove unassigned bartender consumption form access with assign_tenders enabled

Open
#113 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
8
Forks
6
Avg merge
13h 37m
Merged PRs (30d)
1

Description

In the current implementation, when the `assign_tenders` boolean is True for an organization, all bartenders (either assigned or unassigned) can see the buttons to open POS&DCF. The logic used for rendering this button is:
https://github.com/Inter-Actief/alexia/blob/9431a476b23ab1141f70d77ea3fe0b86f6ef0786/templates/scheduling/event_list.html#L128

We propose an improvement that only assigned bartenders and organization managers can see the buttons. So that would change the rendering logic to:
` {% if e in events_tending or request.organization == e.organizer and request.organization.assigns_tenders and is_manager %}` where `is_manager` checks whether the user is a manager of `e.organizer`.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at templates/scheduling/event_list.html around line 128 and inspect how e in events_tending, assigns_tenders, and is_manager affect the POS and DCF buttons. Trace how manager status is determined for e.organizer. Done means unassigned bartenders no longer see the buttons, while assigned bartenders and organization managers still do.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
authorization
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.