Implement the /api/positions endpoint #4
Labels
No Label
priority
high
priority
low
priority
medium
priority
very high
BUG
Feature
High Priority
Low Priority
Medium Priority
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: public/pyceo#4
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Implement the /api/positions endpoint. See the old pyceo code for the general idea. Basically you need to add/remove/modify the 'position' attribute for the execs' LDAP records.
The endpoint should accept some sort of JSON body which specifies the positions of all execs (i.e. no partial update). An error should be returned if the important positions are not filled (pres, VP, treasurer, sysadmin).
It should also subscribe new execs to the exec mailing list, and unsubscribe departing execs.
Since this endpoint is doing multiple things in one request, you should use the transaction model (see the AddMemberTransaction for an example).
I'll use this request body as example for implementation:
I think it makes more sense to use the positions as the keys, e.g.
The TUI for ceo will look like this, so it makes more sense for the API to follow suit.